diff --git a/conf/app.src b/conf/app.src deleted file mode 100644 index 92857ab..0000000 --- a/conf/app.src +++ /dev/null @@ -1,7 +0,0 @@ -SOURCE_URL=https://sourceforge.net/projects/tikiwiki/files/Tiki_25.x_Sagittarius_A/25.0/tiki-25.0.tar.gz/download -SOURCE_SUM=e056cdcfdcb03a8c4710db44e7f04e0f846eb7131a8f8aa130a3d8348e0161a4 -SOURCE_SUM_PRG=sha256sum -SOURCE_FORMAT=tar.gz -SOURCE_IN_SUBDIR=true -SOURCE_FILENAME= -SOURCE_EXTRACT=true diff --git a/doc/ADMIN.md b/doc/ADMIN.md index 60035de..34a2854 100644 --- a/doc/ADMIN.md +++ b/doc/ADMIN.md @@ -2,4 +2,4 @@ To ease the install process and first access, Tiki saves your uploaded files (office documents, images, pdf, etc. attached to wiki pages, forum posts, tracker items, file galleries...) by default in its database. This works perfectly in most cases but it is not the recommended setup if you need to save many thousands of files or more. -In that case, consider switching from "Store to database" to "Store to directory", which you will find in the Configuration Wizard. Please use this preset path directory: `/home/yunohost.app/tiki`. You will be able to migrate your currently uploaded files from one to the other. +In that case, consider switching from "Store to database" to "Store to directory", which you will find in the Configuration Wizard. Please use this preset path directory: `/home/yunohost.app/$app`. You will be able to migrate your currently uploaded files from one to the other. diff --git a/manifest.toml b/manifest.toml index 75dce28..c251540 100644 --- a/manifest.toml +++ b/manifest.toml @@ -33,11 +33,34 @@ ram.runtime = "50M" type = "path" default = "/tiki" + [install.release_cycle] + ask.en = "Upgrade cycle" + ask.fr = "Cycle de mises à jours" + help.en = "Every 3 version is an LTS. LTS versions are supported for 5 years" + help.fr = "Toutes les 3 versions sont des LTS qui sont maintenues pendant 5 ans" + type = "select" + choices.longterm = "Install latest Long Term Support version (recommended)" + choices.regular = "Install latest version" + default = "longterm" + [install.init_main_permission] type = "group" default = "visitors" [resources] + + [resources.sources] + + [resources.sources.main] + url = "https://sourceforge.net/projects/tikiwiki/files/Tiki_25.x_Sagittarius_A/25.0/tiki-25.0.tar.gz/download" + sha256 = "e056cdcfdcb03a8c4710db44e7f04e0f846eb7131a8f8aa130a3d8348e0161a4" + format = "tar.gz" + + [resources.sources.lts] + url = "https://sourceforge.net/projects/tikiwiki/files/Tiki_24.x_Wolf_359/24.0/tiki-24.0.tar.gz/download" + sha256 = "2f9fd0e3509cf28c884173bfa58ff3aaa2e694f8c6051b0a94ba1bdbb243463e" + format = "tar.gz" + [resources.system_user] [resources.install_dir] diff --git a/scripts/install b/scripts/install index 0f968ca..0b3d841 100755 --- a/scripts/install +++ b/scripts/install @@ -27,7 +27,13 @@ ynh_app_setting_set --app=$app --key=fpm_usage --value=$fpm_usage ynh_script_progression --message="Setting up source files..." --weight=15 # Download, check integrity, uncompress and patch the source from app.src -ynh_setup_source --dest_dir="$install_dir" +source_id_to_use="main" +if [[ "$release_cycle" == "longterm" ]] +then + source_id_to_use="lts" +fi + +ynh_setup_source --dest_dir="$install_dir" --source_id="$source_id_to_use" chmod -R o-rwx "$install_dir" chown -R $app:www-data "$install_dir" diff --git a/scripts/upgrade b/scripts/upgrade index 1088450..fd2b539 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -47,7 +47,13 @@ then ynh_script_progression --message="Upgrading source files..." --weight=1 # Download, check integrity, uncompress and patch the source from app.src - ynh_setup_source --dest_dir="$install_dir" + source_id_to_use="main" + if [[ "$release_cycle" == "longterm" ]] + then + source_id_to_use="lts" + fi + + ynh_setup_source --dest_dir="$install_dir" --source_id="$source_id_to_use" fi chmod -R o-rwx "$install_dir" diff --git a/tests.toml b/tests.toml index eb73b8d..d56c96c 100644 --- a/tests.toml +++ b/tests.toml @@ -1,3 +1,9 @@ test_format = 1.0 -[default] \ No newline at end of file +[default] + +[regular] + + only = ["install.subdir"] + + args.release_cycle = "regular"