mirror of
https://github.com/YunoHost-Apps/bozon_ynh.git
synced 2024-09-03 18:16:09 +02:00
Update upstream version
This commit is contained in:
parent
b5b81ca83c
commit
ce9f074327
3 changed files with 24 additions and 6 deletions
|
@ -1 +1 @@
|
||||||
1bc078ddfcbdfebb301b49fe87fd805b6cb89a5a
|
670d3fa88f2e3c0f5cee1de14e7a1d5c113b106d
|
||||||
|
|
|
@ -65,11 +65,21 @@ fi
|
||||||
sudo mv "$TMPDIR" "$final_path"
|
sudo mv "$TMPDIR" "$final_path"
|
||||||
|
|
||||||
# configure config file
|
# configure config file
|
||||||
|
# language
|
||||||
ynh_replace_string "default_language='en'" "default_language='$language'" "$bozon_conf"
|
ynh_replace_string "default_language='en'" "default_language='$language'" "$bozon_conf"
|
||||||
ynh_store_file_checksum "$bozon_conf"
|
|
||||||
|
# max upload file size
|
||||||
|
case ${filesize: -1} in
|
||||||
|
g|G)
|
||||||
|
max_length=$((${filesize%?}*1024))
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
max_length=${filesize%?}
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
ynh_replace_string "max_length=2048" "max_length=$max_length" "$bozon_conf"
|
||||||
|
|
||||||
# update auto_dropzone.php
|
ynh_store_file_checksum "$bozon_conf"
|
||||||
myynh_update_bozon_auto_dropzone
|
|
||||||
|
|
||||||
# create private & data folders
|
# create private & data folders
|
||||||
myynh_create_dir "$final_path/private"
|
myynh_create_dir "$final_path/private"
|
||||||
|
|
|
@ -75,8 +75,16 @@ fi
|
||||||
sudo cp -a "$TMPDIR/." "$final_path"
|
sudo cp -a "$TMPDIR/." "$final_path"
|
||||||
sudo rm -R "$TMPDIR"
|
sudo rm -R "$TMPDIR"
|
||||||
|
|
||||||
# update auto_dropzone.php
|
# update config.php with 'max_length' line
|
||||||
myynh_update_bozon_auto_dropzone
|
case ${filesize: -1} in
|
||||||
|
g|G)
|
||||||
|
max_length=$((${filesize%?}*1024))
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
max_length=${filesize%?}
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
sed -i "54i\$max_length=$max_length;" "$bozon_conf"
|
||||||
|
|
||||||
# set permissions
|
# set permissions
|
||||||
myynh_set_permissions
|
myynh_set_permissions
|
||||||
|
|
Loading…
Reference in a new issue