Skip to content

Commit 480611d

Browse files
wheegitster
authored andcommitted
Make usage documentation for git-add consistent.
The usage string for the executable was missing --refresh. In addition, the documentation referred to "file", but the usage string referred to "filepattern". Updated the documentation to "filepattern", as git-add does handle patterns. Signed-off-by: Brian Hetro <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 1560be1 commit 480611d

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

Documentation/git-add.txt

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,9 @@ git-add - Add file contents to the index
77

88
SYNOPSIS
99
--------
10-
'git-add' [-n] [-v] [-f] [--interactive | -i] [-u] [--refresh] [--] <file>...
10+
[verse]
11+
'git-add' [-n] [-v] [-f] [--interactive | -i] [-u] [--refresh]
12+
[--] <filepattern>...
1113

1214
DESCRIPTION
1315
-----------
@@ -41,7 +43,7 @@ commit.
4143

4244
OPTIONS
4345
-------
44-
<file>...::
46+
<filepattern>...::
4547
Files to add content from. Fileglobs (e.g. `*.c`) can
4648
be given to add all matching files. Also a
4749
leading directory name (e.g. `dir` to add `dir/file1`

builtin-add.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
#include "revision.h"
1515

1616
static const char builtin_add_usage[] =
17-
"git-add [-n] [-v] [-f] [--interactive | -i] [-u] [--] <filepattern>...";
17+
"git-add [-n] [-v] [-f] [--interactive | -i] [-u] [--refresh] [--] <filepattern>...";
1818

1919
static int take_worktree_changes;
2020
static const char *excludes_file;

0 commit comments

Comments
 (0)