From a179a303524c1b81ded1d04930f1edc6b5227c9d Mon Sep 17 00:00:00 2001 From: Christian Couder Date: Sat, 12 Apr 2008 02:17:36 -0700 Subject: [PATCH 1/6] bisect: report bad rev better The previous one overwrote the variable used to report the bad input when the input is actually bad, and we did not give a useful enough information. This corrects it. Signed-off-by: Christian Couder Signed-off-by: Junio C Hamano --- git-bisect.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/git-bisect.sh b/git-bisect.sh index c8be9f7e8a..c99ffee122 100755 --- a/git-bisect.sh +++ b/git-bisect.sh @@ -155,9 +155,9 @@ bisect_state() { shift for rev in "$@" do - rev=$(git rev-parse --verify "$rev^{commit}") || + sha=$(git rev-parse --verify "$rev^{commit}") || die "Bad rev input: $rev" - bisect_write "$state" "$rev" + bisect_write "$state" "$sha" done ;; *,bad) die "'git bisect bad' can take only one argument." ;; From 55ef8a4610c4f1077551682a86f9a4e6d498e8e0 Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Sat, 12 Apr 2008 15:38:20 -0700 Subject: [PATCH 2/6] Document -w option to shortlog Noticed by Fredrik Noring. Signed-off-by: Junio C Hamano --- Documentation/git-shortlog.txt | 10 ++++++++-- builtin-shortlog.c | 2 +- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/Documentation/git-shortlog.txt b/Documentation/git-shortlog.txt index c7752575d8..d7cb4c0468 100644 --- a/Documentation/git-shortlog.txt +++ b/Documentation/git-shortlog.txt @@ -8,8 +8,8 @@ git-shortlog - Summarize 'git log' output SYNOPSIS -------- [verse] -git-log --pretty=short | 'git-shortlog' [-h] [-n] [-s] [-e] -git-shortlog [-n|--numbered] [-s|--summary] [-e|--email] [...] +git-log --pretty=short | 'git-shortlog' [-h] [-n] [-s] [-e] [-w] +git-shortlog [-n|--numbered] [-s|--summary] [-e|--email] [-w[[,[,]]]] [...] DESCRIPTION ----------- @@ -35,6 +35,12 @@ OPTIONS -e, \--email:: Show the email address of each author. +-w[[,[,]]]:: + Linewrap the output by wrapping each line at `width`. The first + line of each entry is indented by `indent1` spaces, and the second + and subsequent lines are indented by `indent2` spaces. `width`, + `indent1`, and `indent2` default to 76, 6 and 9 respectively. + FILES ----- diff --git a/builtin-shortlog.c b/builtin-shortlog.c index f08095bc91..01cfd7b47c 100644 --- a/builtin-shortlog.c +++ b/builtin-shortlog.c @@ -8,7 +8,7 @@ #include "mailmap.h" static const char shortlog_usage[] = -"git-shortlog [-n] [-s] [-e] [... ]"; +"git-shortlog [-n] [-s] [-e] [-w] [... ]"; static char *common_repo_prefix; static int email; From e80950786c16e642be76976a8926b2846ba0aa4f Mon Sep 17 00:00:00 2001 From: Clifford Caoile Date: Sat, 12 Apr 2008 18:50:20 +0900 Subject: [PATCH 3/6] Docs gitk: Explicitly mention the files that gitk uses (~/.gitk) gitk creates and uses ~/.gitk Signed-off-by: Clifford Caoile Signed-off-by: Junio C Hamano --- Documentation/gitk.txt | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Documentation/gitk.txt b/Documentation/gitk.txt index 29edafceda..ed3ba83c53 100644 --- a/Documentation/gitk.txt +++ b/Documentation/gitk.txt @@ -74,6 +74,11 @@ gitk --max-count=100 --all \-- Makefile:: Show at most 100 changes made to the file 'Makefile'. Instead of only looking for changes in the current branch look in all branches. +Files +----- +Gitk creates the .gitk file in your $HOME directory to store preferences +such as display options, font, and colors. + See Also -------- 'qgit(1)':: From 60e3aba9c3c99c40826c051d384e785935874962 Mon Sep 17 00:00:00 2001 From: Daniel Barkalow Date: Sat, 12 Apr 2008 15:32:00 -0400 Subject: [PATCH 4/6] Fix config key miscount in url.*.insteadOf Also tighten test to require it to be correct. Signed-off-by: Daniel Barkalow Signed-off-by: Junio C Hamano --- remote.c | 2 +- t/t5516-fetch-push.sh | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/remote.c b/remote.c index 08af7f9de1..369dc3398c 100644 --- a/remote.c +++ b/remote.c @@ -315,7 +315,7 @@ static int handle_config(const char *key, const char *value) } if (!prefixcmp(key, "url.")) { struct rewrite *rewrite; - name = key + 5; + name = key + 4; subkey = strrchr(name, '.'); if (!subkey) return 0; diff --git a/t/t5516-fetch-push.sh b/t/t5516-fetch-push.sh index 793ffc6600..6d7e738548 100755 --- a/t/t5516-fetch-push.sh +++ b/t/t5516-fetch-push.sh @@ -103,9 +103,9 @@ test_expect_success 'fetch with wildcard' ' test_expect_success 'fetch with insteadOf' ' mk_empty && ( - TRASH=$(pwd) && + TRASH=$(pwd)/ && cd testrepo && - git config url./$TRASH/.insteadOf trash/ + git config url.$TRASH.insteadOf trash/ git config remote.up.url trash/. && git config remote.up.fetch "refs/heads/*:refs/remotes/origin/*" && git fetch up && @@ -145,8 +145,8 @@ test_expect_success 'push with wildcard' ' test_expect_success 'push with insteadOf' ' mk_empty && - TRASH=$(pwd) && - git config url./$TRASH/.insteadOf trash/ && + TRASH=$(pwd)/ && + git config url.$TRASH.insteadOf trash/ && git push trash/testrepo refs/heads/master:refs/remotes/origin/master && ( cd testrepo && From 51836e9e125f67aa26724154757b4734c08057e4 Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Sat, 12 Apr 2008 18:34:39 -0700 Subject: [PATCH 5/6] Documentation/git-submodule: typofix Signed-off-by: Junio C Hamano --- Documentation/git-submodule.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Documentation/git-submodule.txt b/Documentation/git-submodule.txt index 41f9f63566..6ffd896fbc 100644 --- a/Documentation/git-submodule.txt +++ b/Documentation/git-submodule.txt @@ -70,7 +70,7 @@ OPTIONS -n, --summary-limit:: This option is only valid for the summary command. Limit the summary size (number of commits shown in total). - Giving 0 will disable the summary; a negative number means unlimted + Giving 0 will disable the summary; a negative number means unlimited (the default). This limit only applies to modified submodules. The size is always limited to 1 for added/deleted/typechanged submodules. From 02604e293a3b7d48b0ce4e34149de8dc89c674e5 Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Sat, 12 Apr 2008 18:57:08 -0700 Subject: [PATCH 6/6] t7401: squelch garbage output The script had an unconditional output done outside of test_expect_* construct, which leaked out and contaminated the output without -v. Squelch it. Signed-off-by: Junio C Hamano --- t/t7401-submodule-summary.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/t/t7401-submodule-summary.sh b/t/t7401-submodule-summary.sh index 0f3c42ab35..b9a22190e8 100755 --- a/t/t7401-submodule-summary.sh +++ b/t/t7401-submodule-summary.sh @@ -30,7 +30,7 @@ commit_file () { } test_create_repo sm1 && -add_file . foo +add_file . foo >/dev/null head1=$(add_file sm1 foo1 foo2)