SubmittingPatches: note on whitespaces
Signed-off-by: Junio C Hamano <junkio@cox.net>
Junio C Hamano committed
Feb 17, 2006 at 16:15 UTC
45d2b286acf4a1191e6199c41a034cb0677a0965
1 file changed
+19
-11
Documentation/SubmittingPatches
+19
-11
@@ -4,8 +4,8 @@ it for the core GIT to make sure people understand what they are
4
doing when they write "Signed-off-by" line.
5
6
But the patch submission requirements are a lot more relaxed
7
-here, because the core GIT is thousand times smaller ;-). So
8
-here is only the relevant bits.
7
+here on the technical/contents front, because the core GIT is
8
+thousand times smaller ;-). So here is only the relevant bits.
9
10
11
(1) Make separate commits for logically separate changes.
@@ -18,13 +18,19 @@ repository. It is a good discipline.
18
19
Describe the technical detail of the change(s).
20
21
-If your description starts to get long, that's a sign that you
21
+If your description starts to get too long, that's a sign that you
22
probably need to split up your commit to finer grained pieces.
23
24
+Oh, another thing. I am picky about whitespaces. Make sure your
25
+changes do not trigger errors with the sample pre-commit hook shipped
26
+in templates/hooks--pre-commit.
27
25
-(2) Generate your patch using git/cogito out of your commits.
28
27
-git diff tools generate unidiff which is the preferred format.
29
+(2) Generate your patch using git tools out of your commits.
30
+
31
+git based diff tools (git, Cogito, and StGIT included) generate
32
+unidiff which is the preferred format.
33
+
34
You do not have to be afraid to use -M option to "git diff" or
35
"git format-patch", if your patch involves file renames. The
36
receiving end can handle them just fine.
@@ -33,20 +39,22 @@ Please make sure your patch does not include any extra files
39
which do not belong in a patch submission. Make sure to review
40
your patch after generating it, to ensure accuracy. Before
41
sending out, please make sure it cleanly applies to the "master"
36
-branch head.
42
+branch head. If you are preparing a work based on "next" branch,
43
+that is fine, but please mark it as such.
44
45
46
(3) Sending your patches.
47
41
-People on the git mailing list needs to be able to read and
48
+People on the git mailing list need to be able to read and
49
comment on the changes you are submitting. It is important for
50
a developer to be able to "quote" your changes, using standard
51
e-mail tools, so that they may comment on specific portions of
45
-your code. For this reason, all patches should be submitting
46
-e-mail "inline". WARNING: Be wary of your MUAs word-wrap
47
-corrupting your patch. Do not cut-n-paste your patch.
52
+your code. For this reason, all patches should be submited
53
+"inline". WARNING: Be wary of your MUAs word-wrap
54
+corrupting your patch. Do not cut-n-paste your patch; you can
55
+lose tabs that way if you are not careful.
56
49
-It is common convention to prefix your subject line with
57
+It is a common convention to prefix your subject line with
58
[PATCH]. This lets people easily distinguish patches from other
59
e-mail discussions.
60