Skip to content

Commit

Permalink
Deleting online tag if alreadi exists on git
Browse files Browse the repository at this point in the history
  • Loading branch information
mahype committed Jan 28, 2019
1 parent 5a58136 commit f52c0c5
Showing 1 changed file with 11 additions and 9 deletions.
20 changes: 11 additions & 9 deletions deploy.sh
Original file line number Diff line number Diff line change
Expand Up @@ -42,17 +42,19 @@ echo "Versions match in readme.txt and $MAINFILE. Let's proceed..."

if git show-ref --quiet --tags --verify -- "refs/tags/$NEWVERSION1"
then
echo "Version $NEWVERSION1 already exists as git tag. Skipping."
else
printf "Tagging new Git version..."
git tag -a "$NEWVERSION1" -m "tagged version $NEWVERSION1"
echo "Done."

printf "Pushing new Git tag..."
git push --quiet --tags
echo "Done."
echo "Version $NEWVERSION1 already exists as git tag. Deleting."
git tag -d $NEWVERSION1
git push origin :refs/tags/$NEWVERSION1
fi

printf "Tagging new Git version..."
git tag -a $NEWVERSION1 -m "tagged version $NEWVERSION1"
echo "Done."

printf "Pushing new Git tag..."
git push --quiet --tags
echo "Done."

printf "Creating local copy of SVN repo..."
svn checkout --quiet $SVNURL/trunk $SVNPATH/trunk
echo "Done."
Expand Down

0 comments on commit f52c0c5

Please sign in to comment.