Thread (158 messages) 158 messages, 7 authors, 2021-04-09

Re: [PATCH 15/20] gitattributes doc: document multi-line userdiff patterns

flat view

From: Chris Torek <hidden>
Date: 2021-02-15 03:17:13

This is extremely trivial, just something to consider if you are
already doing a reroll:

On Sun, Feb 14, 2021 at 4:57 PM Ævar Arnfjörð Bjarmason
[off-list ref] wrote:
quoted hunk ↗ jump to hunk
diff --git a/Documentation/gitattributes.txt b/Documentation/gitattributes.txt
index 90992e2136..225c17b90d 100644
--- a/Documentation/gitattributes.txt
+++ b/Documentation/gitattributes.txt
@@ -794,6 +794,23 @@ backslashes; the pattern above picks a line that begins with a
 backslash, and zero or more occurrences of `sub` followed by
 `section` followed by open brace, to the end of line.

+Multiple patterns can be supplied by seperating them with
+newlines. They will be matched one at a time and are compiled as
+separate patterns, and thus the first capture in each such pattern is
+`$1`, see further discussion of captures below.
This is a comma splice (https://en.wikipedia.org/wiki/Comma_splice).
Use a period or semicolon to fix it.

(overall comment, haven't quite finished scanning the series yet but it
looks good!)

Chris
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help