From afcf08fefa178c969b78df62cc461e357446e810 Mon Sep 17 00:00:00 2001 From: Krakinou Date: Tue, 29 Jan 2019 23:04:48 +0100 Subject: [PATCH] Update manifest with help Update upgrade script with ldap --- manifest.json | 28 ++++++++++++++++++++++------ scripts/upgrade | 7 ++++++- 2 files changed, 28 insertions(+), 7 deletions(-) diff --git a/manifest.json b/manifest.json index 04cac8f..fbf956c 100644 --- a/manifest.json +++ b/manifest.json @@ -57,14 +57,22 @@ "en": "Is it a public application?", "fr": "Est-ce une application publique ?" }, + "help":{ + "en":"No will set the library in /home/yunohost.multimedia/admin/eBook, but if you set thje library as public", + "fr":"Non parametrera la bibliothèque pour /home/yunohost.multimedia/admin/eBook sauf si la bibliothèque est également publique" + }, "default": false }, { "name": "language", "optional": true, "ask": { - "en": "Select a default language (you may change it later in the app)", - "fr": "Choisissez une langue par défaut (vous pourrez la changer ultérieurement dans l'application)" + "en": "Select a default language", + "fr": "Choisissez une langue par défaut" + }, + "help":{ + "en":"You may change it later in the app", + "fr":"Vous pourrez la changer ultérieurement dans l'application" }, "choices": [ "fr", "en", "es", "de"], "default": "fr" @@ -74,8 +82,12 @@ "type":"boolean", "optional": true, "ask": { - "en": "Do you want to allow uploading of books (you may change it later in the app)?", - "fr": "Voulez vous autoriser l'upload de livres (vous pourrez le changer ultérieurement dans l'application)?" + "en": "Do you want to allow uploading of books?", + "fr": "Voulez vous autoriser l'upload de livres?" + }, + "help":{ + "en":"You may change it later in the app", + "fr":"Vous pourrez le changer ultérieurement dans l'application" }, "default": false }, @@ -84,8 +96,12 @@ "type":"boolean", "optional": true, "ask": { - "en": "Do you want to allow access to the library to all Yunohost users? Yes will set the library in /home/yunohost.multimedia/share/eBook", - "fr": "Voulez vous autoriser l'accès à la bibliothèque à tous les utilisateurs Yunohost? Yes parametrera la bibliothèque pour /home/yunohost.multimedia/share/eBook" + "en": "Do you want to allow access to the library to all Yunohost users? ", + "fr": "Voulez vous autoriser l'accès à la bibliothèque à tous les utilisateurs Yunohost?" + }, + "help":{ + "en":"Yes will set the library in /home/yunohost.multimedia/share/eBook", + "fr":"Oui parametrera la bibliothèque pour /home/yunohost.multimedia/share/eBook" }, "default": true } diff --git a/scripts/upgrade b/scripts/upgrade index f66a801..be3884f 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -71,7 +71,7 @@ ynh_add_nginx_config #================================================= # UPGRADE DEPENDENCIES #================================================= - +ynh_print_info "Download and install dependencies" ynh_install_app_dependencies $PKG_DEPENDENCIES pip install --target $final_path/vendor -r $final_path/requirements.txt @@ -92,6 +92,11 @@ ynh_system_user_create $app ### Verify the checksum of a file, stored by `ynh_store_file_checksum` in the install script. ### And create a backup of this file if the checksum is different. So the file will be backed up if the admin had modified it. ynh_backup_if_checksum_is_different "$final_path/app.db" + +#set database settings as per conf file +conf="\"UPDATE settings SET $(. <(echo -E echo $(<../conf/init_calibre_db_settings))) WHERE ID=1\"" +eval sqlite3 $final_path/app.db "$conf" + # Recalculate and store the checksum of the file for the next upgrade. ynh_store_file_checksum "$final_path/app.db"