X-Git-Url: https://git.tokkee.org/?p=tig.git;a=blobdiff_plain;f=tig.1.txt;h=490a0a247008663da6e0fc021150f09255e634ff;hp=4b8a73529b1054c71b11510d39577158cd752d9b;hb=43fec2264a6cdffc083123ef412d79c95ec44371;hpb=158a522c5740123fd1144f9045ef0a419dfcf090 diff --git a/tig.1.txt b/tig.1.txt index 4b8a735..490a0a2 100644 --- a/tig.1.txt +++ b/tig.1.txt @@ -1,4 +1,4 @@ -TIG(1) +tig(1) ====== NAME @@ -8,12 +8,11 @@ tig - text-mode interface for git SYNOPSIS -------- [verse] -tig [options] -tig [options] [--] [git options] -tig [options] log [git options] -tig [options] diff [git options] -tig [options] show [git options] -tig [options] < [git command output] +tig [options] [revisions] [--] [paths] +tig show [options] [revisions] [--] [paths] +tig blame [options] [rev] path +tig status +tig < [git command output] DESCRIPTION ----------- @@ -30,18 +29,23 @@ to colorize it. OPTIONS ------- --l:: - Start up in log view using the internal log command. +Command line options recognized by tig include all valid git-log(1) and +git-diff(1) options, as well as the following subcommands and tig specific +options. The first command line parameter not starting with "-" is interpreted +as being either a revision specification or a path and will end the option +parsing. All following options will be passed untouched to the underlying git +command. --d:: - Start up in diff view using the internal diff command. +show:: + Open diff view using the given git-show(1) options. --n[INTERVAL], --line-number[=INTERVAL]:: - Prefix line numbers in log and diff view. - Optionally, with interval different than each line. +blame:: + Show given file annotated by commits. + Takes zero or more git-blame(1) options. + Optionally limited from given revision. --b[NSPACES], --tab-size[=NSPACES]:: - Set the number of spaces tabs should be expanded to. +status:: + Start up in status view. -v, --version:: Show version and exit. @@ -49,75 +53,87 @@ OPTIONS -h, --help:: Show help message and exit. -\--:: - End of tig(1) options. Useful when specifying command - options for the main view. Example: +EXAMPLES +-------- - $ tig -- --since=1.month +Display the current branch: +----------------------------------------------------------------------------- +$ tig +----------------------------------------------------------------------------- + +Display one or more specific branches: +----------------------------------------------------------------------------- +$ tig test master +----------------------------------------------------------------------------- + +Display all branches: +----------------------------------------------------------------------------- +$ tig --all +----------------------------------------------------------------------------- + +Display differences between two branches: +----------------------------------------------------------------------------- +$ tig test..master +----------------------------------------------------------------------------- + +Display changes for a single file: +----------------------------------------------------------------------------- +$ tig -- README +----------------------------------------------------------------------------- + +Display contents of the README file in a specific revision: +----------------------------------------------------------------------------- +$ tig show tig-0.8:README +----------------------------------------------------------------------------- + +Display revisions between two dates for a specific file: +----------------------------------------------------------------------------- +$ tig --after="2004-01-01" --before="2006-05-16" -- README +----------------------------------------------------------------------------- -log:: - Open log view using the given git log options. +ENVIRONMENT VARIABLES +--------------------- -diff:: - Open diff view using the given git diff options. +In addition to environment variables used by git (e.g. GIT_DIR), tig defines +the ones below. The command related environment variables have access to the +internal state of tig via replacement variables, such as `%(commit)` and +`%(blob)`. See manpage:tigrc[5] for a full list. -show:: - Open diff view using the given git show options. +TIGRC_USER:: + Path of the user configuration file (defaults to `~/.tigrc`). -[git options]:: - tig(1) will stop the option parsing when the first - command line parameter not starting with "-" is - encountered. All options including this one will be - passed to git log when loading the main view. - This makes it possible to say: +TIGRC_SYSTEM:: + Path of the system wide configuration file (defaults to + `{sysconfdir}/tigrc`). - $ tig tag-1.0..HEAD - -ENVIRONMENT VARIABLES ---------------------- TIG_LS_REMOTE:: Set command for retrieving all repository references. The command should output data in the same format as git-ls-remote(1). -TIG_DIFF_CMD:: - The command used for the diff view. By default, git show is used - as a backend. - -TIG_LOG_CMD:: - The command used for the log view. If you prefer to have both - author and committer shown in the log view be sure to pass - `--pretty=fuller` to git log. - -TIG_MAIN_CMD:: - The command used for the main view. Note, you must always specify - the option: `--pretty=raw` since the main view parser expects to - read that format. - -Tree commands -~~~~~~~~~~~~~ -TIG_TREE_CMD:: - The command used for the tree view. By default, git-ls-tree(1) is - used. The commands should expect first the commit ID and second - a path. - -TIG_BLOB_CMD:: - The command used for the blob view. By default, git-cat-file(1) is - used. The command gets the blob ID. +TIG_DIFF_OPTS:: + The diff options to use in the diff view. The diff view uses + git-show(1) for formatting and always passes --patch-with-stat, + --find-copies-harder, and -C. FILES ----- '~/.tigrc':: - User configuration file. See gitlink:tigrc[5] for examples. + User configuration file. See manpage:tigrc[5] for examples. + +'{sysconfdir}/tigrc':: + System wide configuration file. -'.git/config':: - Repository config file. Read on start-up with the help of - git-repo-config(1). +'$GIT_DIR/config':: +'~/.gitconfig:: +'{sysconfdir}/etc/gitconfig:: + Git configuration files. Read on start-up with the help of + git-config(1). include::BUGS[] COPYRIGHT --------- -Copyright (c) 2006 Jonas Fonseca +Copyright (c) 2006-2010 Jonas Fonseca This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -127,8 +143,7 @@ the Free Software Foundation; either version 2 of the License, or SEE ALSO -------- -gitlink:tigrc[5], git(7), cogito(7), as well as other git repository browsers: -gitk(1), qgit(1), gitview(1). +manpage:tigrc[5], manpage:tigmanual[7], git(7), gitk(1) Online resources: