Created
June 13, 2022 14:57
-
-
Save foopis23/31259386f505717cfeaa5d12d792544c to your computer and use it in GitHub Desktop.
Checkout Latest Tag
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Get new tags from remote | |
git fetch --tags | |
# Get latest tag name | |
latestTag=$(git describe --tags `git rev-list --tags --max-count=1`) | |
# Checkout latest tag | |
git checkout $latestTag |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment