]> granicus.if.org Git - strace/commitdiff
doc: update commit requirements
authorEugene Syromyatnikov <evgsyr@gmail.com>
Wed, 14 Mar 2018 19:43:47 +0000 (20:43 +0100)
committerDmitry V. Levin <ldv@altlinux.org>
Fri, 16 Mar 2018 00:55:58 +0000 (00:55 +0000)
* README-hacking (Requirements): Enhance phrasing.
(Commit log requirements): Rename to "Commit requirements",
describe "absence of whitespace errors" requirement, add references
to the Linux kernel coding style and scripts/checkpatch.pl script.

Co-Authored-by: Dmitry V. Levin <ldv@altlinux.org>
README-hacking

index ff8ce12e21f306afe0ef61e8c56b6731fdde9d57..5ee0eda9dea31a5f659f8426bfcab82843533e43 100644 (file)
@@ -1,6 +1,7 @@
 Requirements
 ============
-If you use the GIT version of strace, please refer to INSTALL-git.md file.
+If you use a GIT version of strace source code, please refer to
+INSTALL-git.md file for building and installation instructions.
 
 
 No more ChangeLog file
@@ -13,13 +14,28 @@ the top-level ChangeLog file from logs at "make dist" time.  As such,
 there are strict requirements on the form of the commit log messages.
 
 
-Commit log requirements
-=======================
-Each commit log should always start with a one-line summary, the second
+Commit requirements
+===================
+Each commit message should always start with a one-line summary, the second
 line should be blank, and the remaining lines are usually ChangeLog-style
 entries for all affected files, except the leading TABs which should
 be omitted.
 
+Changes must not introduce whitespace errors in git sense (trailing
+whitespace, spaces before tabs, spaces for indentation, blank lines
+at the end of file), this can be checked with the following command:
+
+       git -c core.whitespace=space-before-tab,trailing-space diff-index \
+               --check 4b825dc642cb6eb9a060e54bf8d69288fbee4904
+
+It is also preferred (but not required) that commit patches pass
+scripts/checkpatch.pl script from the Linux kernel[1], as currently established
+coding style quite closely resembles the one used in Linux kernel[2], with some
+exceptions.
+
+[1] https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/plain/scripts/checkpatch.pl
+[2] https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/plain/Documentation/process/coding-style.rst
+
 
 Documentation
 =============