Skip to content

Commit

Permalink
feat(git-authors): support path value for --output
Browse files Browse the repository at this point in the history
  • Loading branch information
vanpipy committed Nov 20, 2023
1 parent 50b9677 commit 7334237
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions bin/git-authors
Original file line number Diff line number Diff line change
Expand Up @@ -44,11 +44,11 @@ while [[ $# -gt 0 ]]; do
no_email=1
;;
--output )
if [[ -n $2 ]] && [[ $2 =~ ^[a-zA-Z] ]]; then
if [[ -n $2 ]] && [[ $2 =~ ^(\.\/|\.\.\/|\/)?([a-zA-Z]\/?)+$ ]]; then
output=$2
shift
else
echo >&2 "option $1 requires a letter prefix value"
echo >&2 "option $1 requires a path-like value"
exit 1
fi
;;
Expand Down
2 changes: 1 addition & 1 deletion man/git-authors.1
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ output the authors
.P
<filename>
.P
the filename which is letter prefix to save the authors
the filename which is path\-like to save the authors
.SH "EXAMPLES"
Updating AUTHORS file:
.IP "" 4
Expand Down
2 changes: 1 addition & 1 deletion man/git-authors.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion man/git-authors.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ git-authors(1) -- Generate authors report

&lt;filename&gt;

the filename which is letter prefix to save the authors
the filename which is path-like to save the authors

## EXAMPLES

Expand Down

0 comments on commit 7334237

Please sign in to comment.