Jump to navigation Jump to search
→‎Body of the commit message: clarify and expand with more specific exceptions
If there is more than one file touched in different ways and the one-line
description isn't enough to describe all changes, the commit message needsaa full-body description.
Individual files you touched get their Each individual file changed by a commmit must have its changes separately enumerated. Ifthere a particular C or For changes affecting specific C++ functions, each function you changed, the general format name islisted inparentheses. For example
* (class1::function1): Make change fooAdd something. (class2::function2, function3): Make change barDelete something else.
Note the newline for describing the change to a different function. GeneralFor changes affecting specific Octave built-ins, each built-in name is listedGNU style guidelines can be followed herein parentheses with an "F" prefix, so that similar changes todifferent files can be groupedan implementation detail.For example
<pre>* (Fcolumns): Return columns.</pre> When the same change is applied to a series of files, or to a set of functionsin a single file, the file or function names may be grouped to shorten thecommit message. For example: <pre>*,,, Include <sys/types.h>.* (function1, function2, function3): Throw error if empty.</pre> Each line of the commit message body should also be kept under 80 columns. TheGNU standards recommend starting a new line for each parenthesized function,but if the line is short enough, we often avoid an extra newline. For example <pre>* (function1): Add an option. (function2): Add another option.</pre> Only the last file name component is typically needed, since most files haveunique names across the entire repository. One notable exception are the{{codeline|}} files in every directory, they should include thecomplete directory and file name. For example <pre>* doc/interpreter/ (dist_man_MANS): Include foo.1 in the list.</pre> For m-script file and Fortran sources, the function name can be omitted ifthe filethe m-script contains only contains one filefunction. For changes outside of functionsor classes, of course the parenthetical (function) or (class::function)specifiers can also be omitted.
=== Wording ===


Navigation menu