Use rooted paths in .gitignore files

A leading / in paths in a .gitignore file matches the beginning of the
path, meaning that for patterns without slashes, git will match files
only in the current directory as opposed to in any subdirectory.

Prefix relevant paths with / in .gitignore files, to prevent
accidentally ignoring files in subdirectories and possibly slightly
improve the performance of "git status".
This commit is contained in:
Vladimir Panteleev 2017-08-17 00:41:10 +00:00 committed by David Bremner
parent 4d44976135
commit ca4688e103
14 changed files with 58 additions and 58 deletions

18
.gitignore vendored
View file

@ -1,16 +1,16 @@
.first-build-message /.first-build-message
Makefile.config /Makefile.config
sh.config /sh.config
version.stamp /version.stamp
TAGS TAGS
tags tags
*cscope* *cscope*
.deps /.deps
/notmuch /notmuch
notmuch-shared /notmuch-shared
libnotmuch.so* /lib/libnotmuch.so*
libnotmuch*.dylib /lib/libnotmuch*.dylib
*.[ao] *.[ao]
*~ *~
.*.swp .*.swp
releases /releases

View file

@ -1,4 +1,4 @@
*.py[co] *.py[co]
/docs/build /docs/build
/docs/html /docs/html
build/ /build/

View file

@ -1,7 +1,7 @@
# .gitignore for bindings/ruby # .gitignore for bindings/ruby
# Generated files # Generated files
Makefile /Makefile
mkmf.log /mkmf.log
notmuch.so /notmuch.so
*.o *.o

2
compat/.gitignore vendored
View file

@ -1 +1 @@
zlib.pc /zlib.pc

View file

@ -1,3 +1,3 @@
src/github.com/ /src/github.com/
pkg/ /pkg/
bin/ /bin/

View file

@ -1,2 +1,2 @@
notmuch-mutt.1 /notmuch-mutt.1
README.html /README.html

28
debian/.gitignore vendored
View file

@ -1,14 +1,14 @@
tmp/ /tmp/
libnotmuch-dev/ /libnotmuch-dev/
libnotmuch*/ /libnotmuch*/
notmuch-emacs/ /notmuch-emacs/
notmuch/ /notmuch/
notmuch-dbg/ /notmuch-dbg/
notmuch-mutt/ /notmuch-mutt/
notmuch-vim/ /notmuch-vim/
ruby-notmuch/ /ruby-notmuch/
python*-notmuch/ /python*-notmuch/
*.debhelper /*.debhelper
*.debhelper.log /*.debhelper.log
*.substvars /*.substvars
files /files

View file

@ -1,2 +1,2 @@
*.pyc *.pyc
_build /_build

4
doc/.gitignore vendored
View file

@ -1,3 +1,3 @@
*.pyc *.pyc
_build /_build
config.dox /config.dox

8
emacs/.gitignore vendored
View file

@ -1,4 +1,4 @@
.eldeps* /.eldeps*
*.elc /*.elc
notmuch-version.el /notmuch-version.el
notmuch-pkg.el /notmuch-pkg.el

View file

@ -1,4 +1,4 @@
tmp.*/ /tmp.*/
log.*/ /log.*/
corpus/ /corpus/
notmuch.cache.*/ /notmuch.cache.*/

View file

@ -1,2 +1,2 @@
*.tar.gz /*.tar.gz
*.tar.xz /*.tar.xz

22
test/.gitignore vendored
View file

@ -1,11 +1,11 @@
arg-test /arg-test
corpora.mail /corpora.mail
hex-xcode /hex-xcode
parse-time /parse-time
random-corpus /random-corpus
smtp-dummy /smtp-dummy
symbol-test /symbol-test
make-db-version /make-db-version
test-results /test-results
ghost-report /ghost-report
tmp.* /tmp.*

View file

@ -1 +1 @@
*.tar.xz /*.tar.xz