aboutsummaryrefslogtreecommitdiff
path: root/git-tag.sh
Commit message (Collapse)AuthorAge
* Rewrite "git-frotz" to "git frotz"Junio C Hamano2007-07-02
| | | | | | This uses the remove-dashes target to replace "git-frotz" to "git frotz". Signed-off-by: Junio C Hamano <gitster@pobox.com>
* git-tag: Fix "can't shift that many".Alexandre Vassalotti2007-06-30
| | | | | | | | | | | This stop git-tag from emitting a "shift: can't shift that many" error, when listing tags. [jc: with further fixups from Sam Vilain merged in; it passes the tests under dash now] Signed-off-by: Alexandre Vassalotti <alexandre@peadrop.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* Correct usages of sed in git-tag for Mac OS XShawn O. Pearce2007-06-30
| | | | | | | | | | | | | | | Both `git-tag -l` and `git tag -v` fail on Mac OS X due to their non-standard uses of sed. Actually `git tag -v` fails because the underlying git-tag-verify uses a non-standard sed command. We now stick to only standard sed, which does make our sed scripts slightly more complicated, but we can actually list tags with more than 0 lines of additional context and we can verify signed tags with gpg. These major Git functions are much more important than saving two or three lines of a simple sed script. Signed-off-by: Shawn O. Pearce <spearce@spearce.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* War on whitespaceJunio C Hamano2007-06-07
| | | | | | | | | This uses "git-apply --whitespace=strip" to fix whitespace errors that have crept in to our source files over time. There are a few files that need to have trailing whitespaces (most notably, test vectors). The results still passes the test, and build result in Documentation/ area is unchanged. Signed-off-by: Junio C Hamano <gitster@pobox.com>
* Teach git-tag about showing tag annotations.Matthijs Melchior2007-06-02
| | | | | | | | | | | | | | | | | | | | | The <pattern> for -l is now a shell pattern, not a list of grep parameters. Option -l may be repeated with another <pattern>. The new -n [<num>] option specifies how many lines from the annotation are to be printed. Not specifieing -n or -n 0 will just produce the tag names Just -n or -n 1 will show the first line of the annotation on the tag line. Other valuse for -n will show that number of lines from the annotation. The exit code used to indicate if any tag was found. This is changed due to a different implementation. A good way to test a tag for existence is to use: git show-ref --quiet --verify refs/tags/$TAGNAME Signed-off-by: Matthijs Melchior <mmelchior@xs4all.nl> Signed-off-by: Junio C Hamano <junkio@cox.net>
* More echo "$user_message" fixes.Jeff King2007-05-26
| | | | | | | Here are fixes to more uses of 'echo "$msg"' where $msg could contain backslashed sequence. Signed-off-by: Junio C Hamano <junkio@cox.net>
* Fix git-tag -uJunio C Hamano2007-01-30
| | | | | | | ... which I broke when we introduced user.signingkey configuration. There was no reason to add a new variable keyid to the script. Signed-off-by: Junio C Hamano <junkio@cox.net>
* Allow the tag signing key to be specified in the config fileAndy Parkins2007-01-27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I did this: $ git tag -s test-sign gpg: skipped "Andy Parkins <andyparkins@gmail.com>": secret key not available gpg: signing failed: secret key not available failed to sign the tag with GPG. The problem is that I have used the comment field in my key's UID definition. $ gpg --list-keys andy pub 1024D/4F712F6D 2003-08-14 uid Andy Parkins (Google) <andyparkins@gmail.com> So when git-tag looks for "Andy Parkins <andyparkins@gmail.com>"; obviously it's not going to be found. There shouldn't be a requirement that I use the same form of my name in my git repository and my gpg key - I might want to be formal (Andrew) in my gpg key and informal (Andy) in the repository. Further I might have multiple keys in my keyring, and might want to use one that doesn't match up with the address I use in commit messages. This patch adds a configuration entry "user.signingkey" which, if present, will be passed to the "-u" switch for gpg, allowing the tag signing key to be overridden. If the entry is not present, the fallback is the original method, which means existing behaviour will continue untouched. Signed-off-by: Andy Parkins <andyparkins@gmail.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
* git-tag -d: allow deleting multiple tags at once.Junio C Hamano2007-01-20
| | | | Signed-off-by: Junio C Hamano <junkio@cox.net>
* git-tag: add flag to verify a tagSanti Béjar2007-01-03
| | | | | | | This way "git tag -v $tag" is the UI for git-verify-tag. Signed-off-by: Santi Béjar <sbejar@gmail.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
* git-tag: lose exit after dieJunio C Hamano2006-12-22
| | | | | | We are not running under /bin/resurrection shell ;-) Signed-off-by: Junio C Hamano <junkio@cox.net>
* git-tag: support -F <file> optionJohannes Schindelin2006-12-21
| | | | | | | | | This imitates the behaviour of git-commit. Noticed by Han-Wen Nienhuys. Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de> Signed-off-by: Junio C Hamano <junkio@cox.net>
* git-tag: allow empty tag message if -m is given explicitly.Han-Wen Nienhuys2006-11-26
| | | | | Signed-off-by: Han-Wen Nienhuys <hanwen@xs4all.nl> Signed-off-by: Junio C Hamano <junkio@cox.net>
* Do not create tag leading directories since git update-ref does it.Christian Couder2006-10-01
| | | | | Signed-off-by: Christian Couder <chriscool@tuxfamily.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
* Check that a tag exists using show-ref instead of looking for the ref file.Christian Couder2006-10-01
| | | | | Signed-off-by: Christian Couder <chriscool@tuxfamily.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
* Use git-update-ref to delete a tag instead of rm()ing the ref file.Christian Couder2006-10-01
| | | | | Signed-off-by: Christian Couder <chriscool@tuxfamily.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
* update a few Porcelain-ish for ref lock safety.Junio C Hamano2006-09-27
| | | | | | | | | | | | | | | | | | This updates the use of git-update-ref in git-branch, git-tag and git-commit to make them safer in a few corner cases as demonstration. - git-tag makes sure that the named tag does not exist, allows you to edit tag message and then creates the tag. If a tag with the same name was created by somebody else in the meantime, it used to happily overwrote it. Now it notices the situation. - git-branch -d and git-commit (for the initial commit) had the same issue but with smaller race window, which is plugged with this. Signed-off-by: Junio C Hamano <junkio@cox.net>
* Strip useless "tags/" prefix from git-tag -l outputSean2006-05-15
|
* Shell utilities: Guard against expr' magic tokens.Mark Wooding2006-04-13
| | | | | | | | | Some words, e.g., `match', are special to expr(1), and cause strange parsing effects. Track down all uses of expr and mangle the arguments so that this isn't a problem. Signed-off-by: Mark Wooding <mdw@distorted.org.uk> Signed-off-by: Junio C Hamano <junkio@cox.net>
* git-tag: -l to list tags (usability).Junio C Hamano2006-02-17
| | | | | | | git-tag -l lists all tags, and git-tag -l <pattern> filters the result with <pattern>. Signed-off-by: Junio C Hamano <junkio@cox.net>
* avoid echo -e, there are systems where it does not workAlex Riesen2006-02-12
| | | | | | | | FreeBSD 4.11 being one example: the built-in echo doesn't have -e, and the installed /bin/echo does not do "-e" as well. "printf" works, laking just "\e" and "\xAB'. Signed-off-by: Junio C Hamano <junkio@cox.net>
* Trivial usage string clean-upfreku045@student.liu.se2005-12-14
| | | | | Signed-off-by: Fredrik Kuivinen <freku045@student.liu.se> Signed-off-by: Junio C Hamano <junkio@cox.net>
* define die() for scripts that use it.Junio C Hamano2005-11-28
| | | | | | | | | As a fallout from not using git-sh-setup in scripts that can operate from a subdirectory, we lost definition of die() from them. It might make sense to do some cleanup to consolidate them back again, but this should suffice for now. Signed-off-by: Junio C Hamano <junkio@cox.net>
* tag: make it operable from a subdirectory.Junio C Hamano2005-11-28
| | | | Signed-off-by: Junio C Hamano <junkio@cox.net>
* git-sh-setup: die if outside git repository.Junio C Hamano2005-11-25
| | | | | | | | Now all the users of this script detect its exit status and die, complaining that it is outside git repository. So move the code that dies from all callers to git-sh-setup script. Signed-off-by: Junio C Hamano <junkio@cox.net>
* git-tag -d <tag>: delete tag <tag>Kai Ruemmler2005-11-08
| | | | | | | This adds option '-d' to git-tag.sh and documents it. Signed-off-by: Kai Ruemmler <kai.ruemmler@gmx.net> Signed-off-by: Junio C Hamano <junkio@cox.net>
* Do not fail on hierarchical tagnames.Junio C Hamano2005-11-07
| | | | | | | | This is a companion patch to 13d1cc3604a1a64cb5a6025bba8af8b74a373963 commit, which made hierarchical branch name possible. "git tag v0.99.9/a" would fail otherwise. Signed-off-by: Junio C Hamano <junkio@cox.net>
* git-tag: Do not assume the working tree root is writable.Junio C Hamano2005-11-03
| | | | | | | | | | | This is a long overdue companion commit that fixed git-commit (Santi's f8e2c54c9a17af3319e96db1d9e97ace36ae6831). Having the temporary files in the working tree root when making tags is not as bad because it does not involve 'git status' as the git-commit case, but this makes things more consistent. Signed-off-by: Junio C Hamano <junkio@cox.net>
* git-check-ref-format: reject funny ref names.Junio C Hamano2005-10-15
| | | | | | | | | | | | | | Update check_ref_format() function to reject ref names that: * has a path component that begins with a ".", or * has a double dots "..", or * has ASCII control character, "~", "^", ":" or SP, anywhere, or * ends with a "/". Use it in 'git-checkout -b', 'git-branch', and 'git-tag' to make sure that newly created refs are well-formed. Signed-off-by: Junio C Hamano <junkio@cox.net>
* Merge branch 'fixes'Junio C Hamano2005-10-09
|\ | | | | | | | | | | with minor hand resolving on git-tag. Signed-off-by: Junio C Hamano <junkio@cox.net>
| * git-tag: update usage string and documentation.Junio C Hamano2005-10-09
| | | | | | | | Signed-off-by: Junio C Hamano <junkio@cox.net>
* | Allow "-u" flag to tag signingLinus Torvalds2005-10-06
|/ | | | | | | | | | | | | | | | | | | | | | The current "git tag -s" thing always uses the tagger name as the signing user key, which is very irritating, since my key is under my email address, but the tagger key obviously contains the actual machine name too. Now, I could just use "GIT_COMMITTER_EMAIL" and force it to be my real email, but I actually think that it's nice to see which machine I use for my work. So rather than force my tagger ID to have to match the gpg key name, just support the "-u" flag to "git tag" instead. It implicitly enables signing, since it doesn't make any sense without it. Thus: git tag -u <gpg-key-name> <tag-name> [<tagged-object>] will use the named gpg key for signing. Signed-off-by: Linus Torvalds <torvalds@osdl.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
* Big tool rename.Junio C Hamano2005-09-07
As promised, this is the "big tool rename" patch. The primary differences since 0.99.6 are: (1) git-*-script are no more. The commands installed do not have any such suffix so users do not have to remember if something is implemented as a shell script or not. (2) Many command names with 'cache' in them are renamed with 'index' if that is what they mean. There are backward compatibility symblic links so that you and Porcelains can keep using the old names, but the backward compatibility support is expected to be removed in the near future. Signed-off-by: Junio C Hamano <junkio@cox.net>