Initial commit

This commit is contained in:
2025-07-26 14:34:20 +03:00
commit f268338bd8
4 changed files with 57 additions and 0 deletions
+12
View File
@@ -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"