Skip to content

Commit e041706

Browse files
deviantintegralgitster
authored andcommitted
docs: .gitignore parsing is to the top of the repo
The current documentation reads as if .gitignore files will be parsed in every parent directory, and not until they reach a repository boundary. This clarifies the current behaviour. As well, this corrects 'toplevel' to 'top-level', matching usage for 'top-level domain'. Signed-off-by: Andrew Berry <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent ebf3c04 commit e041706

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

Documentation/gitignore.txt

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -27,12 +27,11 @@ precedence, the last matching pattern decides the outcome):
2727
them.
2828

2929
* Patterns read from a `.gitignore` file in the same directory
30-
as the path, or in any parent directory, with patterns in the
31-
higher level files (up to the toplevel of the work tree) being overridden
32-
by those in lower level files down to the directory containing the file.
33-
These patterns match relative to the location of the
34-
`.gitignore` file. A project normally includes such
35-
`.gitignore` files in its repository, containing patterns for
30+
as the path, or in any parent directory (up to the top-level of the working
31+
tree), with patterns in the higher level files being overridden by those in
32+
lower level files down to the directory containing the file. These patterns
33+
match relative to the location of the `.gitignore` file. A project normally
34+
includes such `.gitignore` files in its repository, containing patterns for
3635
files generated as part of the project build.
3736

3837
* Patterns read from `$GIT_DIR/info/exclude`.

0 commit comments

Comments
 (0)