aboutsummaryrefslogtreecommitdiffstats
path: root/Documentation
diff options
context:
space:
mode:
authorJulia Evans <julia@jvns.ca>2025-08-19 20:46:10 +0000
committerJunio C Hamano <gitster@pobox.com>2025-08-19 16:04:54 -0700
commit929e112481b4632a6664d7b583bd99b8c590eb1a (patch)
treececceba69dc842f6f99e2a324594b07e42517440 /Documentation
parentd14147c0ab84bf4d08adedb4d1a4e99511c56375 (diff)
downloadgit-929e112481b4632a6664d7b583bd99b8c590eb1a.tar.gz
doc: git-add: simplify discussion of ignored files
- Mention the --force option earlier - Remove the explanation of shell globbing vs git's internal glob system, since users are confused by it and there's a clearer discussion in the EXAMPLES section. Signed-off-by: Julia Evans <julia@jvns.ca> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'Documentation')
-rw-r--r--Documentation/git-add.adoc10
1 files changed, 4 insertions, 6 deletions
diff --git a/Documentation/git-add.adoc b/Documentation/git-add.adoc
index 19f99b0e7f..bf793d2894 100644
--- a/Documentation/git-add.adoc
+++ b/Documentation/git-add.adoc
@@ -37,12 +37,10 @@ you must run `git add` again to add the new content to the index.
The `git status` command can be used to obtain a summary of which
files have changes that are staged for the next commit.
-The `git add` command will not add ignored files by default. If any
-ignored files were explicitly specified on the command line, `git add`
-will fail with a list of ignored files. Ignored files reached by
-directory recursion or filename globbing performed by Git (quote your
-globs before the shell) will be silently ignored. The `git add` command can
-be used to add ignored files with the `-f` (force) option.
+The `git add` command will not add ignored files by default. You can
+use the `--force` option to add ignored files. If you specify the exact
+filename of an ignored file, `git add` will fail with a list of ignored
+files. Otherwise it will silently ignore the file.
Please see linkgit:git-commit[1] for alternative ways to add content to a
commit.