diff options
author | Ramón M. Gómez <ramongomez@us.es> | 2018-06-12 13:08:52 +0200 |
---|---|---|
committer | Ramón M. Gómez <ramongomez@us.es> | 2018-06-12 13:08:52 +0200 |
commit | 9815cac93139ec0a4a155934819a887b6436081a (patch) | |
tree | 2885c6adab639d6ca71f1a6e87d077024e583ed8 /installer/opengnsys_import.sh | |
parent | c00832504a4a2d0c569850525ed95214a1cffbaa (diff) |
#843: Scripts in in^Caller directory use new version file.
Diffstat (limited to 'installer/opengnsys_import.sh')
-rwxr-xr-x | installer/opengnsys_import.sh | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/installer/opengnsys_import.sh b/installer/opengnsys_import.sh index 26b7ede3..b2a9463b 100755 --- a/installer/opengnsys_import.sh +++ b/installer/opengnsys_import.sh @@ -220,12 +220,12 @@ if [ $? -ne 0 ]; then fi # Comprobamos si es la misma versión -OLDVERSION=$(awk '{print $2}' $TMPDIR/VERSION.txt) -NEWVERSION=$(awk '{print $2}' $OPENGNSYS/doc/VERSION.txt) +OLDVERSION=$(jq -r '.version' $TMPDIR/VERSION.json) +NEWVERSION=$(jq -r '.version' $OPENGNSYS/doc/VERSION.json) # FALTA: Comprobar que la versión OLD es menor que la NEW if [ $OLDVERSION != $NEWVERSION ] ; then echo "La versión del servidor no coincide con la del backup." - cat $OPENGNSYS/doc/VERSION.txt $TMPDIR/VERSION.txt + jq -r '[.project, .version, .codename] | join(" ")' $OPENGNSYS/doc/VERSION.json $TMPDIR/VERSION.json read -p "¿Quiere continuar? (y/n): " ANSWER if [ "${ANSWER^^}" != "Y" ]; then echo "Operación cancelada." |