summaryrefslogtreecommitdiffstats
path: root/installer/opengnsys_makecompress.sh
diff options
context:
space:
mode:
authorRamón M. Gómez <ramongomez@us.es>2018-06-12 13:08:52 +0200
committerRamón M. Gómez <ramongomez@us.es>2018-06-12 13:08:52 +0200
commit9815cac93139ec0a4a155934819a887b6436081a (patch)
tree2885c6adab639d6ca71f1a6e87d077024e583ed8 /installer/opengnsys_makecompress.sh
parentc00832504a4a2d0c569850525ed95214a1cffbaa (diff)
#843: Scripts in in^Caller directory use new version file.
Diffstat (limited to 'installer/opengnsys_makecompress.sh')
-rwxr-xr-xinstaller/opengnsys_makecompress.sh6
1 files changed, 3 insertions, 3 deletions
diff --git a/installer/opengnsys_makecompress.sh b/installer/opengnsys_makecompress.sh
index 5c8aa729..ff267b1e 100755
--- a/installer/opengnsys_makecompress.sh
+++ b/installer/opengnsys_makecompress.sh
@@ -24,7 +24,7 @@ done
BRANCH="devel"
CODE_URL="https://codeload.github.com/opengnsys/OpenGnsys/zip/$BRANCH"
API_URL="https://api.github.com/repos/opengnsys/OpenGnsys/branches/$BRANCH"
-REVISION=$(curl -s "$API_URL" | jq -r '"r" + (.commit.commit.committer.date | gsub("-"; "")[:8]) + "." + (.commit.sha[:7])')
+REVISION=$(curl -s "$API_URL" | jq '"r" + (.commit.commit.committer.date | gsub("-"; "")[:8]) + "." + (.commit.sha[:7])')
# Descargar repositorio SVN
cd /tmp
@@ -36,10 +36,10 @@ chown -R root.root opengnsys
WARNING=$?
# Parchear datos de revisión del código.
-sed -ri "s/$/ $REVISION/" opengnsys/doc/VERSION.txt
+jq ".release=$REVISION" opengnsys/doc/VERSION.json | sponge opengnsys/doc/VERSION.json
# Generar fichero comprimido.
-VERSION=$(awk '{print $2"-"$3}' opengnsys/doc/VERSION.txt)
+VERSION=$(jq -r '.version+"-"+.release' opengnsys/doc/VERSION.json)
tar cvzf opengnsys-$VERSION.tar.gz opengnsys
rm -fr opengnsys opengnsys.zip