Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/sh
- echo "Last tag is:"
- git tag | sed -e '$!d'
- echo "Want to tag current commit? type the name of the tag (leave empty to skip)"
- read current
- if [ "$current" != "" ]; then
- git tag -a $current
- fi
- echo "Type the name of the tag you want to move (leave blank to skip)"
- read movement
- if [ "$current" != "" ]; then
- git tag -af $movement
- fi
- read -p "Want to push all updated tags? (y/N)" -n 1 -r
- echo # (optional) move to a new line
- if [[ $REPLY =~ ^[Yy]$ ]]; then
- git push origin :$movement
- git push --tags
- fi
- echo "Done!"
Add Comment
Please, Sign In to add comment