diff options
author | Junio C Hamano <gitster@pobox.com> | 2013-02-05 16:13:32 -0800 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2013-02-05 16:13:32 -0800 |
commit | e34c7e2b51c02a761a034b877b852dc0dbccf101 (patch) | |
tree | 2c80451e27d6fda5c0745270fee17da9e7bc2d1e /Documentation/CodingGuidelines | |
parent | 6d81ce0543c2fb7177c08491ba31a69aa54b7930 (diff) | |
parent | afeef30c34116ddc4a091d497f5ac8f4cdde7c65 (diff) | |
download | git-e34c7e2b51c02a761a034b877b852dc0dbccf101.tar.gz |
Merge branch 'ta/doc-no-small-caps'
Update documentation to change "GIT" which was a poor-man's small
caps to "Git". The latter was the intended spelling.
Also change "git" spelled in all-lowercase to "Git" when it refers
to the system as the whole or the concept it embodies, as opposed to
the command the end users would type.
* ta/doc-no-small-caps:
Documentation: StGit is the right spelling, not StGIT
Documentation: describe the "repository" in repository-layout
Documentation: add a description for 'gitfile' to glossary
Documentation: do not use undefined terms git-dir and git-file
Documentation: the name of the system is 'Git', not 'git'
Documentation: avoid poor-man's small caps GIT
Diffstat (limited to 'Documentation/CodingGuidelines')
-rw-r--r-- | Documentation/CodingGuidelines | 19 |
1 files changed, 12 insertions, 7 deletions
diff --git a/Documentation/CodingGuidelines b/Documentation/CodingGuidelines index 69f7e9b76c..1d7de5f985 100644 --- a/Documentation/CodingGuidelines +++ b/Documentation/CodingGuidelines @@ -1,5 +1,5 @@ Like other projects, we also have some guidelines to keep to the -code. For git in general, three rough rules are: +code. For Git in general, three rough rules are: - Most importantly, we never say "It's in POSIX; we'll happily ignore your needs should your system not conform to it." @@ -22,7 +22,7 @@ code. For git in general, three rough rules are: As for more concrete guidelines, just imitate the existing code (this is a good guideline, no matter which project you are contributing to). It is always preferable to match the _local_ -convention. New code added to git suite is expected to match +convention. New code added to Git suite is expected to match the overall style of existing code. Modifications to existing code is expected to match the style the surrounding code already uses (even if it doesn't match the overall style of existing code). @@ -112,7 +112,7 @@ For C programs: - We try to keep to at most 80 characters per line. - - We try to support a wide range of C compilers to compile git with, + - We try to support a wide range of C compilers to compile Git with, including old ones. That means that you should not use C99 initializers, even if a lot of compilers grok it. @@ -164,14 +164,14 @@ For C programs: - If you are planning a new command, consider writing it in shell or perl first, so that changes in semantics can be easily - changed and discussed. Many git commands started out like + changed and discussed. Many Git commands started out like that, and a few are still scripts. - - Avoid introducing a new dependency into git. This means you + - Avoid introducing a new dependency into Git. This means you usually should stay away from scripting languages not already - used in the git core command set (unless your command is clearly + used in the Git core command set (unless your command is clearly separate from it, such as an importer to convert random-scm-X - repositories to git). + repositories to Git). - When we pass <string, length> pair to functions, we should try to pass them in that order. @@ -230,3 +230,8 @@ Writing Documentation: valid usage. "*" has its own pair of brackets, because it can (optionally) be specified only when one or more of the letters is also provided. + + A note on notation: + Use 'git' (all lowercase) when talking about commands i.e. something + the user would type into a shell and use 'Git' (uppercase first letter) + when talking about the version control system and its properties. |