/**
* \--::
- * End of tig(1) options. Useful when specifying commands
+ * End of tig(1) options. Useful when specifying command
* options for the main view. Example:
*
* $ tig -- --since=1.month
*
* $ tig log --pretty=fuller
*
- * See the "Specifying revisions" section below for an introduction
- * to revision options supported by the git commands. For
- * details on specific git command options, refer to the man
- * page of the command in question.
+ * See the <<refspec, "Specifying revisions">> section below
+ * for an introduction to revision options supported by the git
+ * commands. For details on specific git command options, refer
+ * to the man page of the command in question.
**/
if (opt_request == REQ_VIEW_MAIN)
"git ls-remote ."
/**
+ * [[view-commands]]
* View commands
* ~~~~~~~~~~~~~
* It is possible to alter which commands are used for the different views.
#define TIG_MAIN_CMD \
"git log --topo-order --stat --pretty=raw %s"
-/* We silently ignore that the following are also exported. */
+/* ... silently ignore that the following are also exported. */
#define TIG_HELP_CMD \
"man tig 2> /dev/null"
* z::
* Stop all background loading. This can be useful if you use
* tig(1) in a repository with a long history without limiting
- * the log output.
+ * the revision log.
* v::
* Show version.
* n::
}
/**
+ * [[refspec]]
* Specifying revisions
* --------------------
- * This section describes various ways to specify what revisions to
- * display or otherwise limit the view to.
+ * This section describes various ways to specify what revisions to display
+ * or otherwise limit the view to. Note, that tig(1) does not itself parse
+ * the described revision options.
+ *
+ * File history
+ * ------------
+ * If you are interested only in those revisions that made changes to a
+ * specific file (or even several files) list the files like this:
+ *
+ * $ tig log Makefile
+ *
+ * To avoid ambiguity with repository references such as tag name, be sure
+ * to separate file names from other git options using "\--". So if you
+ * have a file named 'master' it will clash with the reference named
+ * 'master', and thus you will have to use:
+ *
+ * $ tag log -- master
+ *
+ * NOTE: For the main view, avoiding ambiguity will in some cases require
+ * you to specify two "\--" options. The first will make tig(1) stop
+ * option processing and the latter will be passed to git log.
*
* Limit by date or number
* ~~~~~~~~~~~~~~~~~~~~~~~
* e.g. `--since=1.month` or limit by the number of commits using `-n400`.
*
* NOTE: You can tune the interaction with git by making use of the options
- * explained in this section.
- *
- * NOTE: tig(1) does not itself parse the revision options
- * described in this section.
+ * explained in this section. For example, by configuring the environment
+ * variables described in the <<view-commands, "View commands">> section.
*
* Ranges
* ~~~~~~