From b6138273188e300dee4d309d2342384ca9eeb186 Mon Sep 17 00:00:00 2001 From: Miklos Vajna Date: Fri, 11 Jul 2008 02:12:03 +0200 Subject: t0001-init.sh: change confusing directory name using git-init as directory name confused 'make remove-dashes', so just drop the 'git-' prefix. Signed-off-by: Miklos Vajna Signed-off-by: Junio C Hamano --- t/t0001-init.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/t/t0001-init.sh b/t/t0001-init.sh index d31887f9b..2a38d98cb 100755 --- a/t/t0001-init.sh +++ b/t/t0001-init.sh @@ -83,11 +83,11 @@ test_expect_success 'init --bare' ' ( unset GIT_DIR GIT_WORK_TREE GIT_CONFIG - mkdir git-init-bare.git && - cd git-init-bare.git && + mkdir init-bare.git && + cd init-bare.git && git init --bare ) && - check_config git-init-bare.git true unset + check_config init-bare.git true unset ' test_expect_success 'GIT_DIR non-bare' ' -- cgit v1.2.1 From b9c76ddd27c035f9f562f6fa5edaea71e3d642db Mon Sep 17 00:00:00 2001 From: Miklos Vajna Date: Fri, 11 Jul 2008 02:12:04 +0200 Subject: t1007-hash-object.sh: use quotes for the test description Signed-off-by: Miklos Vajna Signed-off-by: Junio C Hamano --- t/t1007-hash-object.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/t/t1007-hash-object.sh b/t/t1007-hash-object.sh index 05262954a..1ec053513 100755 --- a/t/t1007-hash-object.sh +++ b/t/t1007-hash-object.sh @@ -1,6 +1,6 @@ #!/bin/sh -test_description=git-hash-object +test_description="git-hash-object" . ./test-lib.sh -- cgit v1.2.1 From 6c98c0548aa3433ba64708ca8f08d44cd923f0b7 Mon Sep 17 00:00:00 2001 From: Miklos Vajna Date: Fri, 11 Jul 2008 18:01:29 +0200 Subject: git-bisect: use dash-less form on git bisect log Given that users are supposed to type 'git bisect' now, make the output of 'git bisect log' consistent with this. Signed-off-by: Miklos Vajna Signed-off-by: Junio C Hamano --- git-bisect.sh | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/git-bisect.sh b/git-bisect.sh index 991b2ef37..3cac20db7 100755 --- a/git-bisect.sh +++ b/git-bisect.sh @@ -149,7 +149,7 @@ bisect_start() { echo "$start_head" >"$GIT_DIR/BISECT_START" && sq "$@" >"$GIT_DIR/BISECT_NAMES" && eval "$eval" && - echo "git-bisect start$orig_args" >>"$GIT_DIR/BISECT_LOG" || exit + echo "git bisect start$orig_args" >>"$GIT_DIR/BISECT_LOG" || exit # # Check if we can proceed to the next bisect state. # @@ -169,7 +169,7 @@ bisect_write() { esac git update-ref "refs/bisect/$tag" "$rev" || exit echo "# $state: $(git show-branch $rev)" >>"$GIT_DIR/BISECT_LOG" - test -n "$nolog" || echo "git-bisect $state $rev" >>"$GIT_DIR/BISECT_LOG" + test -n "$nolog" || echo "git bisect $state $rev" >>"$GIT_DIR/BISECT_LOG" } bisect_state() { @@ -426,9 +426,13 @@ bisect_clean_state() { bisect_replay () { test -r "$1" || die "cannot read $1 for replaying" bisect_reset - while read bisect command rev + while read git bisect command rev do - test "$bisect" = "git-bisect" || continue + test "$git $bisect" = "git bisect" -o "$git" = "git-bisect" || continue + if test "$git" = "git-bisect"; then + rev="$command" + command="$bisect" + fi case "$command" in start) cmd="bisect_start $rev" -- cgit v1.2.1 From b4f02d3509e8e4da0f115b9515d52daa02621db7 Mon Sep 17 00:00:00 2001 From: Miklos Vajna Date: Fri, 11 Jul 2008 02:12:06 +0200 Subject: make remove-dashes: apply to scripts and programs as well, not just to builtins All programs and scripts are now moved outside PATH, so it's a good idea not to use the dashed forms for them, either. Signed-off-by: Miklos Vajna Signed-off-by: Junio C Hamano --- Makefile | 2 +- fixup-builtins | 18 +++++++++--------- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/Makefile b/Makefile index 4796565ab..2b54d927b 100644 --- a/Makefile +++ b/Makefile @@ -1296,7 +1296,7 @@ check: common-cmds.h for i in *.c; do sparse $(ALL_CFLAGS) $(SPARSE_FLAGS) $$i || exit; done remove-dashes: - ./fixup-builtins $(BUILT_INS) + ./fixup-builtins $(BUILT_INS) $(PROGRAMS) $(SCRIPTS) ### Installation rules diff --git a/fixup-builtins b/fixup-builtins index 49e861d2a..63dfa4c47 100755 --- a/fixup-builtins +++ b/fixup-builtins @@ -1,16 +1,16 @@ #!/bin/sh while [ "$1" ] do - old="$1" - new=$(echo "$1" | sed 's/git-/git /') - echo "Converting '$old' to '$new'" - git ls-files '*.sh' | while read file - do - sed "s/\\<$old\\>/$new/g" < $file > $file.new - chmod --reference=$file $file.new - mv $file.new $file - done + if [ "$1" != "git-sh-setup" -a "$1" != "git-parse-remote" -a "$1" != "git-svn" ]; then + old="$1" + new=$(echo "$1" | sed 's/git-/git /') + echo "Converting '$old' to '$new'" + sed -i "s/\\<$old\\>/$new/g" $(git ls-files '*.sh') + fi shift done + +sed -i 's/git merge-one-file/git-merge-one-file/g +s/git rebase-todo/git-rebase-todo/g' $(git ls-files '*.sh') git update-index --refresh >& /dev/null exit 0 -- cgit v1.2.1