Documentation about exclude/ignore files
Use .git/info/exclude in the example in git-ls-files.txt, instead of .git/ignore, and update the list of commands looking at .git/info/exclude in repository-layout.txt. Signed-off-by: Matthias Lederhofer <matled@gmx.net> Signed-off-by: Junio C Hamano <junkio@cox.net>
Matthias Lederhofer committed
Jul 12, 2006 at 21:54 UTC
ff4d78041e85d1eddb17f2eee497e29aaeee4564
2 files changed
+7
-5
Documentation/git-ls-files.txt
+2
-2
@@ -207,7 +207,7 @@ An exclude pattern is of the following format:
207
An example:
208
209
--------------------------------------------------------------
210
- $ cat .git/ignore
210
+ $ cat .git/info/exclude
211
# ignore objects and archives, anywhere in the tree.
212
*.[oa]
213
$ cat Documentation/.gitignore
@@ -217,7 +217,7 @@ An example:
217
!foo.html
218
$ git-ls-files --ignored \
219
--exclude='Documentation/*.[0-9]' \
220
- --exclude-from=.git/ignore \
220
+ --exclude-from=.git/info/exclude \
221
--exclude-per-directory=.gitignore
222
--------------------------------------------------------------
223
Documentation/repository-layout.txt
+5
-3
@@ -120,9 +120,11 @@ info/grafts::
120
121
info/exclude::
122
This file, by convention among Porcelains, stores the
123
- exclude pattern list. `git status` looks at it, but
124
- otherwise it is not looked at by any of the core git
125
- commands.
123
+ exclude pattern list. `.gitignore` is the per-directory
124
+ ignore file. `git status`, `git add`, `git rm` and `git
125
+ clean` look at it but the core git commands do not look
126
+ at it. See also: gitlink:git-ls-files[1] `--exclude-from`
127
+ and `--exclude-per-directory`.
128
129
remotes::
130
Stores shorthands to be used to give URL and default