summaryrefslogtreecommitdiff
path: root/builtin-tag.c
diff options
context:
space:
mode:
authorLibravatar Jonathan Nieder <jrnieder@gmail.com>2010-01-26 10:08:44 -0600
committerLibravatar Jonathan Nieder <jrnieder@gmail.com>2010-01-26 10:08:44 -0600
commit225f78c817755bebff91629cc525a258cf60eaea (patch)
treefc8146efeb2e2165d5427854f7f36d78fa59e168 /builtin-tag.c
parentMakefile: drop dependency on $(wildcard */*.h) (diff)
parentam: fix patch format detection for Thunderbird "Save As" emails (diff)
downloadtgif-225f78c817755bebff91629cc525a258cf60eaea.tar.xz
Merge branch 'master' of git://repo.or.cz/alt-git into jn/autodep
* 'master' of git://repo.or.cz/alt-git: (384 commits) am: fix patch format detection for Thunderbird "Save As" emails t0022: replace non-portable literal CR tests: consolidate CR removal/addition functions commit-tree: remove unused #define t5541-http-push: make grep expression check for one line only rebase: replace antiquated sed invocation Add test-run-command to .gitignore git_connect: use use_shell instead of explicit "sh", "-c" gitweb.js: Workaround for IE8 bug Make test numbers unique Windows: Remove dependency on pthreadGC2.dll Documentation: move away misplaced 'push --upstream' description Documentation: add missing :: in config.txt pull: re-fix command line generation Documentation: merge: use MERGE_HEAD to refer to the remote branch Documentation: simplify How Merge Works Documentation: merge: add a section about fast-forward Documentation: emphasize when git merge terminates early Documentation: merge: add an overview Documentation: merge: move merge strategy list to end ... Conflicts: Makefile
Diffstat (limited to 'builtin-tag.c')
-rw-r--r--builtin-tag.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/builtin-tag.c b/builtin-tag.c
index c4790185eb..4ef1c4f508 100644
--- a/builtin-tag.c
+++ b/builtin-tag.c
@@ -140,7 +140,7 @@ static int delete_tag(const char *name, const char *ref,
{
if (delete_ref(ref, sha1, 0))
return 1;
- printf("Deleted tag '%s'\n", name);
+ printf("Deleted tag '%s' (was %s)\n", name, find_unique_abbrev(sha1, DEFAULT_ABBREV));
return 0;
}
@@ -479,6 +479,8 @@ int cmd_tag(int argc, const char **argv, const char *prefix)
die("%s: cannot lock the ref", ref);
if (write_ref_sha1(lock, object, NULL) < 0)
die("%s: cannot update the ref", ref);
+ if (force && hashcmp(prev, object))
+ printf("Updated tag '%s' (was %s)\n", tag, find_unique_abbrev(prev, DEFAULT_ABBREV));
strbuf_release(&buf);
return 0;