Initial commit
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Git repository
|
||||
REPO="git://sourceware.org/git/binutils-gdb.git"
|
||||
|
||||
# Get tag name using 'git ls-remote'
|
||||
TAG_NAME=$(git ls-remote --exit-code --refs --tags --sort='v:refname' "$REPO" | grep -E "gdb-([0-9].*)-release" | tail -1 | cut -d'/' -f3)
|
||||
|
||||
# Get version number from tag name
|
||||
VERSION=$(echo "$TAG_NAME" | cut -d'-' -f2)
|
||||
|
||||
echo "$VERSION"
|
||||
Reference in New Issue
Block a user