@matheusbsbs / matheus-bagliano / commits / b86bec6c4f
Fork 0

Documentation: add another example to git-ls-files

Signed-off-by: Junio C Hamano <junkio@cox.net>

Junio C Hamano committed Jun 7, 2006 at 20:16 UTC b86bec6c4ff7909246e68a4495dcaaeede3907e9
1 file changed +14 -2
Documentation/git-ls-files.txt
+14 -2
@@ -195,8 +195,7 @@ An exclude pattern is of the following format:
195
196 - if it does not contain a slash '/', it is a shell glob
197 pattern and used to match against the filename without
198 - leading directories (i.e. the same way as the current
199 - implementation).
198 + leading directories.
199
200 - otherwise, it is a shell glob pattern, suitable for
201 consumption by fnmatch(3) with FNM_PATHNAME flag. I.e. a
@@ -222,6 +221,19 @@ An example:
221 --exclude-per-directory=.gitignore
222 --------------------------------------------------------------
223
224 +Another example:
225 +
226 +--------------------------------------------------------------
227 + $ cat .gitignore
228 + vmlinux*
229 + $ ls arch/foo/kernel/vm*
230 + arch/foo/kernel/vmlinux.lds.S
231 + $ echo '!/vmlinux*' >arch/foo/kernel/.gitignore
232 +--------------------------------------------------------------
233 +
234 +The second .gitignore keeps `arch/foo/kernel/vmlinux.lds.S` file
235 +from getting ignored.
236 +
237
238 See Also
239 --------