1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/pluxml_ynh.git synced 2024-09-03 20:16:02 +02:00

update languages

This commit is contained in:
matlink 2014-11-13 22:06:51 +01:00 committed by Moul
parent 7dc480f69b
commit 1dab3f13b6
2 changed files with 11 additions and 1 deletions

View file

@ -55,6 +55,15 @@
}, },
"choices": ["Yes", "No"], "choices": ["Yes", "No"],
"default": "No" "default": "No"
},
{
"name": "default_lang",
"ask": {
"en": "Default language",
"fr": "Langue par défaut"
},
"choices": ["de","en","es","fr","it","nl","pl","pt","po","ro","ru"],
"default": "en"
} }

View file

@ -8,6 +8,7 @@ path=$2
admin=$3 admin=$3
password=$4 password=$4
is_public=$5 is_public=$5
default_lang=$6
domain=${$domain%?} domain=${$domain%?}
@ -57,7 +58,7 @@ sudo curl -kL -o /tmp/install_page.html https://$domain/$path/install.php >/dev/
#get the token for form validation #get the token for form validation
token=$(sudo cat /tmp/install_page.html | grep "input" | grep "token" | tail -1 | cut -d' ' -f3 | cut -d'"' -f2) token=$(sudo cat /tmp/install_page.html | grep "input" | grep "token" | tail -1 | cut -d' ' -f3 | cut -d'"' -f2)
#send http POST values #send http POST values
sudo curl -k -X POST --data "default_lang=fr&timezone=Greenland&install=Installer&name=$admin&login=$admin&pwd=$password&pwd2=$password&token=$token" https://$domain/$path/install.php >/dev/null 2>&1 sudo curl -k -X POST --data "default_lang=$default_lang&timezone=Greenland&install=Installer&name=$admin&login=$admin&pwd=$password&pwd2=$password&token=$token" https://$domain/$path/install.php >/dev/null 2>&1
sudo chmod 750 -R $final_path sudo chmod 750 -R $final_path
# If app is private, remove url to SSOWat conf from skipped_uris # If app is private, remove url to SSOWat conf from skipped_uris