Created
October 29, 2019 10:14
-
-
Save halidaltuner/2b0e558df789e5da0fee6202ad41dedb to your computer and use it in GitHub Desktop.
get git repository latest tag
This file contains hidden or 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
git clone REPO_URL | |
cd REPO_DIR | |
git fetch --all --tags --prune | |
latestTag=$(git describe --tags `git rev-list --tags --max-count=1`) | |
git checkout $latestTag |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment