<feed xmlns='http://www.w3.org/2005/Atom'>
<title>git/ws.c, branch v2.13.2</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/git/git.git/
</subtitle>
<id>https://git.shady.money/git/atom?h=v2.13.2</id>
<link rel='self' href='https://git.shady.money/git/atom?h=v2.13.2'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/'/>
<updated>2017-02-01T21:46:52Z</updated>
<entry>
<title>attr: convert git_check_attrs() callers to use the new API</title>
<updated>2017-02-01T21:46:52Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2017-01-28T02:01:57Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=2aef63d31c338a764099e925d35fe2a9c71348a8'/>
<id>urn:sha1:2aef63d31c338a764099e925d35fe2a9c71348a8</id>
<content type='text'>
The remaining callers are all simple "I have N attributes I am
interested in.  I'll ask about them with various paths one by one".

After this step, no caller to git_check_attrs() remains.  After
removing it, we can extend "struct attr_check" struct with data
that can be used in optimizing the query for the specific N
attributes it contains.

Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
Signed-off-by: Stefan Beller &lt;sbeller@google.com&gt;
Signed-off-by: Brandon Williams &lt;bmwill@google.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>attr: rename function and struct related to checking attributes</title>
<updated>2017-02-01T21:46:52Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2017-01-28T02:01:54Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=7bd18054d249d1f9aebad38d74ba6c53f8e6ecb3'/>
<id>urn:sha1:7bd18054d249d1f9aebad38d74ba6c53f8e6ecb3</id>
<content type='text'>
The traditional API to check attributes is to prepare an N-element
array of "struct git_attr_check" and pass N and the array to the
function "git_check_attr()" as arguments.

In preparation to revamp the API to pass a single structure, in
which these N elements are held, rename the type used for these
individual array elements to "struct attr_check_item" and rename
the function to "git_check_attrs()".

Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
Signed-off-by: Stefan Beller &lt;sbeller@google.com&gt;
Signed-off-by: Brandon Williams &lt;bmwill@google.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>use strchrnul() in place of strchr() and strlen()</title>
<updated>2014-03-10T15:35:30Z</updated>
<author>
<name>Rohit Mani</name>
<email>rohit.mani@outlook.com</email>
</author>
<published>2014-03-08T06:48:31Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=2c5495f7b60d6ddcd6a411b48d2f6dbc4a24717a'/>
<id>urn:sha1:2c5495f7b60d6ddcd6a411b48d2f6dbc4a24717a</id>
<content type='text'>
Avoid scanning strings twice, once with strchr() and then with
strlen(), by using strchrnul().

Helped-by: Junio C Hamano &lt;gitster@pobox.com&gt;
Signed-off-by: Rohit Mani &lt;rohit.mani@outlook.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Rename git_checkattr() to git_check_attr()</title>
<updated>2011-08-04T22:53:21Z</updated>
<author>
<name>Michael Haggerty</name>
<email>mhagger@alum.mit.edu</email>
</author>
<published>2011-08-04T04:36:33Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=d932f4eb9fc88e93040635d291f6c195ea2e4ee3'/>
<id>urn:sha1:d932f4eb9fc88e93040635d291f6c195ea2e4ee3</id>
<content type='text'>
Suggested by: Junio Hamano &lt;gitster@pobox.com&gt;

Signed-off-by: Michael Haggerty &lt;mhagger@alum.mit.edu&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Make the tab width used for whitespace checks configurable</title>
<updated>2010-12-01T22:47:51Z</updated>
<author>
<name>Johannes Sixt</name>
<email>j6t@kdbg.org</email>
</author>
<published>2010-11-30T08:29:11Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=f4b05a4947f5f1cf3e01fb61ec5919cc28fe11f7'/>
<id>urn:sha1:f4b05a4947f5f1cf3e01fb61ec5919cc28fe11f7</id>
<content type='text'>
A new whitespace "rule" is added that sets the tab width to use for
whitespace checks and fix-ups and replaces the hard-coded constant 8.

Since the setting is part of the rules, it can be set per file using
.gitattributes.

The new configuration is backwards compatible because older git versions
simply ignore unknown whitespace rules.

Signed-off-by: Johannes Sixt &lt;j6t@kdbg.org&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'js/maint-apply-tab-in-indent-fix' into HEAD</title>
<updated>2010-12-01T22:42:00Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2010-12-01T22:42:00Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=dee40e5178bab78aaf655ee4323f3141acd17654'/>
<id>urn:sha1:dee40e5178bab78aaf655ee4323f3141acd17654</id>
<content type='text'>
* js/maint-apply-tab-in-indent-fix:
  apply --whitespace=fix: fix tab-in-indent
</content>
</entry>
<entry>
<title>apply --whitespace=fix: fix tab-in-indent</title>
<updated>2010-12-01T22:34:00Z</updated>
<author>
<name>Johannes Sixt</name>
<email>j6t@kdbg.org</email>
</author>
<published>2010-11-30T08:22:04Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=d35711adc4cffe0c4aebd85c197080c7163bcb77'/>
<id>urn:sha1:d35711adc4cffe0c4aebd85c197080c7163bcb77</id>
<content type='text'>
When the whitespace rule tab-in-indent is enabled, apply --whitespace=fix
replaces tabs by the appropriate amount of blanks. The code used
"dst-&gt;len % 8" as the criterion to stop adding blanks. But it forgot that
dst holds more than just the current line. Consequently, the modulus was
computed correctly only for the first added line, but not for the second
and subsequent lines. Fix it.

Signed-off-by: Johannes Sixt &lt;j6t@kdbg.org&gt;
Acked-by: Chris Webb &lt;chris@arachsys.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>diff: handle lines containing only whitespace and tabs better</title>
<updated>2010-10-20T23:10:15Z</updated>
<author>
<name>Kevin Ballard</name>
<email>kevin@sb.org</email>
</author>
<published>2010-10-20T22:17:26Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=cfd1a9849cdb4b9c7fcd0cb71a28cbdbc3494329'/>
<id>urn:sha1:cfd1a9849cdb4b9c7fcd0cb71a28cbdbc3494329</id>
<content type='text'>
When a line contains nothing but whitespace with at least one tab
and the core.whitespace config option contains blank-at-eol, the
whitespace on the line is being printed twice, once unhighlighted
(unless otherwise matched by one of the other core.whitespace values),
and a second time highlighted for blank-at-eol.

Update the leading indentation check to stop checking when it reaches
the trailing whitespace.

Signed-off-by: Kevin Ballard &lt;kevin@sb.org&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>whitespace: add tab-in-indent support for --whitespace=fix</title>
<updated>2010-04-04T21:21:54Z</updated>
<author>
<name>Chris Webb</name>
<email>chris@arachsys.com</email>
</author>
<published>2010-04-02T23:37:30Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=4e35c51e5113e83155a6c44a8f9adeafed9125d2'/>
<id>urn:sha1:4e35c51e5113e83155a6c44a8f9adeafed9125d2</id>
<content type='text'>
If tab-in-indent is set, --whitespace=fix will ensure that any stray tabs in
the initial indent are expanded to the correct number of space characters.

Signed-off-by: Chris Webb &lt;chris@arachsys.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>whitespace: replumb ws_fix_copy to take a strbuf *dst instead of char *dst</title>
<updated>2010-04-04T21:21:54Z</updated>
<author>
<name>Chris Webb</name>
<email>chris@arachsys.com</email>
</author>
<published>2010-04-02T23:37:23Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=d511bd330d66fe8f0be21855888e30af2f3e373b'/>
<id>urn:sha1:d511bd330d66fe8f0be21855888e30af2f3e373b</id>
<content type='text'>
To implement --whitespace=fix for tab-in-indent, we have to allow for the
possibility that whitespace can increase in size when it is fixed, expanding
tabs to to multiple spaces in the initial indent.

Signed-off-by: Chris Webb &lt;chris@arachsys.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
</feed>
