Git development
 help / color / mirror / Atom feed
* [PATCH] doc: gitignore: rejoin related paragraphs
@ 2026-11-28  7:14 Matt Hunter
  2026-11-29  4:51 ` Junio C Hamano
  0 siblings, 1 reply; 3+ messages in thread
From: Matt Hunter @ 2026-11-28  7:14 UTC (permalink / raw)
  To: git

Some text has become separated from relevant context by the addition of
another paragraph.

Reorder the "If there is a separator at the beginning or middle..." item
so that it is next to the "For example..." item that describes it.  The
preceeding item about paths ending in "/" is related, however the
example text speaks more to the moved paragraph than this one.

Signed-off-by: Matt Hunter <m@lfurio.us>
---

Noticed while looking into
 <20261106182945.1316297-1-aniketgupta3001@gmail.com> and
 <xmqqh5hx4jz3.fsf_-_@gitster.g>

 Documentation/gitignore.adoc | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/Documentation/gitignore.adoc b/Documentation/gitignore.adoc
index 7979e50f187e..662632bdefc9 100644
--- a/Documentation/gitignore.adoc
+++ b/Documentation/gitignore.adoc
@@ -91,11 +91,6 @@ PATTERN FORMAT
  - The slash "`/`" is used as the directory separator. Separators may
    occur at the beginning, middle or end of the `.gitignore` search pattern.
 
- - If there is a separator at the beginning or middle (or both) of the
-   pattern, then the pattern is relative to the directory level of the
-   particular `.gitignore` file itself. Otherwise the pattern may also
-   match at any level below the `.gitignore` level.
-
  - Patterns read from exclude sources that are outside the working tree,
    such as $GIT_COMMON_DIR/info/exclude and core.excludesFile, are treated as if
    they are specified at the root of the working tree, i.e. a leading "/"
@@ -105,6 +100,11 @@ PATTERN FORMAT
    will only match directories, otherwise the pattern can match both
    files and directories.
 
+ - If there is a separator at the beginning or middle (or both) of the
+   pattern, then the pattern is relative to the directory level of the
+   particular `.gitignore` file itself. Otherwise the pattern may also
+   match at any level below the `.gitignore` level.
+
  - For example, a pattern `doc/frotz/` matches `doc/frotz` directory,
    but not `a/doc/frotz` directory; however `frotz/` matches `frotz`
    and `a/frotz` that is a directory (all paths are relative from

base-commit: a018953688f1b10bddf91bff8747068f5f4746a4
-- 
2.56.1.944.gfc811cc53d


^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2026-11-29  9:15 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-11-28  7:14 [PATCH] doc: gitignore: rejoin related paragraphs Matt Hunter
2026-11-29  4:51 ` Junio C Hamano
2026-11-29  9:15   ` Matt Hunter

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox