summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-09-09 15:58:28 +0300
committerAndrei Karas <akaras@inbox.ru>2015-09-09 15:58:28 +0300
commit85b0c87088ac499f96adce92c014b92e729c27bb (patch)
tree75d657181e80e9443dd8fcab516bbdd9aa3abbd6
parent0c96721e9b232091e22e45afa1e8eb523df6ae92 (diff)
downloadall-85b0c87088ac499f96adce92c014b92e729c27bb.tar.gz
all-85b0c87088ac499f96adce92c014b92e729c27bb.tar.bz2
all-85b0c87088ac499f96adce92c014b92e729c27bb.tar.xz
all-85b0c87088ac499f96adce92c014b92e729c27bb.zip
Add to status script also db version check for upgrade.
-rwxr-xr-xstatus.sh12
1 files changed, 12 insertions, 0 deletions
diff --git a/status.sh b/status.sh
index b134fcb..6ffc68c 100755
--- a/status.sh
+++ b/status.sh
@@ -2,6 +2,17 @@
export LANG=C
+function dbinfo {
+ export VER=$(cat tools/localserver/versions/sqlver 2>/dev/null)
+
+ if [[ -n "${VER}" ]]; then
+ if [ "${VER}" -lt "2" ]; then
+ echo "database"
+ echo -e "\e[1;31mPlease upgrade database. See instuctions in http://wiki.evolonline.org/guidelines/updating#update_database\e[0m"
+ fi
+ fi
+}
+
function status {
if [ ! -d "$1" ]; then
return
@@ -47,3 +58,4 @@ status music music
status art art
status manaplus manaplus
status media media
+dbinfo