From 0430e3a874bf1f6935be905e8539d77d41f48a62 Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Tue, 15 May 2007 03:13:17 +0000 Subject: [PATCH] Autogenerated HTML docs for v1.5.2-rc3-39-gaf9b --- RelNotes-1.5.1.5.txt | 37 ++ RelNotes-1.5.2.txt | 2 +- git-add.html | 9 +- git-add.txt | 7 +- git-am.html | 45 +- git-am.txt | 35 +- git-applymbox.html | 4 +- git-applymbox.txt | 2 +- git-diff-tree.html | 172 ++++---- git-diff-tree.txt | 5 +- git-log.html | 206 ++++----- git-log.txt | 5 +- git-mailinfo.html | 4 +- git-mailinfo.txt | 2 +- git-rev-list.html | 998 ++++++++++++++++++++++--------------------- git-rev-list.txt | 6 +- git-show.html | 76 ++-- git-show.txt | 3 + gitattributes.html | 8 +- gitattributes.txt | 6 +- pretty-formats.txt | 66 ++- pretty-options.txt | 14 + 22 files changed, 907 insertions(+), 805 deletions(-) create mode 100644 RelNotes-1.5.1.5.txt create mode 100644 pretty-options.txt diff --git a/RelNotes-1.5.1.5.txt b/RelNotes-1.5.1.5.txt new file mode 100644 index 000000000..5cfe0b5b0 --- /dev/null +++ b/RelNotes-1.5.1.5.txt @@ -0,0 +1,37 @@ +GIT v1.5.1.5 Release Notes (draft) +========================== + +Fixes since v1.5.1.4 +-------------------- + +* Bugfixes + + - git-svn was reported to segfault for many people on list and + #git; hopefully this has been fixed. + + - "git-svn clone" does not try to minimize the URL + (i.e. connect to higher level hierarchy) by default, as this + can prevent clone to fail if only part of the repository + (e.g. 'trunk') is open to public. + + - "git checkout branch^0" did not detach the head when you are + already on 'branch'; backported the fix from the 'master'. + + - "git-config section.var" did not correctly work when + existing configuration file had both [section] and [section "name"] + next to each other. + + - "git clone ../other-directory" was fooled if the current + directory $PWD points at is a symbolic link. + + - (build) tree_entry_extract() function was both static inline + and extern, which caused trouble compiling with Forte12 + compilers on Sun. + + - Many documentation fixes. + +-- +exec >/var/tmp/1 +O=v1.5.1.4-26-gb4b20b2 +echo O=`git describe refs/heads/maint` +git shortlog --no-merges $O..refs/heads/maint diff --git a/RelNotes-1.5.2.txt b/RelNotes-1.5.2.txt index d1c2cac4f..7dbdb2698 100644 --- a/RelNotes-1.5.2.txt +++ b/RelNotes-1.5.2.txt @@ -26,7 +26,7 @@ Updates since v1.5.1 considered a binary or text (the former would be treated by 'git diff' not to produce textual output; the latter can go through the line endings conversion process in repositories - with core.autocrlf set), expand and unexpand '$ident$' keyword + with core.autocrlf set), expand and unexpand '$Id$' keyword with blob object name, specify a custom 3-way merge driver, and specify a custom diff driver. You can also apply arbitrary filter to contents on check-in/check-out codepath diff --git a/git-add.html b/git-add.html index 48114b6bb..03df0ed72 100644 --- a/git-add.html +++ b/git-add.html @@ -347,8 +347,11 @@ commit.

- Update all files that git already knows about. This is what - "git commit -a" does in preparation for making a commit. + Update only files that git already knows about. This is similar + to what "git commit -a" does in preparation for making a commit, + except that the update is limited to paths specified on the + command line. If no paths are specified, all tracked files are + updated.

@@ -545,7 +548,7 @@ diff diff --git a/git-add.txt b/git-add.txt index ea2701846..27b9c0f8c 100644 --- a/git-add.txt +++ b/git-add.txt @@ -57,8 +57,11 @@ OPTIONS the index. -u:: - Update all files that git already knows about. This is what - "git commit -a" does in preparation for making a commit. + Update only files that git already knows about. This is similar + to what "git commit -a" does in preparation for making a commit, + except that the update is limited to paths specified on the + command line. If no paths are specified, all tracked files are + updated. \--:: This option can be used to separate command-line options from diff --git a/git-am.html b/git-am.html index f2a433f82..9984b7728 100644 --- a/git-am.html +++ b/git-am.html @@ -273,8 +273,9 @@ git-am(1) Manual Page

SYNOPSIS

-
git-am [--signoff] [--dotest=<dir>] [--utf8 | --no-utf8] [--binary] [--3way] - [--interactive] [--whitespace=<option>] [-C<n>] [-p<n>] +
git-am [--signoff] [--dotest=<dir>] [--keep] [--utf8 | --no-utf8] + [--3way] [--interactive] [--binary] + [--whitespace=<option>] [-C<n>] [-p<n>] <mbox>… git-am [--skip | --resolved]
@@ -329,7 +330,7 @@ current branch.

Pass -u flag to git-mailinfo (see git-mailinfo(1)). The proposed commit log message taken from the e-mail - are re-coded into UTF-8 encoding (configuration variable + is re-coded into UTF-8 encoding (configuration variable i18n.commitencoding can be used to specify project's preferred encoding if it is not UTF-8).

@@ -346,15 +347,6 @@ default. You could use --no-utf8 to override this.

--b, --binary -
-
-

- Pass --allow-binary-replacement flag to git-apply - (see git-apply(1)). -

-
-
-3, --3way
@@ -362,16 +354,16 @@ default. You could use --no-utf8 to override this.

When the patch does not apply cleanly, fall back on 3-way merge, if the patch records the identity of blobs it is supposed to apply to, and we have those blobs - locally. + available locally.

---skip +-b, --binary

- Skip the current patch. This is only meaningful when - restarting an aborted patch. + Pass --allow-binary-replacement flag to git-apply + (see git-apply(1)).

@@ -379,7 +371,8 @@ default. You could use --no-utf8 to override this.

- This flag is passed to the git-apply program that applies + This flag is passed to the git-apply (see git-apply(1)) + program that applies the patch.

@@ -388,7 +381,8 @@ default. You could use --no-utf8 to override this.

- These flags are passed to the git-apply program that applies + These flags are passed to the git-apply (see git-apply(1)) + program that applies the patch.

@@ -397,7 +391,16 @@ default. You could use --no-utf8 to override this.

- Run interactively, just like git-applymbox. + Run interactively. +

+
+
+--skip +
+
+

+ Skip the current patch. This is only meaningful when + restarting an aborted patch.

@@ -471,7 +474,7 @@ recover from this in one of two ways:

  1. -skip the current one by re-running the command with --skip +skip the current patch by re-running the command with --skip option.

  2. @@ -506,7 +509,7 @@ names.

    diff --git a/git-am.txt b/git-am.txt index f0405a35e..ba79773f7 100644 --- a/git-am.txt +++ b/git-am.txt @@ -9,9 +9,10 @@ git-am - Apply a series of patches from a mailbox SYNOPSIS -------- [verse] -'git-am' [--signoff] [--dotest=] [--utf8 | --no-utf8] [--binary] [--3way] - [--interactive] [--whitespace=

- Pretty-prints the details of a commit. --pretty - without an explicit =<format> defaults to medium. - If the commit is a merge, and if the pretty-format - is not oneline, email or raw, an additional line is - inserted before the Author: line. This line begins with - "Merge: " and the sha1s of ancestral commits are printed, - separated by spaces. Note that the listed commits may not - necessarily be the list of the direct parent commits if you - have limited your view of history: for example, if you are - only interested in changes related to a certain directory or - file. Here are some additional details for each format: + Pretty print the contents of the commit logs in a given format, + where <format> can be one of oneline, short, medium, + full, fuller, email, raw and format:<string>. + When left out the format default to medium.

+
+
+--encoding[=<encoding>] +
+
+

+ The commit objects record the encoding used for the log message + in their encoding header; this option can be used to tell the + command to re-code the commit log message in the encoding + preferred by the user. For non plumbing commands this + defaults to UTF-8. +

+
+
+-<n> +
+
+

+ Limits the number of commits to show. +

+
+
+<since>..<until> +
+
+

+ Show only commits between the named two commits. When + either <since> or <until> is omitted, it defaults to + HEAD, i.e. the tip of the current branch. + For a more complete list of ways to spell <since> + and <until>, see "SPECIFYING REVISIONS" section in + git-rev-parse(1). +

+
+
+--first-parent +
+
+

+ Follow only the first parent commit upon seeing a merge + commit. This option gives a better overview of the + evolution of a particular branch. +

+
+
+-p +
+
+

+ Show the change the commit introduces in a patch form. +

+
+
+-g, --walk-reflogs +
+
+

+ Show commits as they were recorded in the reflog. The log contains + a record about how the tip of a reference was changed. + See also git-reflog(1). +

+
+
+--decorate +
+
+

+ Print out the ref names of any commits that are shown. +

+
+
+<paths>… +
+
+

+ Show only commits that affect the specified paths. +

+
+ + +

PRETTY FORMATS

+
+

If the commit is a merge, and if the pretty-format +is not oneline, email or raw, an additional line is +inserted before the Author: line. This line begins with +"Merge: " and the sha1s of ancestral commits are printed, +separated by spaces. Note that the listed commits may not +necessarily be the list of the direct parent commits if you +have limited your view of history: for example, if you are +only interested in changes related to a certain directory or +file.

+

Here are some additional details for each format:

-
full commit message>
+
<full commit message>
  • @@ -422,14 +507,14 @@ simplification into account.

    you want to show. It works a little bit like printf format, with the notable exception that you get a newline with %n instead of \n.

    -
  • - - - -

    E.g, format:"The author of %h was %an, %ar%nThe title was >>%s<<" +

    E.g, format:"The author of %h was %an, %ar%nThe title was >>%s<<%n" would show something like this:

    -

    The author of fe6e0ee was Junio C Hamano, 23 hours ago -The title was >>t4119: test autocomputing -p<n> for traditional diff input.<<

    +
    +
    +
    The author of fe6e0ee was Junio C Hamano, 23 hours ago
    +The title was >>t4119: test autocomputing -p<n> for traditional diff input.<<
    +
    +

    The placeholders are:

    @@ -779,7 +787,7 @@ reversible operation.

    diff --git a/git-log.txt b/git-log.txt index dd06527a1..0f353f655 100644 --- a/git-log.txt +++ b/git-log.txt @@ -25,7 +25,7 @@ This manual page describes only the most frequently used options. OPTIONS ------- -include::pretty-formats.txt[] +include::pretty-options.txt[] -:: Limits the number of commits to show. @@ -58,6 +58,9 @@ include::pretty-formats.txt[] Show only commits that affect the specified paths. +include::pretty-formats.txt[] + + Examples -------- git log --no-merges:: diff --git a/git-mailinfo.html b/git-mailinfo.html index 5b5b6d2c7..5b24f53bd 100644 --- a/git-mailinfo.html +++ b/git-mailinfo.html @@ -297,7 +297,7 @@ command directly. See git-am(1) instead.

    whitespaces, (3) [ up to ], typically [PATCH], and then prepends "[PATCH] ". This flag forbids this munging, and is most useful when used to read back git - format-patch --mbox output. + format-patch -k output.

    @@ -357,7 +357,7 @@ Junio C Hamano <junkio@cox.net>

    diff --git a/git-mailinfo.txt b/git-mailinfo.txt index ba18133ea..8eadcebfc 100644 --- a/git-mailinfo.txt +++ b/git-mailinfo.txt @@ -30,7 +30,7 @@ OPTIONS whitespaces, (3) '[' up to ']', typically '[PATCH]', and then prepends "[PATCH] ". This flag forbids this munging, and is most useful when used to read back 'git - format-patch --mbox' output. + format-patch -k' output. -u:: The commit log message, author name and author email are diff --git a/git-rev-list.html b/git-rev-list.html index bd5c2cd13..e672e5aa2 100644 --- a/git-rev-list.html +++ b/git-rev-list.html @@ -347,282 +347,12 @@ more specialized family of commit log tools: git-log(1)

    - Pretty-prints the details of a commit. --pretty - without an explicit =<format> defaults to medium. - If the commit is a merge, and if the pretty-format - is not oneline, email or raw, an additional line is - inserted before the Author: line. This line begins with - "Merge: " and the sha1s of ancestral commits are printed, - separated by spaces. Note that the listed commits may not - necessarily be the list of the direct parent commits if you - have limited your view of history: for example, if you are - only interested in changes related to a certain directory or - file. Here are some additional details for each format: + Pretty print the contents of the commit logs in a given format, + where <format> can be one of oneline, short, medium, + full, fuller, email, raw and format:<string>. + When left out the format default to medium.

    -
      -
    • -

      -oneline -

      -
      -
      -
      <sha1> <title line>
      -
      -

      This is designed to be as compact as possible.

      -
    • -
    • -

      -short -

      -
      -
      -
      commit <sha1>
      -Author: <author>
      -
      -
      -
      -
      <title line>
      -
      -
    • -
    • -

      -medium -

      -
      -
      -
      commit <sha1>
      -Author: <author>
      -Date: <date>
      -
      -
      -
      -
      <title line>
      -
      -
      -
      -
      <full commit message>
      -
      -
    • -
    • -

      -full -

      -
      -
      -
      commit <sha1>
      -Author: <author>
      -Commit: <committer>
      -
      -
      -
      -
      <title line>
      -
      -
      -
      -
      <full commit message>
      -
      -
    • -
    • -

      -fuller -

      -
      -
      -
      commit <sha1>
      -Author: <author>
      -AuthorDate: <date & time>
      -Commit: <committer>
      -CommitDate: <date & time>
      -
      -
      -
      -
      <title line>
      -
      -
      -
      -
      <full commit message>
      -
      -
    • -
    • -

      -email -

      -
      -
      -
      From <sha1> <date>
      -From: <author>
      -Date: <date & time>
      -Subject: [PATCH] <title line>
      -
      -
      -
      -
      full commit message>
      -
      -
    • -
    • -

      -raw -

      -

      The raw format shows the entire commit exactly as -stored in the commit object. Notably, the SHA1s are -displayed in full, regardless of whether --abbrev or ---no-abbrev are used, and parents information show the -true parent commits, without taking grafts nor history -simplification into account.

      -
    • -
    • -

      -format: -

      -

      The format: format allows you to specify which information -you want to show. It works a little bit like printf format, -with the notable exception that you get a newline with %n -instead of \n.

      -
    • -
    - -

    E.g, format:"The author of %h was %an, %ar%nThe title was >>%s<<" -would show something like this:

    -

    The author of fe6e0ee was Junio C Hamano, 23 hours ago -The title was >>t4119: test autocomputing -p<n> for traditional diff input.<<

    -

    The placeholders are:

    -
      -
    • -

      -%H: commit hash -

      -
    • -
    • -

      -%h: abbreviated commit hash -

      -
    • -
    • -

      -%T: tree hash -

      -
    • -
    • -

      -%t: abbreviated tree hash -

      -
    • -
    • -

      -%P: parent hashes -

      -
    • -
    • -

      -%p: abbreviated parent hashes -

      -
    • -
    • -

      -%an: author name -

      -
    • -
    • -

      -%ae: author email -

      -
    • -
    • -

      -%ad: author date -

      -
    • -
    • -

      -%aD: author date, RFC2822 style -

      -
    • -
    • -

      -%ar: author date, relative -

      -
    • -
    • -

      -%at: author date, UNIX timestamp -

      -
    • -
    • -

      -%cn: committer name -

      -
    • -
    • -

      -%ce: committer email -

      -
    • -
    • -

      -%cd: committer date -

      -
    • -
    • -

      -%cD: committer date, RFC2822 style -

      -
    • -
    • -

      -%cr: committer date, relative -

      -
    • -
    • -

      -%ct: committer date, UNIX timestamp -

      -
    • -
    • -

      -%e: encoding -

      -
    • -
    • -

      -%s: subject -

      -
    • -
    • -

      -%b: body -

      -
    • -
    • -

      -%Cred: switch color to red -

      -
    • -
    • -

      -%Cgreen: switch color to green -

      -
    • -
    • -

      -%Cblue: switch color to blue -

      -
    • -
    • -

      -%Creset: reset color -

      -
    • -
    • -

      -%m: left, right or boundary mark -

      -
    • -
    • -

      -%n: newline -

      -
      --encoding[=<encoding>]
      @@ -707,8 +437,6 @@ e.g. "2 hours ago".

      -
    • -

    Diff Formatting

    Below are listed options that control the formatting of diff output. Some of them are specific to git-rev-list(1), however other diff @@ -719,319 +447,599 @@ options may be given. See git-diff-files(1) fo

    - This flag changes the way a merge commit is displayed. It shows - the differences from each of the parents to the merge result - simultaneously instead of showing pairwise diff between a parent - and the result one at a time. Furthermore, it lists only files - which were modified from all parents. + This flag changes the way a merge commit is displayed. It shows + the differences from each of the parents to the merge result + simultaneously instead of showing pairwise diff between a parent + and the result one at a time. Furthermore, it lists only files + which were modified from all parents. +

    +
    +
    +--cc +
    +
    +

    + This flag implies the -c options and further compresses the + patch output by omitting hunks that show differences from only + one parent, or show the same change from all but one parent for + an Octopus merge. +

    +
    +
    +-r +
    +
    +

    + Show recursive diffs. +

    +
    +
    +-t +
    +
    +

    + Show the tree objects in the diff output. This implies -r. +

    +
    + +

    Commit Limiting

    +

    Besides specifying a range of commits that should be listed using the +special notations explained in the description, additional commit +limiting may be applied.

    +
    +
    +-n number, --max-count=number +
    +
    +

    + Limit the number of commits output. +

    +
    +
    +--skip=number +
    +
    +

    + Skip number commits before starting to show the commit output. +

    +
    +
    +--since=date, --after=date +
    +
    +

    + Show commits more recent than a specific date. +

    +
    +
    +--until=date, --before=date +
    +
    +

    + Show commits older than a specific date. +

    +
    +
    +--max-age=timestamp, --min-age=timestamp +
    +
    +

    + Limit the commits output to specified time range. +

    +
    +
    +--author=pattern, --committer=pattern +
    +
    +

    + Limit the commits output to ones with author/committer + header lines that match the specified pattern. +

    +
    +
    +--grep=pattern +
    +
    +

    + Limit the commits output to ones with log message that + matches the specified pattern. +

    +
    +
    +--remove-empty +
    +
    +

    + Stop when a given path disappears from the tree. +

    +
    +
    +--no-merges +
    +
    +

    + Do not print commits with more than one parent. +

    +
    +
    +--not +
    +
    +

    + Reverses the meaning of the ^ prefix (or lack thereof) + for all following revision specifiers, up to the next --not. +

    +
    +
    +--all +
    +
    +

    + Pretend as if all the refs in $GIT_DIR/refs/ are listed on the + command line as <commit>. +

    +
    +
    +--stdin +
    +
    +

    + In addition to the <commit> listed on the command + line, read them from the standard input. +

    +
    +
    +--cherry-pick +
    +
    +

    + Omit any commit that introduces the same change as + another commit on the "other side" when the set of + commits are limited with symmetric difference.
    +For example, if you have two branches, A and B, a usual way +to list all commits on only one side of them is with +--left-right, like the example above in the description of +that option. It however shows the commits that were cherry-picked +from the other branch (for example, "3rd on b" may be cherry-picked +from branch A). With this option, such pairs of commits are +excluded from the output. +

    +
    +
    +-g, --walk-reflogs +
    +
    +

    + Instead of walking the commit ancestry chain, walk + reflog entries from the most recent one to older ones. + When this option is used you cannot specify commits to + exclude (that is, ^commit, commit1..commit2, + nor commit1…commit2 notations cannot be used).
    +With --pretty format other than oneline (for obvious reasons), +this causes the output to have two extra lines of information +used in the output. When the starting commit is specified as +instead. Under --pretty=oneline, the commit message is +prefixed with this information on the same line. +

    +
    +
    +--merge +
    +
    +

    + After a failed merge, show refs that touch files having a + conflict and don't exist on all heads to merge. +

    +
    +
    +--boundary +
    +
    +

    + Output uninteresting commits at the boundary, which are usually + not shown.

    ---cc +--dense, --sparse

    - This flag implies the -c options and further compresses the - patch output by omitting hunks that show differences from only - one parent, or show the same change from all but one parent for - an Octopus merge. +When optional paths are given, the default behaviour (--dense) is to +only output commits that changes at least one of them, and also ignore +merges that do not touch the given paths.

    +

    Use the --sparse flag to makes the command output all eligible commits +(still subject to count and age limitation), but apply merge +simplification nevertheless.

    --r +--bisect

    - Show recursive diffs. +Limit output to the one commit object which is roughly halfway between +the included and excluded commits. Thus, if

    +
    +
    +
            $ git-rev-list --bisect foo ^bar ^baz
    +
    +

    outputs midpoint, the output of the two commands

    +
    +
    +
            $ git-rev-list foo ^midpoint
    +        $ git-rev-list midpoint ^bar ^baz
    +
    +

    would be of roughly the same length. Finding the change which +introduces a regression is thus reduced to a binary search: repeatedly +generate and test new 'midpoint's until the commit chain is of length +one.

    --t +--bisect-vars

    - Show the tree objects in the diff output. This implies -r. +This calculates the same as --bisect, but outputs text ready +to be eval'ed by the shell. These lines will assign the name of +the midpoint revision to the variable bisect_rev, and the +expected number of commits to be tested after bisect_rev is +tested to bisect_nr, the expected number of commits to be +tested if bisect_rev turns out to be good to bisect_good, +the expected number of commits to be tested if bisect_rev +turns out to be bad to bisect_bad, and the number of commits +we are bisecting right now to bisect_all.

    -

    Commit Limiting

    -

    Besides specifying a range of commits that should be listed using the -special notations explained in the description, additional commit -limiting may be applied.

    +

    Commit Ordering

    +

    By default, the commits are shown in reverse chronological order.

    --n number, --max-count=number +--topo-order

    - Limit the number of commits output. + This option makes them appear in topological order (i.e. + descendant commits are shown before their parents).

    ---skip=number +--date-order

    - Skip number commits before starting to show the commit output. + This option is similar to --topo-order in the sense that no + parent comes before all of its children, but otherwise things + are still ordered in the commit timestamp order.

    ---since=date, --after=date +--reverse

    - Show commits more recent than a specific date. + Output the commits in reverse order.

    +
    +

    Object Traversal

    +

    These options are mostly targeted for packing of git repositories.

    +
    ---until=date, --before=date +--objects

    - Show commits older than a specific date. + Print the object IDs of any object referenced by the listed + commits. git-rev-list --objects foo ^bar thus means "send me + all object IDs which I need to download if I have the commit + object bar, but not foo".

    ---max-age=timestamp, --min-age=timestamp +--objects-edge

    - Limit the commits output to specified time range. + Similar to --objects, but also print the IDs of excluded + commits prefixed with a "-" character. This is used by + git-pack-objects(1) to build "thin" pack, which records + objects in deltified form based on objects contained in these + excluded commits to reduce network traffic.

    ---author=pattern, --committer=pattern +--unpacked

    - Limit the commits output to ones with author/committer - header lines that match the specified pattern. + Only useful with --objects; print the object IDs that are not + in packs. +

    +
    +
    + +

    PRETTY FORMATS

    +
    +

    If the commit is a merge, and if the pretty-format +is not oneline, email or raw, an additional line is +inserted before the Author: line. This line begins with +"Merge: " and the sha1s of ancestral commits are printed, +separated by spaces. Note that the listed commits may not +necessarily be the list of the direct parent commits if you +have limited your view of history: for example, if you are +only interested in changes related to a certain directory or +file.

    +

    Here are some additional details for each format:

    +
      +
    • +

      +oneline +

      +
      +
      +
      <sha1> <title line>
      +
      +

      This is designed to be as compact as possible.

      +
    • +
    • +

      +short +

      +
      +
      +
      commit <sha1>
      +Author: <author>
      +
      +
      +
      +
      <title line>
      +
      +
    • +
    • +

      +medium +

      +
      +
      +
      commit <sha1>
      +Author: <author>
      +Date: <date>
      +
      +
      +
      +
      <title line>
      +
      +
      +
      +
      <full commit message>
      +
      +
    • +
    • +

      +full +

      +
      +
      +
      commit <sha1>
      +Author: <author>
      +Commit: <committer>
      +
      +
      +
      +
      <title line>
      +
      +
      +
      +
      <full commit message>
      +
      +
    • +
    • +

      +fuller +

      +
      +
      +
      commit <sha1>
      +Author: <author>
      +AuthorDate: <date & time>
      +Commit: <committer>
      +CommitDate: <date & time>
      +
      +
      +
      +
      <title line>
      +
      +
      +
      +
      <full commit message>
      +
      +
    • +
    • +

      +email +

      +
      +
      +
      From <sha1> <date>
      +From: <author>
      +Date: <date & time>
      +Subject: [PATCH] <title line>
      +
      +
      +
      +
      <full commit message>
      +
      +
    • +
    • +

      +raw +

      +

      The raw format shows the entire commit exactly as +stored in the commit object. Notably, the SHA1s are +displayed in full, regardless of whether --abbrev or +--no-abbrev are used, and parents information show the +true parent commits, without taking grafts nor history +simplification into account.

      +
    • +
    • +

      +format: +

      +

      The format: format allows you to specify which information +you want to show. It works a little bit like printf format, +with the notable exception that you get a newline with %n +instead of \n.

      +

      E.g, format:"The author of %h was %an, %ar%nThe title was >>%s<<%n" +would show something like this:

      +
      +
      +
      The author of fe6e0ee was Junio C Hamano, 23 hours ago
      +The title was >>t4119: test autocomputing -p<n> for traditional diff input.<<
      +
      +
      +

      The placeholders are:

      +
        +
      • +

        +%H: commit hash +

        +
      • +
      • +

        +%h: abbreviated commit hash +

        +
      • +
      • +

        +%T: tree hash +

        +
      • +
      • +

        +%t: abbreviated tree hash +

        +
      • +
      • +

        +%P: parent hashes +

        +
      • +
      • +

        +%p: abbreviated parent hashes +

        +
      • +
      • +

        +%an: author name

        - -
        ---grep=pattern -
        -
        +
      • +
      • - Limit the commits output to ones with log message that - matches the specified pattern. +%ae: author email

        - -
        ---remove-empty -
        -
        +
      • +
      • - Stop when a given path disappears from the tree. +%ad: author date

        - -
        ---no-merges -
        -
        +
      • +
      • - Do not print commits with more than one parent. +%aD: author date, RFC2822 style

        - -
        ---not -
        -
        +
      • +
      • - Reverses the meaning of the ^ prefix (or lack thereof) - for all following revision specifiers, up to the next --not. +%ar: author date, relative

        - -
        ---all -
        -
        +
      • +
      • - Pretend as if all the refs in $GIT_DIR/refs/ are listed on the - command line as <commit>. +%at: author date, UNIX timestamp

        - -
        ---stdin -
        -
        +
      • +
      • - In addition to the <commit> listed on the command - line, read them from the standard input. +%cn: committer name

        - -
        ---cherry-pick -
        -
        +
      • +
      • - Omit any commit that introduces the same change as - another commit on the "other side" when the set of - commits are limited with symmetric difference.
        -For example, if you have two branches, A and B, a usual way -to list all commits on only one side of them is with ---left-right, like the example above in the description of -that option. It however shows the commits that were cherry-picked -from the other branch (for example, "3rd on b" may be cherry-picked -from branch A). With this option, such pairs of commits are -excluded from the output. +%ce: committer email

        - -
        --g, --walk-reflogs -
        -
        +
      • +
      • - Instead of walking the commit ancestry chain, walk - reflog entries from the most recent one to older ones. - When this option is used you cannot specify commits to - exclude (that is, ^commit, commit1..commit2, - nor commit1…commit2 notations cannot be used).
        -With --pretty format other than oneline (for obvious reasons), -this causes the output to have two extra lines of information -used in the output. When the starting commit is specified as -instead. Under --pretty=oneline, the commit message is -prefixed with this information on the same line. +%cd: committer date

        - -
        ---merge -
        -
        +
      • +
      • - After a failed merge, show refs that touch files having a - conflict and don't exist on all heads to merge. +%cD: committer date, RFC2822 style

        - -
        ---boundary -
        -
        +
      • +
      • - Output uninteresting commits at the boundary, which are usually - not shown. +%cr: committer date, relative

        - -
        ---dense, --sparse -
        -
        +
      • +
      • -When optional paths are given, the default behaviour (--dense) is to -only output commits that changes at least one of them, and also ignore -merges that do not touch the given paths. +%ct: committer date, UNIX timestamp

        -

        Use the --sparse flag to makes the command output all eligible commits -(still subject to count and age limitation), but apply merge -simplification nevertheless.

        - -
        ---bisect -
        -
        +
      • +
      • -Limit output to the one commit object which is roughly halfway between -the included and excluded commits. Thus, if +%e: encoding

        -
        -
        -
                $ git-rev-list --bisect foo ^bar ^baz
        -
        -

        outputs midpoint, the output of the two commands

        -
        -
        -
                $ git-rev-list foo ^midpoint
        -        $ git-rev-list midpoint ^bar ^baz
        -
        -

        would be of roughly the same length. Finding the change which -introduces a regression is thus reduced to a binary search: repeatedly -generate and test new 'midpoint's until the commit chain is of length -one.

        - -
        ---bisect-vars -
        -
        +
      • +
      • -This calculates the same as --bisect, but outputs text ready -to be eval'ed by the shell. These lines will assign the name of -the midpoint revision to the variable bisect_rev, and the -expected number of commits to be tested after bisect_rev is -tested to bisect_nr, the expected number of commits to be -tested if bisect_rev turns out to be good to bisect_good, -the expected number of commits to be tested if bisect_rev -turns out to be bad to bisect_bad, and the number of commits -we are bisecting right now to bisect_all. +%s: subject

        - - -

        Commit Ordering

        -

        By default, the commits are shown in reverse chronological order.

        -
        -
        ---topo-order -
        -
        +
      • +
      • - This option makes them appear in topological order (i.e. - descendant commits are shown before their parents). +%b: body

        - -
        ---date-order -
        -
        +
      • +
      • - This option is similar to --topo-order in the sense that no - parent comes before all of its children, but otherwise things - are still ordered in the commit timestamp order. +%Cred: switch color to red

        - -
        ---reverse -
        -
        +
      • +
      • - Output the commits in reverse order. +%Cgreen: switch color to green

        - - -

        Object Traversal

        -

        These options are mostly targeted for packing of git repositories.

        -
        -
        ---objects -
        -
        +
      • +
      • - Print the object IDs of any object referenced by the listed - commits. git-rev-list --objects foo ^bar thus means "send me - all object IDs which I need to download if I have the commit - object bar, but not foo". +%Cblue: switch color to blue

        - -
        ---objects-edge -
        -
        +
      • +
      • - Similar to --objects, but also print the IDs of excluded - commits prefixed with a "-" character. This is used by - git-pack-objects(1) to build "thin" pack, which records - objects in deltified form based on objects contained in these - excluded commits to reduce network traffic. +%Creset: reset color

        - -
        ---unpacked -
        -
        +
      • +
      • - Only useful with --objects; print the object IDs that are not - in packs. +%m: left, right or boundary mark

        - - +
      • +
      • +

        +%n: newline +

        +
      • +
      +
    • +

    Author

    @@ -1048,7 +1056,7 @@ and the git-list <git@vger.kernel.org>.

    diff --git a/git-rev-list.txt b/git-rev-list.txt index 1b12b4f2a..ab90a22f1 100644 --- a/git-rev-list.txt +++ b/git-rev-list.txt @@ -87,7 +87,7 @@ Using these options, gitlink:git-rev-list[1] will act similar to the more specialized family of commit log tools: gitlink:git-log[1], gitlink:git-show[1], and gitlink:git-whatchanged[1] -include::pretty-formats.txt[] +include::pretty-options.txt[] --relative-date:: @@ -367,6 +367,10 @@ These options are mostly targeted for packing of git repositories. Only useful with '--objects'; print the object IDs that are not in packs. + +include::pretty-formats.txt[] + + Author ------ Written by Linus Torvalds diff --git a/git-show.html b/git-show.html index 89d00eb3b..2731ef5e9 100644 --- a/git-show.html +++ b/git-show.html @@ -306,18 +306,38 @@ control how the changes the commit introduces are shown.

    - Pretty-prints the details of a commit. --pretty - without an explicit =<format> defaults to medium. - If the commit is a merge, and if the pretty-format - is not oneline, email or raw, an additional line is - inserted before the Author: line. This line begins with - "Merge: " and the sha1s of ancestral commits are printed, - separated by spaces. Note that the listed commits may not - necessarily be the list of the direct parent commits if you - have limited your view of history: for example, if you are - only interested in changes related to a certain directory or - file. Here are some additional details for each format: + Pretty print the contents of the commit logs in a given format, + where <format> can be one of oneline, short, medium, + full, fuller, email, raw and format:<string>. + When left out the format default to medium.

    +
    +
    +--encoding[=<encoding>] +
    +
    +

    + The commit objects record the encoding used for the log message + in their encoding header; this option can be used to tell the + command to re-code the commit log message in the encoding + preferred by the user. For non plumbing commands this + defaults to UTF-8. +

    +
    + + +

    PRETTY FORMATS

    +
    +

    If the commit is a merge, and if the pretty-format +is not oneline, email or raw, an additional line is +inserted before the Author: line. This line begins with +"Merge: " and the sha1s of ancestral commits are printed, +separated by spaces. Note that the listed commits may not +necessarily be the list of the direct parent commits if you +have limited your view of history: for example, if you are +only interested in changes related to a certain directory or +file.

    +

    Here are some additional details for each format:

    • @@ -415,7 +435,7 @@ Subject: [PATCH] <title line>

    -
    full commit message>
    +
    <full commit message>
  • @@ -437,14 +457,14 @@ simplification into account.

    you want to show. It works a little bit like printf format, with the notable exception that you get a newline with %n instead of \n.

    -
  • - - - -

    E.g, format:"The author of %h was %an, %ar%nThe title was >>%s<<" +

    E.g, format:"The author of %h was %an, %ar%nThe title was >>%s<<%n" would show something like this:

    -

    The author of fe6e0ee was Junio C Hamano, 23 hours ago -The title was >>t4119: test autocomputing -p<n> for traditional diff input.<<

    +
    +
    +
    The author of fe6e0ee was Junio C Hamano, 23 hours ago
    +The title was >>t4119: test autocomputing -p<n> for traditional diff input.<<
    +
    +

    The placeholders are:

    • @@ -581,20 +601,8 @@ The title was >>t4119: test autocomputing -p<n> for traditional diff

      %n: newline

      -
      -
      ---encoding[=<encoding>] -
      -
      -

      - The commit objects record the encoding used for the log message - in their encoding header; this option can be used to tell the - command to re-code the commit log message in the encoding - preferred by the user. For non plumbing commands this - defaults to UTF-8. -

      -
      -
      +
    • +
    @@ -731,7 +739,7 @@ Johannes Schindelin <Johannes.Schindelin@gmx.de>.

    diff --git a/git-show.txt b/git-show.txt index 5a219ab57..34c5caf2d 100644 --- a/git-show.txt +++ b/git-show.txt @@ -38,6 +38,9 @@ OPTIONS For a more complete list of ways to spell object names, see "SPECIFYING REVISIONS" section in gitlink:git-rev-parse[1]. +include::pretty-options.txt[] + + include::pretty-formats.txt[] diff --git a/gitattributes.html b/gitattributes.html index 770fcdb3a..46825d921 100644 --- a/gitattributes.html +++ b/gitattributes.html @@ -414,11 +414,11 @@ converted to LF upon checkin, but there is no conversion done upon checkout.

    ident

    When the attribute ident is set to a path, git replaces -$ident$ in the blob object with $ident:, followed by +$Id$ in the blob object with $Id:, followed by 40-character hexadecimal blob object name, followed by a dollar sign $ upon checkout. Any byte sequence that begins with -$ident: and ends with $ in the worktree file is replaced -with $ident$ upon check-in.

    +$Id: and ends with $ in the worktree file is replaced +with $Id$ upon check-in.

    Interaction between checkin/checkout attributes

    In the check-in codepath, the worktree file is first converted with ident (if specified), and then with crlf (again, if @@ -658,7 +658,7 @@ frotz unspecified

    diff --git a/gitattributes.txt b/gitattributes.txt index 87723105d..d3ac9c718 100644 --- a/gitattributes.txt +++ b/gitattributes.txt @@ -138,11 +138,11 @@ upon checkout. ^^^^^^^ When the attribute `ident` is set to a path, git replaces -`$ident$` in the blob object with `$ident:`, followed by +`$Id$` in the blob object with `$Id:`, followed by 40-character hexadecimal blob object name, followed by a dollar sign `$` upon checkout. Any byte sequence that begins with -`$ident:` and ends with `$` in the worktree file is replaced -with `$ident$` upon check-in. +`$Id:` and ends with `$` in the worktree file is replaced +with `$Id$` upon check-in. Interaction between checkin/checkout attributes diff --git a/pretty-formats.txt b/pretty-formats.txt index d7ffc21dd..d922e8e86 100644 --- a/pretty-formats.txt +++ b/pretty-formats.txt @@ -1,31 +1,32 @@ ---pretty[='']:: - - Pretty-prints the details of a commit. `--pretty` - without an explicit `=` defaults to 'medium'. - If the commit is a merge, and if the pretty-format - is not 'oneline', 'email' or 'raw', an additional line is - inserted before the 'Author:' line. This line begins with - "Merge: " and the sha1s of ancestral commits are printed, - separated by spaces. Note that the listed commits may not - necessarily be the list of the *direct* parent commits if you - have limited your view of history: for example, if you are - only interested in changes related to a certain directory or - file. Here are some additional details for each format: - - * 'oneline' +PRETTY FORMATS +-------------- + +If the commit is a merge, and if the pretty-format +is not 'oneline', 'email' or 'raw', an additional line is +inserted before the 'Author:' line. This line begins with +"Merge: " and the sha1s of ancestral commits are printed, +separated by spaces. Note that the listed commits may not +necessarily be the list of the *direct* parent commits if you +have limited your view of history: for example, if you are +only interested in changes related to a certain directory or +file. + +Here are some additional details for each format: + +* 'oneline' + This is designed to be as compact as possible. - * 'short' +* 'short' commit <sha1> Author: <author> <title line> - * 'medium' +* 'medium' commit <sha1> Author: <author> @@ -35,7 +36,7 @@ This is designed to be as compact as possible. <full commit message> - * 'full' +* 'full' commit <sha1> Author: <author> @@ -45,7 +46,7 @@ This is designed to be as compact as possible. <full commit message> - * 'fuller' +* 'fuller' commit <sha1> Author: <author> @@ -57,18 +58,16 @@ This is designed to be as compact as possible. <full commit message> - - * 'email' +* 'email' From <sha1> <date> From: <author> Date: <date & time> Subject: [PATCH] <title line> - full commit message> - + <full commit message> - * 'raw' +* 'raw' + The 'raw' format shows the entire commit exactly as stored in the commit object. Notably, the SHA1s are @@ -77,19 +76,22 @@ displayed in full, regardless of whether --abbrev or true parent commits, without taking grafts nor history simplification into account. - * 'format:' +* 'format:' + The 'format:' format allows you to specify which information you want to show. It works a little bit like printf format, with the notable exception that you get a newline with '%n' instead of '\n'. - -E.g, 'format:"The author of %h was %an, %ar%nThe title was >>%s<<"' ++ +E.g, 'format:"The author of %h was %an, %ar%nThe title was >>%s<<%n"' would show something like this: - ++ +------- The author of fe6e0ee was Junio C Hamano, 23 hours ago The title was >>t4119: test autocomputing -p<n> for traditional diff input.<< +-------- ++ The placeholders are: - '%H': commit hash @@ -120,11 +122,3 @@ The placeholders are: - '%m': left, right or boundary mark - '%n': newline - ---encoding[=<encoding>]:: - The commit objects record the encoding used for the log message - in their encoding header; this option can be used to tell the - command to re-code the commit log message in the encoding - preferred by the user. For non plumbing commands this - defaults to UTF-8. - diff --git a/pretty-options.txt b/pretty-options.txt new file mode 100644 index 000000000..7d515be0f --- /dev/null +++ b/pretty-options.txt @@ -0,0 +1,14 @@ +--pretty[='<format>']:: + + Pretty print the contents of the commit logs in a given format, + where '<format>' can be one of 'oneline', 'short', 'medium', + 'full', 'fuller', 'email', 'raw' and 'format:<string>'. + When left out the format default to 'medium'. + +--encoding[=<encoding>]:: + The commit objects record the encoding used for the log message + in their encoding header; this option can be used to tell the + command to re-code the commit log message in the encoding + preferred by the user. For non plumbing commands this + defaults to UTF-8. + -- 2.26.2