Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/nextcloudpi.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornachoparker <nacho@ownyourbits.com>2018-04-04 15:21:10 +0300
committernachoparker <nacho@ownyourbits.com>2018-04-04 20:32:07 +0300
commit16e245cf697a88917d07fc0f72af4d27edc1e34b (patch)
tree2c5b40065e7cd31fd9905ad8e65b290dedb3cc15 /bin/ncp-test-updates
parent8a2d30a6b2cf335098391b6ccf985b14cafd1fee (diff)
ncp-web: check for updates upon first runv0.53.20
Diffstat (limited to 'bin/ncp-test-updates')
-rwxr-xr-xbin/ncp-test-updates4
1 files changed, 3 insertions, 1 deletions
diff --git a/bin/ncp-test-updates b/bin/ncp-test-updates
index 1a362401..e439a55e 100755
--- a/bin/ncp-test-updates
+++ b/bin/ncp-test-updates
@@ -5,7 +5,9 @@
NEED_UPDATE=false
VERFILE=/var/run/.ncp-latest-version
-if test -f $VERFILE && grep -qP "v\d+\.\d+\.\d+" $VERFILE; then
+[[ $( cat $VERFILE | wc -c ) -eq 0 ]] && ncp-check-version
+
+if grep -qP "v\d+\.\d+\.\d+" $VERFILE; then
MAJOR=$( grep -oP "\d+\.\d+\.\d+" $VERFILE | cut -d. -f1 )
MINOR=$( grep -oP "\d+\.\d+\.\d+" $VERFILE | cut -d. -f2 )