From c30f9936b0e5cdced3d9cb859ce0d325ebe9c91d Mon Sep 17 00:00:00 2001 From: "Shawn O. Pearce" Date: Thu, 22 May 2008 08:47:19 -0400 Subject: [PATCH 1/4] Clarify repack -n documentation While repacking a local repository a coworker thought the -n option was necessary to git-repack to keep it from updating some unknown file on the central server we all share. Explaining further what the option is (not) doing helps to make it clear the option does not impact any remote repositories the user may have configured. Signed-off-by: Shawn O. Pearce Signed-off-by: Junio C Hamano --- Documentation/git-repack.txt | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/Documentation/git-repack.txt b/Documentation/git-repack.txt index 3d957492f8..d14ab5154f 100644 --- a/Documentation/git-repack.txt +++ b/Documentation/git-repack.txt @@ -55,8 +55,11 @@ OPTIONS linkgit:git-pack-objects[1]. -n:: - Do not update the server information with - `git update-server-info`. + Do not update the server information with + `git update-server-info`. This option skips + updating local catalog files needed to publish + this repository (or a direct copy of it) + over HTTP or FTP. See gitlink:git-update-server-info[1]. --window=[N], --depth=[N]:: These two options affect how the objects contained in the pack are From 3a3e097b866b2785e44c008092884c853fd406cc Mon Sep 17 00:00:00 2001 From: Jon Loeliger Date: Thu, 22 May 2008 14:59:25 -0500 Subject: [PATCH 2/4] git-show.txt: Not very stubby these days. Signed-off-by: Jon Loeliger Signed-off-by: Junio C Hamano --- Documentation/git-show.txt | 2 -- 1 file changed, 2 deletions(-) diff --git a/Documentation/git-show.txt b/Documentation/git-show.txt index dccf0e20ec..29ed0acc62 100644 --- a/Documentation/git-show.txt +++ b/Documentation/git-show.txt @@ -79,8 +79,6 @@ Documentation ------------- Documentation by David Greaves, Petr Baudis and the git-list . -This manual page is a stub. You can help the git documentation by expanding it. - GIT --- Part of the linkgit:git[7] suite From 26b4d0039d84010bbfab2148395cc86f87b91286 Mon Sep 17 00:00:00 2001 From: Heikki Orsila Date: Thu, 22 May 2008 18:24:41 +0300 Subject: [PATCH 3/4] Add missing "short" alternative to --date in rev-list-options.txt Signed-off-by: Heikki Orsila Signed-off-by: Junio C Hamano --- Documentation/rev-list-options.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Documentation/rev-list-options.txt b/Documentation/rev-list-options.txt index 2648a55085..9cd677105d 100644 --- a/Documentation/rev-list-options.txt +++ b/Documentation/rev-list-options.txt @@ -13,7 +13,7 @@ include::pretty-options.txt[] Synonym for `--date=relative`. ---date={relative,local,default,iso,rfc}:: +--date={relative,local,default,iso,rfc,short}:: Only takes effect for dates shown in human-readable format, such as when using "--pretty". From e00f3790b88ce61f1bdc863011a122b98b43197e Mon Sep 17 00:00:00 2001 From: Johannes Sixt Date: Fri, 23 May 2008 16:13:05 +0200 Subject: [PATCH 4/4] rev-parse --symbolic-full-name: don't print '^' if SHA1 is not a ref The intention of --symbolic-full-name is to not print anything if a revision is not an exact ref. But this command: $ git-rev-parse --symbolic-full-name --not master~1 still emitted a sole '^' to stdout (provided that there's no other ref at master~1). This fixes it. Signed-off-by: Johannes Sixt Signed-off-by: Junio C Hamano --- builtin-rev-parse.c | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/builtin-rev-parse.c b/builtin-rev-parse.c index 90dbb9d7c1..1ae086ad17 100644 --- a/builtin-rev-parse.c +++ b/builtin-rev-parse.c @@ -96,6 +96,14 @@ static void show(const char *arg) puts(arg); } +/* Like show(), but with a negation prefix according to type */ +static void show_with_type(int type, const char *arg) +{ + if (type != show_type) + putchar('^'); + show(arg); +} + /* Output a revision, only if filter allows it */ static void show_rev(int type, const unsigned char *sha1, const char *name) { @@ -104,8 +112,6 @@ static void show_rev(int type, const unsigned char *sha1, const char *name) def = NULL; revs_count++; - if (type != show_type) - putchar('^'); if (symbolic && name) { if (symbolic == SHOW_SYMBOLIC_FULL) { unsigned char discard[20]; @@ -122,20 +128,20 @@ static void show_rev(int type, const unsigned char *sha1, const char *name) */ break; case 1: /* happy */ - show(full); + show_with_type(type, full); break; default: /* ambiguous */ error("refname '%s' is ambiguous", name); break; } } else { - show(name); + show_with_type(type, name); } } else if (abbrev) - show(find_unique_abbrev(sha1, abbrev)); + show_with_type(type, find_unique_abbrev(sha1, abbrev)); else - show(sha1_to_hex(sha1)); + show_with_type(type, sha1_to_hex(sha1)); } /* Output a flag, only if filter allows it. */