Merge branch 'jn/ignore-doc'
authorJunio C Hamano <gitster@pobox.com>
Mon, 27 Jan 2014 18:44:26 +0000 (10:44 -0800)
committerJunio C Hamano <gitster@pobox.com>
Mon, 27 Jan 2014 18:44:27 +0000 (10:44 -0800)
Explicitly list $HOME/.config/git/ignore as one of the places you
can use to keep ignore patterns that depend on your personal choice
of tools, e.g. *~ for Emacs users.

* jn/ignore-doc:
gitignore doc: add global gitignore to synopsis

1  2 
Documentation/gitignore.txt
index 205e80ef884a8c8852d7e83ca1ee660a5e1e8414,37c94707b675858254eefc441e64bb22310e9e60..b08d34d84ec92eec6aa54572e3823062424c23bf
@@@ -7,7 -7,7 +7,7 @@@ gitignore - Specifies intentionally unt
  
  SYNOPSIS
  --------
- $GIT_DIR/info/exclude, .gitignore
+ $HOME/.config/git/ignore, $GIT_DIR/info/exclude, .gitignore
  
  DESCRIPTION
  -----------
@@@ -79,10 -79,8 +79,10 @@@ PATTERN FORMA
  
   - An optional prefix "`!`" which negates the pattern; any
     matching file excluded by a previous pattern will become
 -   included again.  If a negated pattern matches, this will
 -   override lower precedence patterns sources.
 +   included again. It is not possible to re-include a file if a parent
 +   directory of that file is excluded. Git doesn't list excluded
 +   directories for performance reasons, so any patterns on contained
 +   files have no effect, no matter where they are defined.
     Put a backslash ("`\`") in front of the first "`!`" for patterns
     that begin with a literal "`!`", for example, "`\!important!.txt`".
  
@@@ -184,19 -182,6 +184,19 @@@ Another example
  The second .gitignore prevents Git from ignoring
  `arch/foo/kernel/vmlinux.lds.S`.
  
 +Example to exclude everything except a specific directory `foo/bar`
 +(note the `/*` - without the slash, the wildcard would also exclude
 +everything within `foo/bar`):
 +
 +--------------------------------------------------------------
 +    $ cat .gitignore
 +    # exclude everything except directory foo/bar
 +    /*
 +    !/foo
 +    /foo/*
 +    !/foo/bar
 +--------------------------------------------------------------
 +
  SEE ALSO
  --------
  linkgit:git-rm[1],