{"thread":{"id":"24293","subject":"[RFC/PATCH 0/3] Documentation: Improve revision documentation","startedAt":"2010-07-05T16:11:38Z","lastAt":"2010-07-14T16:49:44Z","messageCount":8,"participants":["Michael J Gruber","Ævar Arnfjörð Bjarmason","Stephen Boyd"],"isPatch":true,"patchVersion":1,"patchTotal":3},"messages":[{"id":"144827","messageId":"cover.1278346173.git.git@drmicha.warpmail.net","threadId":"24293","inReplyTo":null,"subject":"[RFC/PATCH 0/3] Documentation: Improve revision documentation","fromName":"Michael J Gruber","fromEmail":"git@drmicha.warpmail.net","sentAt":"2010-07-05T16:11:38Z","receivedAt":"2010-07-05T16:11:38Z","isPatch":true,"sender":{"key":"git@grubix.eu","avatar":"https://avatars.githubusercontent.com/u/233215?v=4"},"body":"This mini-series sets up a new gitrevisions(7) man page so that people\nlooking for revision syntax don't need to try to find it in\ngit-rev-parse(1) which is cluttered with a lot of unrelated stuff (it's\nplumbing after all).\n\nIf that concepts is OK, I actually suggest changing the actual content a\nbit. Also, I found a copule of typos around the areas which I touched\nbut saved this for an extension of this series.\n\nMichael J Gruber (3):\n  Documentation: split off rev doc into include file\n  Documentation: gitrevisions\n  Documentation: link to gitrevisions rather than git-rev-parse\n\n Documentation/Makefile                 |    2 +-\n Documentation/git-cat-file.txt         |    2 +-\n Documentation/git-check-ref-format.txt |    2 +-\n Documentation/git-cherry-pick.txt      |    4 +-\n Documentation/git-diff.txt             |    4 +-\n Documentation/git-fast-import.txt      |    2 +-\n Documentation/git-format-patch.txt     |    2 +-\n Documentation/git-log.txt              |    3 +-\n Documentation/git-push.txt             |    2 +-\n Documentation/git-reflog.txt           |    2 +-\n Documentation/git-rev-parse.txt        |  200 +-------------------------------\n Documentation/git-revert.txt           |    2 +-\n Documentation/git-show-branch.txt      |    2 +-\n Documentation/git-show.txt             |    2 +-\n Documentation/git.txt                  |    2 +-\n Documentation/gitcore-tutorial.txt     |    2 +-\n Documentation/gitk.txt                 |    2 +-\n Documentation/gitrevisions.txt         |   35 ++++++\n Documentation/revisions.txt            |  199 +++++++++++++++++++++++++++++++\n Documentation/user-manual.txt          |    8 +-\n 20 files changed, 257 insertions(+), 222 deletions(-)\n create mode 100644 Documentation/gitrevisions.txt\n create mode 100644 Documentation/revisions.txt\n"},{"id":"144828","messageId":"de012c816a5ead592e51e2aa26257ba3ef41a79a.1278346173.git.git@drmicha.warpmail.net","threadId":"24293","inReplyTo":"cover.1278346173.git.git@drmicha.warpmail.net","subject":"[RFC/PATCH 1/3] Documentation: split off rev doc into include file","fromName":"Michael J Gruber","fromEmail":"git@drmicha.warpmail.net","sentAt":"2010-07-05T16:11:39Z","receivedAt":"2010-07-05T16:11:39Z","isPatch":true,"sender":{"key":"git@grubix.eu","avatar":"https://avatars.githubusercontent.com/u/233215?v=4"},"body":"Currently, the documentation for revisions and ranges sits in the\ngit-rev-parse man page, i.e. a plumbing man page, along with the\ndocumentation of all rev-parse modes.\n\nSplit off the revisions and ranges section into an included file to\nprepare for restructuring.\n\nSigned-off-by: Michael J Gruber <git@drmicha.warpmail.net>\n---\n Documentation/git-rev-parse.txt |  200 +--------------------------------------\n Documentation/revisions.txt     |  199 ++++++++++++++++++++++++++++++++++++++\n 2 files changed, 200 insertions(+), 199 deletions(-)\n create mode 100644 Documentation/revisions.txt\n\ndiff --git a/Documentation/git-rev-parse.txt b/Documentation/git-rev-parse.txt\nindex 833a2a2..0727f43 100644\n--- a/Documentation/git-rev-parse.txt\n+++ b/Documentation/git-rev-parse.txt\n@@ -174,205 +174,7 @@ shown.  If the pattern does not contain a globbing character (`?`,\n \tFlags and parameters to be parsed.\n \n \n-SPECIFYING REVISIONS\n---------------------\n-\n-A revision parameter typically, but not necessarily, names a\n-commit object.  They use what is called an 'extended SHA1'\n-syntax.  Here are various ways to spell object names.  The\n-ones listed near the end of this list are to name trees and\n-blobs contained in a commit.\n-\n-* The full SHA1 object name (40-byte hexadecimal string), or\n-  a substring of such that is unique within the repository.\n-  E.g. dae86e1950b1277e545cee180551750029cfe735 and dae86e both\n-  name the same commit object if there are no other object in\n-  your repository whose object name starts with dae86e.\n-\n-* An output from 'git describe'; i.e. a closest tag, optionally\n-  followed by a dash and a number of commits, followed by a dash, a\n-  `g`, and an abbreviated object name.\n-\n-* A symbolic ref name.  E.g. 'master' typically means the commit\n-  object referenced by refs/heads/master.  If you\n-  happen to have both heads/master and tags/master, you can\n-  explicitly say 'heads/master' to tell git which one you mean.\n-  When ambiguous, a `<name>` is disambiguated by taking the\n-  first match in the following rules:\n-\n-  . if `$GIT_DIR/<name>` exists, that is what you mean (this is usually\n-    useful only for `HEAD`, `FETCH_HEAD`, `ORIG_HEAD` and `MERGE_HEAD`);\n-\n-  . otherwise, `refs/<name>` if exists;\n-\n-  . otherwise, `refs/tags/<name>` if exists;\n-\n-  . otherwise, `refs/heads/<name>` if exists;\n-\n-  . otherwise, `refs/remotes/<name>` if exists;\n-\n-  . otherwise, `refs/remotes/<name>/HEAD` if exists.\n-+\n-HEAD names the commit your changes in the working tree is based on.\n-FETCH_HEAD records the branch you fetched from a remote repository\n-with your last 'git fetch' invocation.\n-ORIG_HEAD is created by commands that moves your HEAD in a drastic\n-way, to record the position of the HEAD before their operation, so that\n-you can change the tip of the branch back to the state before you ran\n-them easily.\n-MERGE_HEAD records the commit(s) you are merging into your branch\n-when you run 'git merge'.\n-+\n-Note that any of the `refs/*` cases above may come either from\n-the `$GIT_DIR/refs` directory or from the `$GIT_DIR/packed-refs` file.\n-\n-* A ref followed by the suffix '@' with a date specification\n-  enclosed in a brace\n-  pair (e.g. '\\{yesterday\\}', '\\{1 month 2 weeks 3 days 1 hour 1\n-  second ago\\}' or '\\{1979-02-26 18:30:00\\}') to specify the value\n-  of the ref at a prior point in time.  This suffix may only be\n-  used immediately following a ref name and the ref must have an\n-  existing log ($GIT_DIR/logs/<ref>). Note that this looks up the state\n-  of your *local* ref at a given time; e.g., what was in your local\n-  `master` branch last week. If you want to look at commits made during\n-  certain times, see `--since` and `--until`.\n-\n-* A ref followed by the suffix '@' with an ordinal specification\n-  enclosed in a brace pair (e.g. '\\{1\\}', '\\{15\\}') to specify\n-  the n-th prior value of that ref.  For example 'master@\\{1\\}'\n-  is the immediate prior value of 'master' while 'master@\\{5\\}'\n-  is the 5th prior value of 'master'. This suffix may only be used\n-  immediately following a ref name and the ref must have an existing\n-  log ($GIT_DIR/logs/<ref>).\n-\n-* You can use the '@' construct with an empty ref part to get at a\n-  reflog of the current branch. For example, if you are on the\n-  branch 'blabla', then '@\\{1\\}' means the same as 'blabla@\\{1\\}'.\n-\n-* The special construct '@\\{-<n>\\}' means the <n>th branch checked out\n-  before the current one.\n-\n-* The suffix '@\\{upstream\\}' to a ref (short form 'ref@\\{u\\}') refers to\n-  the branch the ref is set to build on top of.  Missing ref defaults\n-  to the current branch.\n-\n-* A suffix '{caret}' to a revision parameter (e.g. 'HEAD{caret}') means the first parent of\n-  that commit object.  '{caret}<n>' means the <n>th parent (i.e.\n-  'rev{caret}'\n-  is equivalent to 'rev{caret}1').  As a special rule,\n-  'rev{caret}0' means the commit itself and is used when 'rev' is the\n-  object name of a tag object that refers to a commit object.\n-\n-* A suffix '{tilde}<n>' to a revision parameter means the commit\n-  object that is the <n>th generation grand-parent of the named\n-  commit object, following only the first parent.  I.e. rev~3 is\n-  equivalent to rev{caret}{caret}{caret} which is equivalent to\n-  rev{caret}1{caret}1{caret}1.  See below for a illustration of\n-  the usage of this form.\n-\n-* A suffix '{caret}' followed by an object type name enclosed in\n-  brace pair (e.g. `v0.99.8{caret}\\{commit\\}`) means the object\n-  could be a tag, and dereference the tag recursively until an\n-  object of that type is found or the object cannot be\n-  dereferenced anymore (in which case, barf).  `rev{caret}0`\n-  introduced earlier is a short-hand for `rev{caret}\\{commit\\}`.\n-\n-* A suffix '{caret}' followed by an empty brace pair\n-  (e.g. `v0.99.8{caret}\\{\\}`) means the object could be a tag,\n-  and dereference the tag recursively until a non-tag object is\n-  found.\n-\n-* A colon, followed by a slash, followed by a text (e.g. `:/fix nasty bug`): this names\n-  a commit whose commit message starts with the specified text.\n-  This name returns the youngest matching commit which is\n-  reachable from any ref.  If the commit message starts with a\n-  '!', you have to repeat that;  the special sequence ':/!',\n-  followed by something else than '!' is reserved for now.\n-\n-* A suffix ':' followed by a path (e.g. `HEAD:README`); this names the blob or tree\n-  at the given path in the tree-ish object named by the part\n-  before the colon.\n-  ':path' (with an empty part before the colon, e.g. `:README`)\n-  is a special case of the syntax described next: content\n-  recorded in the index at the given path.\n-\n-* A colon, optionally followed by a stage number (0 to 3) and a\n-  colon, followed by a path (e.g. `:0:README`); this names a blob object in the\n-  index at the given path. Missing stage number (and the colon\n-  that follows it, e.g. `:README`) names a stage 0 entry. During a merge, stage\n-  1 is the common ancestor, stage 2 is the target branch's version\n-  (typically the current branch), and stage 3 is the version from\n-  the branch being merged.\n-\n-Here is an illustration, by Jon Loeliger.  Both commit nodes B\n-and C are parents of commit node A.  Parent commits are ordered\n-left-to-right.\n-\n-........................................\n-G   H   I   J\n- \\ /     \\ /\n-  D   E   F\n-   \\  |  / \\\n-    \\ | /   |\n-     \\|/    |\n-      B     C\n-       \\   /\n-        \\ /\n-         A\n-........................................\n-\n-    A =      = A^0\n-    B = A^   = A^1     = A~1\n-    C = A^2  = A^2\n-    D = A^^  = A^1^1   = A~2\n-    E = B^2  = A^^2\n-    F = B^3  = A^^3\n-    G = A^^^ = A^1^1^1 = A~3\n-    H = D^2  = B^^2    = A^^^2  = A~2^2\n-    I = F^   = B^3^    = A^^3^\n-    J = F^2  = B^3^2   = A^^3^2\n-\n-\n-SPECIFYING RANGES\n------------------\n-\n-History traversing commands such as 'git log' operate on a set\n-of commits, not just a single commit.  To these commands,\n-specifying a single revision with the notation described in the\n-previous section means the set of commits reachable from that\n-commit, following the commit ancestry chain.\n-\n-To exclude commits reachable from a commit, a prefix `{caret}`\n-notation is used.  E.g. `{caret}r1 r2` means commits reachable\n-from `r2` but exclude the ones reachable from `r1`.\n-\n-This set operation appears so often that there is a shorthand\n-for it.  When you have two commits `r1` and `r2` (named according\n-to the syntax explained in SPECIFYING REVISIONS above), you can ask\n-for commits that are reachable from r2 excluding those that are reachable\n-from r1 by `{caret}r1 r2` and it can be written as `r1..r2`.\n-\n-A similar notation `r1\\...r2` is called symmetric difference\n-of `r1` and `r2` and is defined as\n-`r1 r2 --not $(git merge-base --all r1 r2)`.\n-It is the set of commits that are reachable from either one of\n-`r1` or `r2` but not from both.\n-\n-Two other shorthands for naming a set that is formed by a commit\n-and its parent commits exist.  The `r1{caret}@` notation means all\n-parents of `r1`.  `r1{caret}!` includes commit `r1` but excludes\n-all of its parents.\n-\n-Here are a handful of examples:\n-\n-   D                G H D\n-   D F              G H I J D F\n-   ^G D             H D\n-   ^D B             E I J F B\n-   B...C            G H D E B C\n-   ^D B C           E I J F B C\n-   C^@              I J F\n-   F^! D            G H D F\n+include::revisions.txt[]\n \n PARSEOPT\n --------\ndiff --git a/Documentation/revisions.txt b/Documentation/revisions.txt\nnew file mode 100644\nindex 0000000..fe846f0\n--- /dev/null\n+++ b/Documentation/revisions.txt\n@@ -0,0 +1,199 @@\n+SPECIFYING REVISIONS\n+--------------------\n+\n+A revision parameter typically, but not necessarily, names a\n+commit object.  They use what is called an 'extended SHA1'\n+syntax.  Here are various ways to spell object names.  The\n+ones listed near the end of this list are to name trees and\n+blobs contained in a commit.\n+\n+* The full SHA1 object name (40-byte hexadecimal string), or\n+  a substring of such that is unique within the repository.\n+  E.g. dae86e1950b1277e545cee180551750029cfe735 and dae86e both\n+  name the same commit object if there are no other object in\n+  your repository whose object name starts with dae86e.\n+\n+* An output from 'git describe'; i.e. a closest tag, optionally\n+  followed by a dash and a number of commits, followed by a dash, a\n+  `g`, and an abbreviated object name.\n+\n+* A symbolic ref name.  E.g. 'master' typically means the commit\n+  object referenced by refs/heads/master.  If you\n+  happen to have both heads/master and tags/master, you can\n+  explicitly say 'heads/master' to tell git which one you mean.\n+  When ambiguous, a `<name>` is disambiguated by taking the\n+  first match in the following rules:\n+\n+  . if `$GIT_DIR/<name>` exists, that is what you mean (this is usually\n+    useful only for `HEAD`, `FETCH_HEAD`, `ORIG_HEAD` and `MERGE_HEAD`);\n+\n+  . otherwise, `refs/<name>` if exists;\n+\n+  . otherwise, `refs/tags/<name>` if exists;\n+\n+  . otherwise, `refs/heads/<name>` if exists;\n+\n+  . otherwise, `refs/remotes/<name>` if exists;\n+\n+  . otherwise, `refs/remotes/<name>/HEAD` if exists.\n++\n+HEAD names the commit your changes in the working tree is based on.\n+FETCH_HEAD records the branch you fetched from a remote repository\n+with your last 'git fetch' invocation.\n+ORIG_HEAD is created by commands that moves your HEAD in a drastic\n+way, to record the position of the HEAD before their operation, so that\n+you can change the tip of the branch back to the state before you ran\n+them easily.\n+MERGE_HEAD records the commit(s) you are merging into your branch\n+when you run 'git merge'.\n++\n+Note that any of the `refs/*` cases above may come either from\n+the `$GIT_DIR/refs` directory or from the `$GIT_DIR/packed-refs` file.\n+\n+* A ref followed by the suffix '@' with a date specification\n+  enclosed in a brace\n+  pair (e.g. '\\{yesterday\\}', '\\{1 month 2 weeks 3 days 1 hour 1\n+  second ago\\}' or '\\{1979-02-26 18:30:00\\}') to specify the value\n+  of the ref at a prior point in time.  This suffix may only be\n+  used immediately following a ref name and the ref must have an\n+  existing log ($GIT_DIR/logs/<ref>). Note that this looks up the state\n+  of your *local* ref at a given time; e.g., what was in your local\n+  `master` branch last week. If you want to look at commits made during\n+  certain times, see `--since` and `--until`.\n+\n+* A ref followed by the suffix '@' with an ordinal specification\n+  enclosed in a brace pair (e.g. '\\{1\\}', '\\{15\\}') to specify\n+  the n-th prior value of that ref.  For example 'master@\\{1\\}'\n+  is the immediate prior value of 'master' while 'master@\\{5\\}'\n+  is the 5th prior value of 'master'. This suffix may only be used\n+  immediately following a ref name and the ref must have an existing\n+  log ($GIT_DIR/logs/<ref>).\n+\n+* You can use the '@' construct with an empty ref part to get at a\n+  reflog of the current branch. For example, if you are on the\n+  branch 'blabla', then '@\\{1\\}' means the same as 'blabla@\\{1\\}'.\n+\n+* The special construct '@\\{-<n>\\}' means the <n>th branch checked out\n+  before the current one.\n+\n+* The suffix '@\\{upstream\\}' to a ref (short form 'ref@\\{u\\}') refers to\n+  the branch the ref is set to build on top of.  Missing ref defaults\n+  to the current branch.\n+\n+* A suffix '{caret}' to a revision parameter (e.g. 'HEAD{caret}') means the first parent of\n+  that commit object.  '{caret}<n>' means the <n>th parent (i.e.\n+  'rev{caret}'\n+  is equivalent to 'rev{caret}1').  As a special rule,\n+  'rev{caret}0' means the commit itself and is used when 'rev' is the\n+  object name of a tag object that refers to a commit object.\n+\n+* A suffix '{tilde}<n>' to a revision parameter means the commit\n+  object that is the <n>th generation grand-parent of the named\n+  commit object, following only the first parent.  I.e. rev~3 is\n+  equivalent to rev{caret}{caret}{caret} which is equivalent to\n+  rev{caret}1{caret}1{caret}1.  See below for a illustration of\n+  the usage of this form.\n+\n+* A suffix '{caret}' followed by an object type name enclosed in\n+  brace pair (e.g. `v0.99.8{caret}\\{commit\\}`) means the object\n+  could be a tag, and dereference the tag recursively until an\n+  object of that type is found or the object cannot be\n+  dereferenced anymore (in which case, barf).  `rev{caret}0`\n+  introduced earlier is a short-hand for `rev{caret}\\{commit\\}`.\n+\n+* A suffix '{caret}' followed by an empty brace pair\n+  (e.g. `v0.99.8{caret}\\{\\}`) means the object could be a tag,\n+  and dereference the tag recursively until a non-tag object is\n+  found.\n+\n+* A colon, followed by a slash, followed by a text (e.g. `:/fix nasty bug`): this names\n+  a commit whose commit message starts with the specified text.\n+  This name returns the youngest matching commit which is\n+  reachable from any ref.  If the commit message starts with a\n+  '!', you have to repeat that;  the special sequence ':/!',\n+  followed by something else than '!' is reserved for now.\n+\n+* A suffix ':' followed by a path (e.g. `HEAD:README`); this names the blob or tree\n+  at the given path in the tree-ish object named by the part\n+  before the colon.\n+  ':path' (with an empty part before the colon, e.g. `:README`)\n+  is a special case of the syntax described next: content\n+  recorded in the index at the given path.\n+\n+* A colon, optionally followed by a stage number (0 to 3) and a\n+  colon, followed by a path (e.g. `:0:README`); this names a blob object in the\n+  index at the given path. Missing stage number (and the colon\n+  that follows it, e.g. `:README`) names a stage 0 entry. During a merge, stage\n+  1 is the common ancestor, stage 2 is the target branch's version\n+  (typically the current branch), and stage 3 is the version from\n+  the branch being merged.\n+\n+Here is an illustration, by Jon Loeliger.  Both commit nodes B\n+and C are parents of commit node A.  Parent commits are ordered\n+left-to-right.\n+\n+........................................\n+G   H   I   J\n+ \\ /     \\ /\n+  D   E   F\n+   \\  |  / \\\n+    \\ | /   |\n+     \\|/    |\n+      B     C\n+       \\   /\n+        \\ /\n+         A\n+........................................\n+\n+    A =      = A^0\n+    B = A^   = A^1     = A~1\n+    C = A^2  = A^2\n+    D = A^^  = A^1^1   = A~2\n+    E = B^2  = A^^2\n+    F = B^3  = A^^3\n+    G = A^^^ = A^1^1^1 = A~3\n+    H = D^2  = B^^2    = A^^^2  = A~2^2\n+    I = F^   = B^3^    = A^^3^\n+    J = F^2  = B^3^2   = A^^3^2\n+\n+\n+SPECIFYING RANGES\n+-----------------\n+\n+History traversing commands such as 'git log' operate on a set\n+of commits, not just a single commit.  To these commands,\n+specifying a single revision with the notation described in the\n+previous section means the set of commits reachable from that\n+commit, following the commit ancestry chain.\n+\n+To exclude commits reachable from a commit, a prefix `{caret}`\n+notation is used.  E.g. `{caret}r1 r2` means commits reachable\n+from `r2` but exclude the ones reachable from `r1`.\n+\n+This set operation appears so often that there is a shorthand\n+for it.  When you have two commits `r1` and `r2` (named according\n+to the syntax explained in SPECIFYING REVISIONS above), you can ask\n+for commits that are reachable from r2 excluding those that are reachable\n+from r1 by `{caret}r1 r2` and it can be written as `r1..r2`.\n+\n+A similar notation `r1\\...r2` is called symmetric difference\n+of `r1` and `r2` and is defined as\n+`r1 r2 --not $(git merge-base --all r1 r2)`.\n+It is the set of commits that are reachable from either one of\n+`r1` or `r2` but not from both.\n+\n+Two other shorthands for naming a set that is formed by a commit\n+and its parent commits exist.  The `r1{caret}@` notation means all\n+parents of `r1`.  `r1{caret}!` includes commit `r1` but excludes\n+all of its parents.\n+\n+Here are a handful of examples:\n+\n+   D                G H D\n+   D F              G H I J D F\n+   ^G D             H D\n+   ^D B             E I J F B\n+   B...C            G H D E B C\n+   ^D B C           E I J F B C\n+   C^@              I J F\n+   F^! D            G H D F\n-- \n1.7.1.621.g01d76\n"},{"id":"144829","messageId":"7efed85cefddff1cd2cc3a0e3802326306117f4e.1278346173.git.git@drmicha.warpmail.net","threadId":"24293","inReplyTo":"cover.1278346173.git.git@drmicha.warpmail.net","subject":"[RFC/PATCH 2/3] Documentation: gitrevisions","fromName":"Michael J Gruber","fromEmail":"git@drmicha.warpmail.net","sentAt":"2010-07-05T16:11:40Z","receivedAt":"2010-07-05T16:11:40Z","isPatch":true,"sender":{"key":"git@grubix.eu","avatar":"https://avatars.githubusercontent.com/u/233215?v=4"},"body":"Create a new man page gitrevisions(7) which contains the revsions and\nranges documentation but not more. This uses (per include) the same bits\nas the pertaining section of git-rev-parse(1).\n\nSigned-off-by: Michael J Gruber <git@drmicha.warpmail.net>\n---\n Documentation/Makefile         |    2 +-\n Documentation/gitrevisions.txt |   35 +++++++++++++++++++++++++++++++++++\n 2 files changed, 36 insertions(+), 1 deletions(-)\n create mode 100644 Documentation/gitrevisions.txt\n\ndiff --git a/Documentation/Makefile b/Documentation/Makefile\nindex 04f69cf..a4c4063 100644\n--- a/Documentation/Makefile\n+++ b/Documentation/Makefile\n@@ -6,7 +6,7 @@ MAN5_TXT=gitattributes.txt gitignore.txt gitmodules.txt githooks.txt \\\n \tgitrepository-layout.txt\n MAN7_TXT=gitcli.txt gittutorial.txt gittutorial-2.txt \\\n \tgitcvs-migration.txt gitcore-tutorial.txt gitglossary.txt \\\n-\tgitdiffcore.txt gitworkflows.txt\n+\tgitdiffcore.txt gitrevisions.txt gitworkflows.txt\n \n MAN_TXT = $(MAN1_TXT) $(MAN5_TXT) $(MAN7_TXT)\n MAN_XML=$(patsubst %.txt,%.xml,$(MAN_TXT))\ndiff --git a/Documentation/gitrevisions.txt b/Documentation/gitrevisions.txt\nnew file mode 100644\nindex 0000000..fc4789f\n--- /dev/null\n+++ b/Documentation/gitrevisions.txt\n@@ -0,0 +1,35 @@\n+gitrevisions(7)\n+================\n+\n+NAME\n+----\n+gitrevisions - specifying revisions and ranges for git\n+\n+SYNOPSIS\n+--------\n+gitrevisions\n+\n+\n+DESCRIPTION\n+-----------\n+\n+Many Git commands take revision parameters as arguments. Depending on\n+the command, they denote a specific commit or, for commands which\n+walk the revision graph (such as linkgit:git-log[1]), all commits which can\n+be reached from that commit. In the latter case one can also specify a\n+range of revisions explicitly.\n+\n+In addition, some Git commands (such as linkgit:git-show[1]) also take\n+revision parameters which denote other objects than commits, e.g. blobs\n+(\"files\") or trees (\"directories of files\").\n+\n+include::revisions.txt[]\n+\n+\n+SEE ALSO\n+--------\n+linkgit:git-rev-parse[1]\n+\n+GIT\n+---\n+Part of the linkgit:git[1] suite\n-- \n1.7.1.621.g01d76\n"},{"id":"144830","messageId":"38f9aae74cdb07aad5b65fd3c05e8ddaf91b943c.1278346173.git.git@drmicha.warpmail.net","threadId":"24293","inReplyTo":"cover.1278346173.git.git@drmicha.warpmail.net","subject":"[RFC/PATCH 3/3] Documentation: link to gitrevisions rather than git-rev-parse","fromName":"Michael J Gruber","fromEmail":"git@drmicha.warpmail.net","sentAt":"2010-07-05T16:11:41Z","receivedAt":"2010-07-05T16:11:41Z","isPatch":true,"sender":{"key":"git@grubix.eu","avatar":"https://avatars.githubusercontent.com/u/233215?v=4"},"body":"Currently, whenever we need documentation for revisions and ranges, we\nlink to the git-rev-parse man page, i.e. a plumbing man page, which has\nthis along with the documentation of all rev-parse modes.\n\nLink to the new gitrevisions man page instead in all cases except\n- when the actual git-rev-parse command is referred to or\n- in very technical context (git-send-pack).\n\nSigned-off-by: Michael J Gruber <git@drmicha.warpmail.net>\n---\n Documentation/git-cat-file.txt         |    2 +-\n Documentation/git-check-ref-format.txt |    2 +-\n Documentation/git-cherry-pick.txt      |    4 ++--\n Documentation/git-diff.txt             |    4 ++--\n Documentation/git-fast-import.txt      |    2 +-\n Documentation/git-format-patch.txt     |    2 +-\n Documentation/git-log.txt              |    3 +--\n Documentation/git-push.txt             |    2 +-\n Documentation/git-reflog.txt           |    2 +-\n Documentation/git-revert.txt           |    2 +-\n Documentation/git-show-branch.txt      |    2 +-\n Documentation/git-show.txt             |    2 +-\n Documentation/git.txt                  |    2 +-\n Documentation/gitcore-tutorial.txt     |    2 +-\n Documentation/gitk.txt                 |    2 +-\n Documentation/user-manual.txt          |    8 ++++----\n 16 files changed, 21 insertions(+), 22 deletions(-)\n\ndiff --git a/Documentation/git-cat-file.txt b/Documentation/git-cat-file.txt\nindex 9ebbe94..a3f56b0 100644\n--- a/Documentation/git-cat-file.txt\n+++ b/Documentation/git-cat-file.txt\n@@ -27,7 +27,7 @@ OPTIONS\n <object>::\n \tThe name of the object to show.\n \tFor a more complete list of ways to spell object names, see\n-\tthe \"SPECIFYING REVISIONS\" section in linkgit:git-rev-parse[1].\n+\tthe \"SPECIFYING REVISIONS\" section in linkgit:gitrevisions[1].\n \n -t::\n \tInstead of the content, show the object type identified by\ndiff --git a/Documentation/git-check-ref-format.txt b/Documentation/git-check-ref-format.txt\nindex 379eee6..f5c2e06 100644\n--- a/Documentation/git-check-ref-format.txt\n+++ b/Documentation/git-check-ref-format.txt\n@@ -49,7 +49,7 @@ git imposes the following rules on how references are named:\n These rules make it easy for shell script based tools to parse\n reference names, pathname expansion by the shell when a reference name is used\n unquoted (by mistake), and also avoids ambiguities in certain\n-reference name expressions (see linkgit:git-rev-parse[1]):\n+reference name expressions (see linkgit:gitrevisions[1]):\n \n . A double-dot `..` is often used as in `ref1..ref2`, and in some\n   contexts this notation means `{caret}ref1 ref2` (i.e. not in\ndiff --git a/Documentation/git-cherry-pick.txt b/Documentation/git-cherry-pick.txt\nindex ca485db..2cef579 100644\n--- a/Documentation/git-cherry-pick.txt\n+++ b/Documentation/git-cherry-pick.txt\n@@ -20,8 +20,8 @@ OPTIONS\n -------\n <commit>...::\n \tCommits to cherry-pick.\n-\tFor a more complete list of ways to spell commits, see the\n-\t\"SPECIFYING REVISIONS\" section in linkgit:git-rev-parse[1].\n+\tFor a more complete list of ways to spell commits, see\n+\tlinkgit:gitrevisions[1].\n \tSets of commits can be passed but no traversal is done by\n \tdefault, as if the '--no-walk' option was specified, see\n \tlinkgit:git-rev-list[1].\ndiff --git a/Documentation/git-diff.txt b/Documentation/git-diff.txt\nindex 723a648..08fd409 100644\n--- a/Documentation/git-diff.txt\n+++ b/Documentation/git-diff.txt\n@@ -68,11 +68,11 @@ for the last two forms that use \"..\" notations, can be any\n <tree-ish>.\n \n For a more complete list of ways to spell <commit>, see\n-\"SPECIFYING REVISIONS\" section in linkgit:git-rev-parse[1].\n+\"SPECIFYING REVISIONS\" section in linkgit:gitrevisions[1].\n However, \"diff\" is about comparing two _endpoints_, not ranges,\n and the range notations (\"<commit>..<commit>\" and\n \"<commit>\\...<commit>\") do not mean a range as defined in the\n-\"SPECIFYING RANGES\" section in linkgit:git-rev-parse[1].\n+\"SPECIFYING RANGES\" section in linkgit:gitrevisions[1].\n \n OPTIONS\n -------\ndiff --git a/Documentation/git-fast-import.txt b/Documentation/git-fast-import.txt\nindex 19082b0..77a0a24 100644\n--- a/Documentation/git-fast-import.txt\n+++ b/Documentation/git-fast-import.txt\n@@ -439,7 +439,7 @@ Marks must be declared (via `mark`) before they can be used.\n * A complete 40 byte or abbreviated commit SHA-1 in hex.\n \n * Any valid Git SHA-1 expression that resolves to a commit.  See\n-  ``SPECIFYING REVISIONS'' in linkgit:git-rev-parse[1] for details.\n+  ``SPECIFYING REVISIONS'' in linkgit:gitrevisions[1] for details.\n \n The special case of restarting an incremental import from the\n current branch value should be written as:\ndiff --git a/Documentation/git-format-patch.txt b/Documentation/git-format-patch.txt\nindex c8c81e8..4b3f5ba 100644\n--- a/Documentation/git-format-patch.txt\n+++ b/Documentation/git-format-patch.txt\n@@ -39,7 +39,7 @@ There are two ways to specify which commits to operate on.\n    that leads to the <since> to be output.\n \n 2. Generic <revision range> expression (see \"SPECIFYING\n-   REVISIONS\" section in linkgit:git-rev-parse[1]) means the\n+   REVISIONS\" section in linkgit:gitrevisions[1]) means the\n    commits in the specified range.\n \n The first rule takes precedence in the case of a single <commit>.  To\ndiff --git a/Documentation/git-log.txt b/Documentation/git-log.txt\nindex 0e6ff31..8a69647 100644\n--- a/Documentation/git-log.txt\n+++ b/Documentation/git-log.txt\n@@ -34,8 +34,7 @@ include::diff-options.txt[]\n \teither <since> or <until> is omitted, it defaults to\n \t`HEAD`, i.e. the tip of the current branch.\n \tFor a more complete list of ways to spell <since>\n-\tand <until>, see \"SPECIFYING REVISIONS\" section in\n-\tlinkgit:git-rev-parse[1].\n+\tand <until>, see linkgit:gitrevisions[1].\n \n --no-decorate::\n --decorate[=short|full|no]::\ndiff --git a/Documentation/git-push.txt b/Documentation/git-push.txt\nindex 4857024..b68abff 100644\n--- a/Documentation/git-push.txt\n+++ b/Documentation/git-push.txt\n@@ -41,7 +41,7 @@ OPTIONS[[OPTIONS]]\n +\n The <src> is often the name of the branch you would want to push, but\n it can be any arbitrary \"SHA-1 expression\", such as `master~4` or\n-`HEAD` (see linkgit:git-rev-parse[1]).\n+`HEAD` (see linkgit:gitrevisions[1]).\n +\n The <dst> tells which ref on the remote side is updated with this\n push. Arbitrary expressions cannot be used here, an actual ref must\ndiff --git a/Documentation/git-reflog.txt b/Documentation/git-reflog.txt\nindex 4eaa62b..5a0451a 100644\n--- a/Documentation/git-reflog.txt\n+++ b/Documentation/git-reflog.txt\n@@ -40,7 +40,7 @@ see linkgit:git-log[1].\n The reflog is useful in various git commands, to specify the old value\n of a reference. For example, `HEAD@\\{2\\}` means \"where HEAD used to be\n two moves ago\", `master@\\{one.week.ago\\}` means \"where master used to\n-point to one week ago\", and so on. See linkgit:git-rev-parse[1] for\n+point to one week ago\", and so on. See linkgit:gitrevisions[1] for\n more details.\n \n To delete single entries from the reflog, use the subcommand \"delete\"\ndiff --git a/Documentation/git-revert.txt b/Documentation/git-revert.txt\nindex dea4f53..b7d9ef7 100644\n--- a/Documentation/git-revert.txt\n+++ b/Documentation/git-revert.txt\n@@ -31,7 +31,7 @@ OPTIONS\n <commit>...::\n \tCommits to revert.\n \tFor a more complete list of ways to spell commit names, see\n-\t\"SPECIFYING REVISIONS\" section in linkgit:git-rev-parse[1].\n+\tlinkgit:gitrevisions[1].\n \tSets of commits can also be given but no traversal is done by\n \tdefault, see linkgit:git-rev-list[1] and its '--no-walk'\n \toption.\ndiff --git a/Documentation/git-show-branch.txt b/Documentation/git-show-branch.txt\nindex f1499bb..81ba296 100644\n--- a/Documentation/git-show-branch.txt\n+++ b/Documentation/git-show-branch.txt\n@@ -32,7 +32,7 @@ no <rev> nor <glob> is given on the command line.\n OPTIONS\n -------\n <rev>::\n-\tArbitrary extended SHA1 expression (see linkgit:git-rev-parse[1])\n+\tArbitrary extended SHA1 expression (see linkgit:gitrevisions[1])\n \tthat typically names a branch head or a tag.\n \n <glob>::\ndiff --git a/Documentation/git-show.txt b/Documentation/git-show.txt\nindex 55e687a..0002bfb 100644\n--- a/Documentation/git-show.txt\n+++ b/Documentation/git-show.txt\n@@ -36,7 +36,7 @@ OPTIONS\n <object>...::\n \tThe names of objects to show.\n \tFor a more complete list of ways to spell object names, see\n-\t\"SPECIFYING REVISIONS\" section in linkgit:git-rev-parse[1].\n+\t\"SPECIFYING REVISIONS\" section in linkgit:gitrevisions[1].\n \n include::pretty-options.txt[]\n \ndiff --git a/Documentation/git.txt b/Documentation/git.txt\nindex 8f0dd7f..12066ab 100644\n--- a/Documentation/git.txt\n+++ b/Documentation/git.txt\n@@ -479,7 +479,7 @@ HEAD::\n \t(i.e. the contents of `$GIT_DIR/refs/heads/<head>`).\n \n For a more complete list of ways to spell object names, see\n-\"SPECIFYING REVISIONS\" section in linkgit:git-rev-parse[1].\n+\"SPECIFYING REVISIONS\" section in linkgit:gitrevisions[1].\n \n \n File/Directory Structure\ndiff --git a/Documentation/gitcore-tutorial.txt b/Documentation/gitcore-tutorial.txt\nindex f7815e9..ed3ddc9 100644\n--- a/Documentation/gitcore-tutorial.txt\n+++ b/Documentation/gitcore-tutorial.txt\n@@ -971,7 +971,7 @@ commits from the master branch.  The string inside brackets\n before the commit log message is a short name you can use to\n name the commit.  In the above example, 'master' and 'mybranch'\n are branch heads.  'master^' is the first parent of 'master'\n-branch head.  Please see linkgit:git-rev-parse[1] if you want to\n+branch head.  Please see linkgit:gitrevisions[1] if you want to\n see more complex cases.\n \n [NOTE]\ndiff --git a/Documentation/gitk.txt b/Documentation/gitk.txt\nindex 99baa24..05ac1c7 100644\n--- a/Documentation/gitk.txt\n+++ b/Documentation/gitk.txt\n@@ -69,7 +69,7 @@ frequently used options.\n \tthe form \"'<from>'..'<to>'\" to show all revisions between '<from>' and\n \tback to '<to>'. Note, more advanced revision selection can be applied.\n \tFor a more complete list of ways to spell object names, see\n-\t\"SPECIFYING REVISIONS\" section in linkgit:git-rev-parse[1].\n+\tlinkgit:gitrevisions[1].\n \n <path>...::\n \ndiff --git a/Documentation/user-manual.txt b/Documentation/user-manual.txt\nindex fe6fb72..22aee34 100644\n--- a/Documentation/user-manual.txt\n+++ b/Documentation/user-manual.txt\n@@ -397,7 +397,7 @@ is usually a shortcut for the HEAD branch in the repository \"origin\".\n For the complete list of paths which git checks for references, and\n the order it uses to decide which to choose when there are multiple\n references with the same shorthand name, see the \"SPECIFYING\n-REVISIONS\" section of linkgit:git-rev-parse[1].\n+REVISIONS\" section of linkgit:gitrevisions[1].\n \n [[Updating-a-repository-With-git-fetch]]\n Updating a repository with git fetch\n@@ -568,7 +568,7 @@ We have seen several ways of naming commits already:\n \t- HEAD: refers to the head of the current branch\n \n There are many more; see the \"SPECIFYING REVISIONS\" section of the\n-linkgit:git-rev-parse[1] man page for the complete list of ways to\n+linkgit:gitrevisions[1] man page for the complete list of ways to\n name revisions.  Some examples:\n \n -------------------------------------------------\n@@ -909,7 +909,7 @@ commits reachable from some head but not from any tag in the repository:\n $ gitk $( git show-ref --heads ) --not  $( git show-ref --tags )\n -------------------------------------------------\n \n-(See linkgit:git-rev-parse[1] for explanations of commit-selecting\n+(See linkgit:gitrevisions[1] for explanations of commit-selecting\n syntax such as `--not`.)\n \n [[making-a-release]]\n@@ -1635,7 +1635,7 @@ you've checked out.\n The reflogs are kept by default for 30 days, after which they may be\n pruned.  See linkgit:git-reflog[1] and linkgit:git-gc[1] to learn\n how to control this pruning, and see the \"SPECIFYING REVISIONS\"\n-section of linkgit:git-rev-parse[1] for details.\n+section of linkgit:gitrevisions[1] for details.\n \n Note that the reflog history is very different from normal git history.\n While normal history is shared by every repository that works on the\n-- \n1.7.1.621.g01d76\n"},{"id":"144831","messageId":"AANLkTinEHbNFv-x1e4f6Jfi7sodNGSlKIPJMctFDSG7k@mail.gmail.com","threadId":"24293","inReplyTo":"cover.1278346173.git.git@drmicha.warpmail.net","subject":"Re: [RFC/PATCH 0/3] Documentation: Improve revision documentation","fromName":"Ævar Arnfjörð Bjarmason","fromEmail":"avarab@gmail.com","sentAt":"2010-07-05T17:26:06Z","receivedAt":"2010-07-05T17:26:06Z","isPatch":true,"sender":{"key":"avarab@gmail.com","avatar":"https://avatars.githubusercontent.com/u/45301?v=4"},"body":"On Mon, Jul 5, 2010 at 16:11, Michael J Gruber <git@drmicha.warpmail.net> wrote:\n> This mini-series sets up a new gitrevisions(7) man page so that people\n> looking for revision syntax don't need to try to find it in\n> git-rev-parse(1) which is cluttered with a lot of unrelated stuff (it's\n> plumbing after all).\n\nI like this series a lot. I often forget what our revision behavior is\nand whether it's documented in git-rev-list, git-rev-parse or\nsomething else. Then when I finally find it in git-rev-parse I have to\npage down the manpage to discover it.\n\nThis is definitely something that should be standalone in\ngitrevisions(7).\n\nAcked-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>\n"},{"id":"145515","messageId":"4C3D562B.3070404@gmail.com","threadId":"24293","inReplyTo":"7efed85cefddff1cd2cc3a0e3802326306117f4e.1278346173.git.git@drmicha.warpmail.net","subject":"Re: [RFC/PATCH 2/3] Documentation: gitrevisions","fromName":"Stephen Boyd","fromEmail":"bebarino@gmail.com","sentAt":"2010-07-14T06:16:11Z","receivedAt":"2010-07-14T06:16:11Z","isPatch":true,"sender":{"key":"bebarino@gmail.com","avatar":"https://avatars.githubusercontent.com/u/38832?v=4"},"body":"  On 07/05/2010 09:11 AM, Michael J Gruber wrote:\n> +\n> +DESCRIPTION\n> +-----------\n> +\n> +Many Git commands take revision parameters as arguments. Depending on\n> +the command, they denote a specific commit or, for commands which\n> +walk the revision graph (such as linkgit:git-log[1]), all commits which can\n> +be reached from that commit. In the latter case one can also specify a\n> +range of revisions explicitly.\n> +\n> +In addition, some Git commands (such as linkgit:git-show[1]) also take\n> +revision parameters which denote other objects than commits, e.g. blobs\n> +(\"files\") or trees (\"directories of files\").\n> +\n\nIs any of this text (section?) necessary besides including revisions.txt? It seems that revisions.txt nicely covers the types of revisions in the first paragraph of each section and these two paragraphs repeat that.\n\nCan you squash this in?\n\n--->8----\n\nindex fc4789f..0e25c5f 100644\n--- a/Documentation/gitrevisions.txt\n+++ b/Documentation/gitrevisions.txt\n@@ -10,19 +10,6 @@ SYNOPSIS\n  gitrevisions\n\n\n-DESCRIPTION\n------------\n-\n-Many Git commands take revision parameters as arguments. Depending on\n-the command, they denote a specific commit or, for commands which\n-walk the revision graph (such as linkgit:git-log[1]), all commits which can\n-be reached from that commit. In the latter case one can also specify a\n-range of revisions explicitly.\n-\n-In addition, some Git commands (such as linkgit:git-show[1]) also take\n-revision parameters which denote other objects than commits, e.g. blobs\n-(\"files\") or trees (\"directories of files\").\n-\n  include::revisions.txt[]\n"},{"id":"145519","messageId":"4C3D785D.1050000@drmicha.warpmail.net","threadId":"24293","inReplyTo":"4C3D562B.3070404@gmail.com","subject":"Re: [RFC/PATCH 2/3] Documentation: gitrevisions","fromName":"Michael J Gruber","fromEmail":"git@drmicha.warpmail.net","sentAt":"2010-07-14T08:42:05Z","receivedAt":"2010-07-14T08:42:05Z","isPatch":true,"sender":{"key":"git@grubix.eu","avatar":"https://avatars.githubusercontent.com/u/233215?v=4"},"body":"Stephen Boyd venit, vidit, dixit 14.07.2010 08:16:\n>   On 07/05/2010 09:11 AM, Michael J Gruber wrote:\n>> +\n>> +DESCRIPTION\n>> +-----------\n>> +\n>> +Many Git commands take revision parameters as arguments. Depending on\n>> +the command, they denote a specific commit or, for commands which\n>> +walk the revision graph (such as linkgit:git-log[1]), all commits which can\n>> +be reached from that commit. In the latter case one can also specify a\n>> +range of revisions explicitly.\n>> +\n>> +In addition, some Git commands (such as linkgit:git-show[1]) also take\n>> +revision parameters which denote other objects than commits, e.g. blobs\n>> +(\"files\") or trees (\"directories of files\").\n>> +\n> \n> Is any of this text (section?) necessary besides including revisions.txt? It seems that revisions.txt nicely covers the types of revisions in the first paragraph of each section and these two paragraphs repeat that.\n> \n> Can you squash this in?\n> \n> --->8----\n> \n> index fc4789f..0e25c5f 100644\n> --- a/Documentation/gitrevisions.txt\n> +++ b/Documentation/gitrevisions.txt\n> @@ -10,19 +10,6 @@ SYNOPSIS\n>   gitrevisions\n> \n> \n> -DESCRIPTION\n> ------------\n> -\n> -Many Git commands take revision parameters as arguments. Depending on\n> -the command, they denote a specific commit or, for commands which\n> -walk the revision graph (such as linkgit:git-log[1]), all commits which can\n> -be reached from that commit. In the latter case one can also specify a\n> -range of revisions explicitly.\n> -\n> -In addition, some Git commands (such as linkgit:git-show[1]) also take\n> -revision parameters which denote other objects than commits, e.g. blobs\n> -(\"files\") or trees (\"directories of files\").\n> -\n>   include::revisions.txt[]\n> \n> \n> \n\nI added this text on purpose. The \"DESCRIPTION\" section is meant to give\na concise description of the overall picture so that, e.g., you\nunderstand which section will answer which question without having to\nread all of them. In this case it gives you a short overview of what can\nbe referred to by revisions (commit, commit range, general object)\nbefore the sections go into the details of how to specify them.\n\nAlso, as I mentioned in the cover letter, I suggest a rework of the\nactual (included, old) content if that structure is to stay. So, in a\nsecond step, one could avoid duplications.\n\nBut here, I find it really natural (if not necessary) that the first\nparagraph in each detailed section picks up on the pertaining parts of\nthe concise description.\n\nMichael\n"},{"id":"145558","messageId":"4C3DEAA8.3090509@gmail.com","threadId":"24293","inReplyTo":"4C3D785D.1050000@drmicha.warpmail.net","subject":"Re: [RFC/PATCH 2/3] Documentation: gitrevisions","fromName":"Stephen Boyd","fromEmail":"bebarino@gmail.com","sentAt":"2010-07-14T16:49:44Z","receivedAt":"2010-07-14T16:49:44Z","isPatch":true,"sender":{"key":"bebarino@gmail.com","avatar":"https://avatars.githubusercontent.com/u/38832?v=4"},"body":"  On 07/14/2010 01:42 AM, Michael J Gruber wrote:\n>\n> I added this text on purpose. The \"DESCRIPTION\" section is meant to give\n> a concise description of the overall picture so that, e.g., you\n> understand which section will answer which question without having to\n> read all of them. In this case it gives you a short overview of what can\n> be referred to by revisions (commit, commit range, general object)\n> before the sections go into the details of how to specify them.\n>\n> Also, as I mentioned in the cover letter, I suggest a rework of the\n> actual (included, old) content if that structure is to stay. So, in a\n> second step, one could avoid duplications.\n\nOk, I must have missed that in the cover letter. I hope in the next version we can rework the old content and integrate it into the two paragraphs in this patch. I don't see how keeping the DESCRIPTION section this verbose is helpful. At most it should say:\n\nMany Git commands take revisions as parameters. A revision typically specifies a commit, but it can also specify a blob, a tree, or a set of commits. A set of commits is commonly referred to as a revision range. (or just range?)\n\nAnd then I wonder if that should just go in the SYNOPSIS section and the DESCRIPTION should be deleted.\n"}]}