diff options
author | Junio C Hamano <junkio@cox.net> | 2006-04-21 13:19:58 -0700 |
---|---|---|
committer | Junio C Hamano <junkio@cox.net> | 2006-04-21 13:25:47 -0700 |
commit | 91efcf60653b2538b05625807293b97c07cb04f4 (patch) | |
tree | 0240b448657063bc251be1c79596377ea8b91542 /git-commit.sh | |
parent | 43885c2a557871aedcbb1a412fc18e98c3dd1dc4 (diff) | |
parent | 70827b15bfb11f7aea52c6995956be9d149233e1 (diff) | |
download | git-91efcf60653b2538b05625807293b97c07cb04f4.tar.gz |
Merge branch 'master' into jc/fmt-patch
* master:
Split up builtin commands into separate files from git.c
git-log produces no output
fix pack-object buffer size
mailinfo: decode underscore used in "Q" encoding properly.
Reintroduce svn pools to solve the memory leak.
pack-objects: do not stop at object that is "too small"
git-commit --amend: two fixes.
get_tree_entry(): make it available from tree-walk
sha1_name.c: no need to include diff.h; tree-walk.h will do.
sha1_name.c: prepare to make get_tree_entry() reusable from others.
get_sha1() shorthands for blob/tree objects
pre-commit hook: complain about conflict markers.
git-merge: a bit more readable user guidance.
diff: move diff.c to diff-lib.c to make room.
git log: don't do merge diffs by default
Allow "git repack" users to specify repacking window/depth
Document git-clone --reference
Fix filename scaling for binary files
Fix uninteresting tags in new revision parsing
Conflicts:
Adjusted the addition of fmt-patch to match the recent split
from git.c to builtin.log.c.
Diffstat (limited to 'git-commit.sh')
-rwxr-xr-x | git-commit.sh | 21 |
1 files changed, 14 insertions, 7 deletions
diff --git a/git-commit.sh b/git-commit.sh index 01c73bdd08..26cd7ca54d 100755 --- a/git-commit.sh +++ b/git-commit.sh @@ -167,8 +167,13 @@ run_status () { fi case "$committable" in 0) - echo "nothing to commit" - exit 1 + case "$amend" in + t) + echo "# No changes" ;; + *) + echo "nothing to commit" ;; + esac + exit 1 ;; esac exit 0 ) @@ -365,14 +370,16 @@ tt*) die "Only one of -c/-C/-F/-m can be used." ;; esac -case "$#,$also$only" in -*,tt) +case "$#,$also,$only,$amend" in +*,t,t,*) die "Only one of --include/--only can be used." ;; -0,t) +0,t,,* | 0,,t,) die "No paths with --include/--only does not make sense." ;; -0,) +0,,t,t) + only_include_assumed="# Clever... amending the last one with dirty index." ;; +0,,,*) ;; -*,) +*,,,*) only_include_assumed="# Explicit paths specified without -i nor -o; assuming --only paths..." also= ;; |