mirror of
https://github.com/RetroShare/RetroShare.git
synced 2024-10-01 02:35:48 -04:00
15 lines
592 B
Bash
15 lines
592 B
Bash
|
#!/bin/bash
|
||
|
|
||
|
SOURCE_VERSION_FILE="$( dirname "${BASH_SOURCE[0]}" )/../../Source_Version"
|
||
|
|
||
|
VERSION_MAJOR="$(cat "${SOURCE_VERSION_FILE}" | awk -F. '{print $1}')"
|
||
|
VERSION_MAJOR="${VERSION_MAJOR:1}"
|
||
|
|
||
|
VERSION_MINOR="$(cat "${SOURCE_VERSION_FILE}" | awk -F. '{print $2}')"
|
||
|
|
||
|
VERSION_MINI="$(cat "${SOURCE_VERSION_FILE}" | awk -F. '{print $3}' | awk -F- '{print $1}')"
|
||
|
|
||
|
VERSION_EXTRA="$(cat "${SOURCE_VERSION_FILE}" | awk -F- '{print "-"$2"-"$3"-OBS"}')"
|
||
|
|
||
|
echo RS_MAJOR_VERSION=${VERSION_MAJOR} RS_MINOR_VERSION=${VERSION_MINOR} RS_MINI_VERSION=${VERSION_MINI} RS_EXTRA_VERSION=\"${VERSION_EXTRA}\"
|