From: Junio C Hamano Date: Thu, 2 Nov 2006 00:22:48 +0000 (+0000) Subject: Autogenerated HTML docs for v1.4.3.3-g7854 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=a2ec14f96e29dae631eb6013e11e0f03dc934660;p=git.git Autogenerated HTML docs for v1.4.3.3-g7854 --- diff --git a/config.txt b/config.txt index 026d4cf9a..d9e73da2a 100644 --- a/config.txt +++ b/config.txt @@ -71,12 +71,16 @@ core.preferSymlinkRefs:: expect HEAD to be a symbolic link. core.logAllRefUpdates:: - If true, `git-update-ref` will append a line to - "$GIT_DIR/logs/" listing the new SHA1 and the date/time - of the update. If the file does not exist it will be - created automatically. This information can be used to - determine what commit was the tip of a branch "2 days ago". - This value is false by default (no logging). + Updates to a ref is logged to the file + "$GIT_DIR/logs/", by appending the new and old + SHA1, the date/time and the reason of the update, but + only when the file exists. If this configuration + variable is set to true, missing "$GIT_DIR/logs/" + file is automatically created for branch heads. + + This information can be used to determine what commit + was the tip of a branch "2 days ago". This value is + false by default (no automated creation of log files). core.repositoryFormatVersion:: Internal variable identifying the repository format and layout diff --git a/git-pack-objects.html b/git-pack-objects.html index 74fd36eb0..852847122 100644 --- a/git-pack-objects.html +++ b/git-pack-objects.html @@ -310,9 +310,8 @@ base-name <base-name> to determine the name of the created file. When this option is used, the two files are written in <base-name>-<SHA1>.{pack,idx} files. <SHA1> is a hash - of object names (currently in random order so it does - not have any useful meaning) to make the resulting - filename reasonably unique, and written to the standard + of the sorted object names to make the resulting filename + based on the pack content, and written to the standard output of the command.

@@ -463,7 +462,7 @@ base-name diff --git a/git-pack-objects.txt b/git-pack-objects.txt index a1e55054b..9bd1e39fe 100644 --- a/git-pack-objects.txt +++ b/git-pack-objects.txt @@ -47,9 +47,8 @@ base-name:: to determine the name of the created file. When this option is used, the two files are written in -.{pack,idx} files. is a hash - of object names (currently in random order so it does - not have any useful meaning) to make the resulting - filename reasonably unique, and written to the standard + of the sorted object names to make the resulting filename + based on the pack content, and written to the standard output of the command. --stdout:: diff --git a/git-repo-config.html b/git-repo-config.html index 1e0b2cddb..31fb042ca 100644 --- a/git-repo-config.html +++ b/git-repo-config.html @@ -603,13 +603,19 @@ core.logAllRefUpdates

- If true, git-update-ref will append a line to - "$GIT_DIR/logs/<ref>" listing the new SHA1 and the date/time - of the update. If the file does not exist it will be - created automatically. This information can be used to - determine what commit was the tip of a branch "2 days ago". - This value is false by default (no logging). + Updates to a ref <ref> is logged to the file + "$GIT_DIR/logs/<ref>", by appending the new and old + SHA1, the date/time and the reason of the update, but + only when the file exists. If this configuration + variable is set to true, missing "$GIT_DIR/logs/<ref>" + file is automatically created for branch heads.

+
+
+
This information can be used to determine what commit
+was the tip of a branch "2 days ago".  This value is
+false by default (no automated creation of log files).
+
core.repositoryFormatVersion @@ -1072,7 +1078,7 @@ receive.denyNonFastforwads diff --git a/git-show-ref.html b/git-show-ref.html new file mode 100644 index 000000000..cfaa94d64 --- /dev/null +++ b/git-show-ref.html @@ -0,0 +1,449 @@ + + + + + + +git-show-ref(1) + + + +

SYNOPSIS

+
+
+
git-show-ref [-q|--quiet] [--verify] [-h|--head] [-d|--dereference] + [-s|--hash] [--abbrev] [--tags] [--heads] [--] <pattern>…
+
+

DESCRIPTION

+
+

Displays references available in a local repository along with the associated +commit IDs. Results can be filtered using a pattern and tags can be +dereferenced into object IDs. Additionally, it can be used to test whether a +particular ref exists.

+

Use of this utility is encouraged in favor of directly accessing files under +in the .git directory.

+
+

OPTIONS

+
+
+
+-h, --head +
+
+

+ Show the HEAD reference. +

+
+
+--tags, --heads +
+
+

+ Limit to only "refs/heads" and "refs/tags", respectively. These + options are not mutually exclusive; when given both, references stored + in "refs/heads" and "refs/tags" are displayed. +

+
+
+-d, --dereference +
+
+

+ Dereference tags into object IDs as well. They will be shown with "^{}" + appended. +

+
+
+-s, --hash +
+
+

+ Only show the SHA1 hash, not the reference name. When also using + --dereference the dereferenced tag will still be shown after the SHA1. +

+
+
+--verify +
+
+

+ Enable stricter reference checking by requiring an exact ref path. + Aside from returning an error code of 1, it will also print an error + message if --quiet was not specified. +

+
+
+--abbrev, --abbrev=len +
+
+

+ Abbreviate the object name. When using --hash, you do + not have to say --hash --abbrev; --hash=len would do. +

+
+
+-q, --quiet +
+
+

+ Do not print any results to stdout. When combined with --verify this + can be used to silently check if a reference exists. +

+
+
+<pattern> +
+
+

+ Show references matching one or more patterns. +

+
+
+
+

OUTPUT

+
+

The output is in the format: <SHA-1 ID> <space> <reference name>.

+
+
+
$ git show-ref --head --dereference
+832e76a9899f560a90ffd62ae2ce83bbeff58f54 HEAD
+832e76a9899f560a90ffd62ae2ce83bbeff58f54 refs/heads/master
+832e76a9899f560a90ffd62ae2ce83bbeff58f54 refs/heads/origin
+3521017556c5de4159da4615a39fa4d5d2c279b5 refs/tags/v0.99.9c
+6ddc0964034342519a87fe013781abf31c6db6ad refs/tags/v0.99.9c^{}
+055e4ae3ae6eb344cbabf2a5256a49ea66040131 refs/tags/v1.0rc4
+423325a2d24638ddcc82ce47be5e40be550f4507 refs/tags/v1.0rc4^{}
+...
+
+

When using --hash (and not --dereference) the output format is: <SHA-1 ID>

+
+
+
$ git show-ref --heads --hash
+2e3ba0114a1f52b47df29743d6915d056be13278
+185008ae97960c8d551adcd9e23565194651b5d1
+03adf42c988195b50e1a1935ba5fcbc39b2b029b
+...
+
+
+

EXAMPLE

+
+

To show all references called "master", whether tags or heads or anything +else, and regardless of how deep in the reference naming hierarchy they are, +use:

+
+
+
        git show-ref master
+
+

This will show "refs/heads/master" but also "refs/remote/other-repo/master", +if such references exists.

+

When using the --verify flag, the command requires an exact path:

+
+
+
        git show-ref --verify refs/heads/master
+
+

will only match the exact branch called "master".

+

If nothing matches, git-show-ref(1) will return an error code of 1, +and in the case of verification, it will show an error message.

+

For scripting, you can ask it to be quiet with the "--quiet" flag, which +allows you to do things like

+
+
+
        git-show-ref --quiet --verify -- "refs/heads/$headname" ||
+                echo "$headname is not a valid branch"
+
+

to check whether a particular branch exists or not (notice how we don't +actually want to show any results, and we want to use the full refname for it +in order to not trigger the problem with ambiguous partial matches).

+

To show only tags, or only proper branch heads, use "--tags" and/or "--heads" +respectively (using both means that it shows tags and heads, but not other +random references under the refs/ subdirectory).

+

To do automatic tag object dereferencing, use the "-d" or "--dereference" +flag, so you can do

+
+
+
        git show-ref --tags --dereference
+
+

to get a listing of all tags together with what they dereference.

+
+

SEE ALSO

+ +

AUTHORS

+
+

Written by Linus Torvalds <torvalds@osdl.org>. +Man page by Jonas Fonseca <fonseca@diku.dk>.

+
+

GIT

+
+

Part of the git(7) suite

+
+ + + diff --git a/git-show-ref.txt b/git-show-ref.txt new file mode 100644 index 000000000..5973a8251 --- /dev/null +++ b/git-show-ref.txt @@ -0,0 +1,156 @@ +git-show-ref(1) +=============== + +NAME +---- +git-show-ref - List references in a local repository + +SYNOPSIS +-------- +[verse] +'git-show-ref' [-q|--quiet] [--verify] [-h|--head] [-d|--dereference] + [-s|--hash] [--abbrev] [--tags] [--heads] [--] ... + +DESCRIPTION +----------- + +Displays references available in a local repository along with the associated +commit IDs. Results can be filtered using a pattern and tags can be +dereferenced into object IDs. Additionally, it can be used to test whether a +particular ref exists. + +Use of this utility is encouraged in favor of directly accessing files under +in the `.git` directory. + +OPTIONS +------- + +-h, --head:: + + Show the HEAD reference. + +--tags, --heads:: + + Limit to only "refs/heads" and "refs/tags", respectively. These + options are not mutually exclusive; when given both, references stored + in "refs/heads" and "refs/tags" are displayed. + +-d, --dereference:: + + Dereference tags into object IDs as well. They will be shown with "^{}" + appended. + +-s, --hash:: + + Only show the SHA1 hash, not the reference name. When also using + --dereference the dereferenced tag will still be shown after the SHA1. + +--verify:: + + Enable stricter reference checking by requiring an exact ref path. + Aside from returning an error code of 1, it will also print an error + message if '--quiet' was not specified. + +--abbrev, --abbrev=len:: + + Abbreviate the object name. When using `--hash`, you do + not have to say `--hash --abbrev`; `--hash=len` would do. + +-q, --quiet:: + + Do not print any results to stdout. When combined with '--verify' this + can be used to silently check if a reference exists. + +:: + + Show references matching one or more patterns. + +OUTPUT +------ + +The output is in the format: '' '' ''. + +----------------------------------------------------------------------------- +$ git show-ref --head --dereference +832e76a9899f560a90ffd62ae2ce83bbeff58f54 HEAD +832e76a9899f560a90ffd62ae2ce83bbeff58f54 refs/heads/master +832e76a9899f560a90ffd62ae2ce83bbeff58f54 refs/heads/origin +3521017556c5de4159da4615a39fa4d5d2c279b5 refs/tags/v0.99.9c +6ddc0964034342519a87fe013781abf31c6db6ad refs/tags/v0.99.9c^{} +055e4ae3ae6eb344cbabf2a5256a49ea66040131 refs/tags/v1.0rc4 +423325a2d24638ddcc82ce47be5e40be550f4507 refs/tags/v1.0rc4^{} +... +----------------------------------------------------------------------------- + +When using --hash (and not --dereference) the output format is: '' + +----------------------------------------------------------------------------- +$ git show-ref --heads --hash +2e3ba0114a1f52b47df29743d6915d056be13278 +185008ae97960c8d551adcd9e23565194651b5d1 +03adf42c988195b50e1a1935ba5fcbc39b2b029b +... +----------------------------------------------------------------------------- + +EXAMPLE +------- + +To show all references called "master", whether tags or heads or anything +else, and regardless of how deep in the reference naming hierarchy they are, +use: + +----------------------------------------------------------------------------- + git show-ref master +----------------------------------------------------------------------------- + +This will show "refs/heads/master" but also "refs/remote/other-repo/master", +if such references exists. + +When using the '--verify' flag, the command requires an exact path: + +----------------------------------------------------------------------------- + git show-ref --verify refs/heads/master +----------------------------------------------------------------------------- + +will only match the exact branch called "master". + +If nothing matches, gitlink:git-show-ref[1] will return an error code of 1, +and in the case of verification, it will show an error message. + +For scripting, you can ask it to be quiet with the "--quiet" flag, which +allows you to do things like + +----------------------------------------------------------------------------- + git-show-ref --quiet --verify -- "refs/heads/$headname" || + echo "$headname is not a valid branch" +----------------------------------------------------------------------------- + +to check whether a particular branch exists or not (notice how we don't +actually want to show any results, and we want to use the full refname for it +in order to not trigger the problem with ambiguous partial matches). + +To show only tags, or only proper branch heads, use "--tags" and/or "--heads" +respectively (using both means that it shows tags and heads, but not other +random references under the refs/ subdirectory). + +To do automatic tag object dereferencing, use the "-d" or "--dereference" +flag, so you can do + +----------------------------------------------------------------------------- + git show-ref --tags --dereference +----------------------------------------------------------------------------- + +to get a listing of all tags together with what they dereference. + +SEE ALSO +-------- +gitlink:git-ls-remote[1], gitlink:git-peek-remote[1] + +AUTHORS +------- +Written by Linus Torvalds . +Man page by Jonas Fonseca . + +GIT +--- +Part of the gitlink:git[7] suite diff --git a/git-update-ref.html b/git-update-ref.html index c60eb855f..d2f076494 100644 --- a/git-update-ref.html +++ b/git-update-ref.html @@ -272,7 +272,7 @@ git-update-ref(1) Manual Page

SYNOPSIS

-

git-update-ref [-m <reason>] <ref> <newvalue> [<oldvalue>]

+

git-update-ref [-m <reason>] (-d <ref> <oldvalue> | <ref> <newvalue> [<oldvalue>])

DESCRIPTION

@@ -284,7 +284,9 @@ possibly dereferencing the symbolic refs, after verifying that the current value of the <ref> matches <oldvalue>. E.g. git-update-ref refs/heads/master <newvalue> <oldvalue> updates the master branch head to <newvalue> only if its current -value is <oldvalue>.

+value is <oldvalue>. You can specify 40 "0" or an empty string +as <oldvalue> to make sure that the ref you are creating does +not exist.

It also allows a "ref" file to be a symbolic pointer to another ref file by starting with the four-byte header sequence of "ref:".

@@ -311,6 +313,8 @@ that point to "outside" the tree are safe: they'll be followed for reading but not for writing (so we'll never write through a ref symlink to some other tree, if you have copied a whole archive by creating a symlink tree).

+

With -d flag, it deletes the named <ref> after verifying it +still contains <oldvalue>.

Logging Updates

@@ -354,7 +358,7 @@ or does not have committer information available.

diff --git a/git-update-ref.txt b/git-update-ref.txt index e062030e9..71bcb7954 100644 --- a/git-update-ref.txt +++ b/git-update-ref.txt @@ -7,7 +7,7 @@ git-update-ref - update the object name stored in a ref safely SYNOPSIS -------- -'git-update-ref' [-m ] [] +'git-update-ref' [-m ] (-d | []) DESCRIPTION ----------- @@ -20,7 +20,9 @@ possibly dereferencing the symbolic refs, after verifying that the current value of the matches . E.g. `git-update-ref refs/heads/master ` updates the master branch head to only if its current -value is . +value is . You can specify 40 "0" or an empty string +as to make sure that the ref you are creating does +not exist. It also allows a "ref" file to be a symbolic pointer to another ref file by starting with the four-byte header sequence of @@ -49,6 +51,10 @@ for reading but not for writing (so we'll never write through a ref symlink to some other tree, if you have copied a whole archive by creating a symlink tree). +With `-d` flag, it deletes the named after verifying it +still contains . + + Logging Updates --------------- If config parameter "core.logAllRefUpdates" is true or the file