diff options
author | Junio C Hamano <gitster@pobox.com> | 2010-01-20 14:40:12 -0800 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2010-01-20 14:40:12 -0800 |
commit | 0877510ad4e8b951b08f9cbb25cfc0d994468979 (patch) | |
tree | dcfc43b1cf44ba49c3f9f206504d2f1cfee8bcc6 /Documentation | |
parent | 15a873d6e85d8089117a6a2141c8158bd370cf49 (diff) | |
parent | 1a893064d7b403625896a2c8bdab39f0f7db61d5 (diff) | |
download | git-0877510ad4e8b951b08f9cbb25cfc0d994468979.tar.gz git-0877510ad4e8b951b08f9cbb25cfc0d994468979.tar.xz |
Merge branch 'jk/warn-author-committer-after-commit'
* jk/warn-author-committer-after-commit:
user_ident_sufficiently_given(): refactor the logic to be usable from elsewhere
commit.c::print_summary: do not release the format string too early
commit: allow suppression of implicit identity advice
commit: show interesting ident information in summary
strbuf: add strbuf_addbuf_percentquote
strbuf_expand: convert "%%" to "%"
Conflicts:
builtin-commit.c
ident.c
Diffstat (limited to 'Documentation')
-rw-r--r-- | Documentation/config.txt | 4 | ||||
-rw-r--r-- | Documentation/pretty-formats.txt | 1 | ||||
-rw-r--r-- | Documentation/technical/api-strbuf.txt | 11 |
3 files changed, 16 insertions, 0 deletions
diff --git a/Documentation/config.txt b/Documentation/config.txt index 2d6775c13..d4332140a 100644 --- a/Documentation/config.txt +++ b/Documentation/config.txt @@ -130,6 +130,10 @@ advice.*:: Advice shown when linkgit:git-merge[1] refuses to merge to avoid overwritting local changes. Default: true. + implicitIdentity:: + Advice on how to set your identity configuration when + your information is guessed from the system username and + domain name. Default: true. -- core.fileMode:: diff --git a/Documentation/pretty-formats.txt b/Documentation/pretty-formats.txt index 53a9168ba..1686a54d2 100644 --- a/Documentation/pretty-formats.txt +++ b/Documentation/pretty-formats.txt @@ -134,6 +134,7 @@ The placeholders are: - '%C(...)': color specification, as described in color.branch.* config option - '%m': left, right or boundary mark - '%n': newline +- '%%': a raw '%' - '%x00': print a byte from a hex code - '%w([<w>[,<i1>[,<i2>]]])': switch line wrapping, like the -w option of linkgit:git-shortlog[1]. diff --git a/Documentation/technical/api-strbuf.txt b/Documentation/technical/api-strbuf.txt index a0e0f850f..afe275995 100644 --- a/Documentation/technical/api-strbuf.txt +++ b/Documentation/technical/api-strbuf.txt @@ -199,6 +199,10 @@ character if the letter `n` appears after a `%`. The function returns the length of the placeholder recognized and `strbuf_expand()` skips over it. + +The format `%%` is automatically expanded to a single `%` as a quoting +mechanism; callers do not need to handle the `%` placeholder themselves, +and the callback function will not be invoked for this placeholder. ++ All other characters (non-percent and not skipped ones) are copied verbatim to the strbuf. If the callback returned zero, meaning that the placeholder is unknown, then the percent sign is copied, too. @@ -214,6 +218,13 @@ which can be used by the programmer of the callback as she sees fit. placeholder and replacement string. The array needs to be terminated by an entry with placeholder set to NULL. +`strbuf_addbuf_percentquote`:: + + Append the contents of one strbuf to another, quoting any + percent signs ("%") into double-percents ("%%") in the + destination. This is useful for literal data to be fed to either + strbuf_expand or to the *printf family of functions. + `strbuf_addf`:: Add a formatted string to the buffer. |