13 lines
295 B
Bash
13 lines
295 B
Bash
#!/bin/bash
|
|
|
|
# Codeberg repository
|
|
REPO="librewolf/source"
|
|
|
|
# Get version from tag name using Codeberg Rest API
|
|
TAG_NAME=$(curl -s -L https://codeberg.org/api/v1/repos/$REPO/tags/ | jq -r '.[0]'.name)
|
|
|
|
# Get version number from tag name
|
|
VERSION=$(echo "$TAG_NAME" | tr '-' 'p')
|
|
|
|
echo "$VERSION"
|