<feed xmlns='http://www.w3.org/2005/Atom'>
<title>user/sven/git.git/Documentation/CodingGuidelines, branch v2.26.0-rc2</title>
<subtitle>Git
</subtitle>
<id>https://git.stealer.net/cgit.cgi/user/sven/git.git/atom?h=v2.26.0-rc2</id>
<link rel='self' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/atom?h=v2.26.0-rc2'/>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/'/>
<updated>2019-11-07T04:42:00Z</updated>
<entry>
<title>Documentation: fix a bunch of typos, both old and new</title>
<updated>2019-11-07T04:42:00Z</updated>
<author>
<name>Elijah Newren</name>
<email>newren@gmail.com</email>
</author>
<published>2019-11-05T17:07:20Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=031fd4b93b8182761948aa348565118955f48307'/>
<id>urn:sha1:031fd4b93b8182761948aa348565118955f48307</id>
<content type='text'>
Reported-by: Jens Schleusener &lt;Jens.Schleusener@fossies.org&gt;
Signed-off-by: Elijah Newren &lt;newren@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'jc/post-c89-rules-doc'</title>
<updated>2019-07-25T20:59:23Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2019-07-25T20:59:22Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=fe9dc6b08c35a8808d24ad32ddac847bc3137a4a'/>
<id>urn:sha1:fe9dc6b08c35a8808d24ad32ddac847bc3137a4a</id>
<content type='text'>
We have been trying out a few language features outside c89; the
coding guidelines document did not talk about them and instead had
a blanket ban against them.

* jc/post-c89-rules-doc:
  CodingGuidelines: spell out post-C89 rules
</content>
</entry>
<entry>
<title>CodingGuidelines: spell out post-C89 rules</title>
<updated>2019-07-18T22:16:04Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2019-07-16T17:21:20Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=cc0c42975a2d9159fea5fdd053425492333c1aba'/>
<id>urn:sha1:cc0c42975a2d9159fea5fdd053425492333c1aba</id>
<content type='text'>
Even though we have been sticking to C89, there are a few handy
features we borrow from more recent C language in our codebase after
trying them in weather balloons and saw that nobody screamed.

Spell them out.

While at it, extend the existing variable declaration rule a bit to
read better with the newly spelled out rule for the for loop.

Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'es/git-debugger-doc'</title>
<updated>2019-06-17T17:15:14Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2019-06-17T17:15:14Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=7df94cd1f691dd6ccb3038e1b77544030aab3fed'/>
<id>urn:sha1:7df94cd1f691dd6ccb3038e1b77544030aab3fed</id>
<content type='text'>
Doc update.

* es/git-debugger-doc:
  doc: hint about GIT_DEBUGGER in CodingGuidelines
</content>
</entry>
<entry>
<title>doc: hint about GIT_DEBUGGER in CodingGuidelines</title>
<updated>2019-05-28T20:42:33Z</updated>
<author>
<name>Emily Shaffer</name>
<email>emilyshaffer@google.com</email>
</author>
<published>2019-05-28T19:07:29Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=f547101b26449c65aefd378022277ebb953eb7a6'/>
<id>urn:sha1:f547101b26449c65aefd378022277ebb953eb7a6</id>
<content type='text'>
We check for a handy environment variable GIT_DEBUGGER when running via
bin-wrappers/, but this feature is undocumented. Add a hint to how to
use it into the CodingGuidelines (which is where other useful
environment settings like DEVELOPER are documented).

Signed-off-by: Emily Shaffer &lt;emilyshaffer@google.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>doc/CodingGuidelines: URLs and paths as monospace</title>
<updated>2019-03-13T02:14:10Z</updated>
<author>
<name>Corentin BOMPARD</name>
<email>corentin.bompard@etu.univ-lyon1.fr</email>
</author>
<published>2019-03-06T13:04:45Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=0dbd305fe7b1c6394e24ef598898ef6cebd42956'/>
<id>urn:sha1:0dbd305fe7b1c6394e24ef598898ef6cebd42956</id>
<content type='text'>
The current documentation uses both quotes (italics) and backquotes
(monospace) to render URLs and pathnames, which is inconsistent.
Document a best practice in CodingGuidelines to help reduce
inconsistencies in the future.

We set the best practice to using backquotes, since:

* It is already an established practice. For exemple:

  $ git grep "'[^']/*[^']'" | wc -l
  206

  $ git grep '`[^`]/*[^`]`' | wc -l
  690

  There are false positives on both sides, but after a cursory look at
  the output of both, it doesn't seem the false positive rate is really
  higher in the second case.

  At least, this shows that the existing documentation uses
  inconsistent formatting, and that it would be good to do
  something about it.

* It may be debatable whether path names need to be typed in
  monospace but having them in italics is really unusual.

Signed-off-by: Corentin BOMPARD &lt;corentin.bompard@etu.univ-lyon1.fr&gt;
Signed-off-by: Nathan BERBEZIER &lt;nathan.berbezier@etu.univ-lyon1.fr&gt;
Signed-off-by: Pablo CHABANNE &lt;pablo.chabanne@etu.univ-lyon1.fr&gt;
Signed-off-by: Matthieu MOY &lt;matthieu.moy@univ-lyon1.fr&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'jc/how-to-document-api'</title>
<updated>2018-10-19T04:34:05Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2018-10-19T04:34:05Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=0d4f473a985e5b5f15ae88fd8dda695a694b9955'/>
<id>urn:sha1:0d4f473a985e5b5f15ae88fd8dda695a694b9955</id>
<content type='text'>
Doc update.

* jc/how-to-document-api:
  CodingGuidelines: document the API in *.h files
</content>
</entry>
<entry>
<title>Documentation: add shell guidelines</title>
<updated>2018-10-06T23:51:17Z</updated>
<author>
<name>Matthew DeVore</name>
<email>matvore@google.com</email>
</author>
<published>2018-10-05T21:54:02Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=a378fee5b0795d671722d803b93b7b32941c0067'/>
<id>urn:sha1:a378fee5b0795d671722d803b93b7b32941c0067</id>
<content type='text'>
Add the following guideline to Documentation/CodingGuidelines:

	Break overlong lines after "&amp;&amp;", "||", and "|", not before
	them; that way the command can continue to subsequent lines
	without backslash at the end.

And the following to t/README (since it is specific to writing tests):

	Pipes and $(git ...) should be avoided when they swallow exit
	codes of Git processes

Signed-off-by: Matthew DeVore &lt;matvore@google.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>CodingGuidelines: document the API in *.h files</title>
<updated>2018-09-29T18:18:01Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2018-09-28T16:50:14Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=d9f079ad1a866151fea01f7f977dfbd1ba4d97f7'/>
<id>urn:sha1:d9f079ad1a866151fea01f7f977dfbd1ba4d97f7</id>
<content type='text'>
It makes it harder to let the API description and the reality drift
apart if the doc is kept close to the implementation or the header
of the API.  We have been slowly migrating API docs out of the
Documentation/technical/api-* to *.h files, and the development
community generally considers that how inline docs in strbuf.h is
done the best current practice.

We recommend documenting in the header over documenting near the
implementation to encourage people to write the docs that are
readable without peeking at the implemention.

Helped-by: Jeff King &lt;peff@peff.net&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>CodingGuidelines: mention "static" and "extern"</title>
<updated>2018-02-08T22:20:43Z</updated>
<author>
<name>Jeff King</name>
<email>peff@peff.net</email>
</author>
<published>2018-02-08T21:38:06Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=89a9f2c862db52d99e4dd78e799f4b36dac597ac'/>
<id>urn:sha1:89a9f2c862db52d99e4dd78e799f4b36dac597ac</id>
<content type='text'>
It perhaps goes without saying that file-local stuff should
be marked static, but it does not hurt to remind people.

Less obvious is that we are settling on "do not include
extern in function declarations". It is already the default
unless the function was previously declared static (but if
you are following a static declaration with an unmarked one,
you should think about why you are declaring the thing
twice). And so it just becomes an extra noise-word in our
header files.

We used to give the opposite advice, so there are quite a
few "extern" markers in early Git code. But this at least
makes a concrete suggestion that we can follow going
forward.

Signed-off-by: Jeff King &lt;peff@peff.net&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
</feed>
