From 180779a6c76f6ab0f0d8fb2d553c936aec83361c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 17 Aug 2023 15:00:13 +0200 Subject: [PATCH 01/44] Update manifest.toml --- manifest.toml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/manifest.toml b/manifest.toml index 0812088..f12b43e 100644 --- a/manifest.toml +++ b/manifest.toml @@ -5,7 +5,7 @@ name = "Etherpad MyPads" description.en = "Online editor providing collaborative editing in real-time" description.fr = "Éditeur en ligne fournissant l'édition collaborative en temps réel" -version = "1.9.1~ynh1" +version = "1.9.2~ynh1" maintainers = [] @@ -17,7 +17,7 @@ admindoc = "http://etherpad.org/doc/v1.9.0" code = "https://github.com/ether/etherpad-lite" [integration] -yunohost = ">= 11.1.21" +yunohost = ">= 11.2" architectures = ["arm64", "amd64"] multi_instance = true ldap = false @@ -80,8 +80,8 @@ ram.runtime = "50M" [resources.sources] [resources.sources.main] - url = "https://github.com/ether/etherpad-lite/archive/1.9.1.tar.gz" - sha256 = "667741235a2bcd8d28a32f5e611b82fb2ea7d11525ff41b8b5478b05a987b047" + url = "https://github.com/ether/etherpad-lite/archive/1.9.2.tar.gz" + sha256 = "7d8168cdb6d6ca84ee48978e8c654f75703d6431203c756ba55c50aa54cc75a3" autoupdate.strategy = "latest_github_tag" [resources.system_user] From 0d734bee4fc9a66487a6f3667ee732dcf59fd79d Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Thu, 17 Aug 2023 13:00:18 +0000 Subject: [PATCH 02/44] Auto-update README --- README.md | 2 +- README_fr.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index f877b73..0690fd7 100644 --- a/README.md +++ b/README.md @@ -35,7 +35,7 @@ This version of Etherpad is preconfigured with a collection of plugins: - [ep_subscript_and_superscript](https://www.npmjs.com/package/ep_subscript_and_superscript) - *Support for subscript and superscript* -**Shipped version:** 1.9.1~ynh1 +**Shipped version:** 1.9.2~ynh1 **Demo:** https://video.etherpad.com diff --git a/README_fr.md b/README_fr.md index b97b773..891cfac 100644 --- a/README_fr.md +++ b/README_fr.md @@ -35,7 +35,7 @@ Cette version d'Etherpad est préconfigurée avec une collection de plugins: - [ep_subscript_and_superscript](https://www.npmjs.com/package/ep_subscript_and_superscript) - *Support des exposants et indices* -**Version incluse :** 1.9.1~ynh1 +**Version incluse :** 1.9.2~ynh1 **Démo :** https://video.etherpad.com From 270c3eab74663e9c47660792318bc4f9c1fa8331 Mon Sep 17 00:00:00 2001 From: Alexandre Aubin Date: Sun, 27 Aug 2023 11:23:54 +0200 Subject: [PATCH 03/44] Remove bloated 'table of content' plugin --- doc/DESCRIPTION.md | 1 - doc/DESCRIPTION_fr.md | 1 - scripts/_common.sh | 1 - scripts/install | 2 -- scripts/upgrade | 2 -- 5 files changed, 7 deletions(-) diff --git a/doc/DESCRIPTION.md b/doc/DESCRIPTION.md index 2847b1b..ea28461 100644 --- a/doc/DESCRIPTION.md +++ b/doc/DESCRIPTION.md @@ -3,7 +3,6 @@ Etherpad is a real-time collaborative editor scalable to thousands of simultaneo This version of Etherpad is preconfigured with a collection of plugins: - [ep_mypads](https://www.npmjs.com/package/ep_mypads) - *Groups and private pads for etherpad* -- [ep_table_of_contents](https://www.npmjs.com/package/ep_table_of_contents) - *Display pad's table of contents* - [ep_align](https://www.npmjs.com/package/ep_align) - *Add Left/Center/Right/Justify alignment* - [ep_author_hover](https://www.npmjs.com/package/ep_author_hover) - *Display author names when hovereing text* - [ep_comments_page](https://www.npmjs.com/package/ep_comments_page) - *Add comments on sidebar and link it to the text.* diff --git a/doc/DESCRIPTION_fr.md b/doc/DESCRIPTION_fr.md index c7b9d0d..6894628 100644 --- a/doc/DESCRIPTION_fr.md +++ b/doc/DESCRIPTION_fr.md @@ -3,7 +3,6 @@ Etherpad est un éditeur collaboratif en temps réel évolutif pour des milliers Cette version d'Etherpad est préconfigurée avec une collection de plugins: - [ep_mypads](https://www.npmjs.com/package/ep_mypads) - *Groupes et pads privés pour etherpad* -- [ep_table_of_contents](https://www.npmjs.com/package/ep_table_of_contents) - *Affichage de la table des matières* - [ep_align](https://www.npmjs.com/package/ep_align) - *Ajout de l'alignement à gauche/centre/droit/justifié* - [ep_author_hover](https://www.npmjs.com/package/ep_author_hover) - *Affichage de l'auteur lorsqu'on passe la souris au dessus d'un texte* - [ep_comments_page](https://www.npmjs.com/package/ep_comments_page) - *Ajout de commentaire dans la barre latéral + lien avec le texte du pad* diff --git a/scripts/_common.sh b/scripts/_common.sh index b3861a7..e2d83e7 100755 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -22,7 +22,6 @@ ep_headings2_version=0.2.44 ep_markdown_version=0.1.50 ep_spellcheck_version=0.0.43 ep_subscript_and_superscript_version=0.2.47 -ep_table_of_contents_version=0.3.42 ep_font_size_version=0.4.44 #================================================= diff --git a/scripts/install b/scripts/install index 9004835..bb1bea0 100644 --- a/scripts/install +++ b/scripts/install @@ -148,8 +148,6 @@ pushd "$install_dir" ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH $ynh_npm install --no-save ep_spellcheck@${ep_spellcheck_version} # Framapad - Add support for Subscript and Superscript ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH $ynh_npm install --no-save ep_subscript_and_superscript@${ep_subscript_and_superscript_version} - # Framapad - View a table of contents for your pad - ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH $ynh_npm install --no-save ep_table_of_contents@${ep_table_of_contents_version} # Framapad - User Pad Contents font size can be set in settings, this does not effect other peoples views ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH $ynh_npm install --no-save ep_font_size@${ep_font_size_version} popd diff --git a/scripts/upgrade b/scripts/upgrade index a1a806e..6cfc080 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -291,8 +291,6 @@ pushd "$install_dir" ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH $ynh_npm install --no-save ep_spellcheck@${ep_spellcheck_version} # Framapad - Add support for Subscript and Superscript ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH $ynh_npm install --no-save ep_subscript_and_superscript@${ep_subscript_and_superscript_version} - # Framapad - View a table of contents for your pad - ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH $ynh_npm install --no-save ep_table_of_contents@${ep_table_of_contents_version} # Framapad - User Pad Contents font size can be set in settings, this does not effect other peoples views ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH $ynh_npm install --no-save ep_font_size@${ep_font_size_version} popd From a05ea94ce8d54ed4a73e5d51d5ded97320a4309c Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Sun, 27 Aug 2023 09:28:24 +0000 Subject: [PATCH 04/44] Auto-update README --- README.md | 1 - README_fr.md | 1 - 2 files changed, 2 deletions(-) diff --git a/README.md b/README.md index 0690fd7..f1ca048 100644 --- a/README.md +++ b/README.md @@ -21,7 +21,6 @@ Etherpad is a real-time collaborative editor scalable to thousands of simultaneo This version of Etherpad is preconfigured with a collection of plugins: - [ep_mypads](https://www.npmjs.com/package/ep_mypads) - *Groups and private pads for etherpad* -- [ep_table_of_contents](https://www.npmjs.com/package/ep_table_of_contents) - *Display pad's table of contents* - [ep_align](https://www.npmjs.com/package/ep_align) - *Add Left/Center/Right/Justify alignment* - [ep_author_hover](https://www.npmjs.com/package/ep_author_hover) - *Display author names when hovereing text* - [ep_comments_page](https://www.npmjs.com/package/ep_comments_page) - *Add comments on sidebar and link it to the text.* diff --git a/README_fr.md b/README_fr.md index 891cfac..9279f29 100644 --- a/README_fr.md +++ b/README_fr.md @@ -21,7 +21,6 @@ Etherpad est un éditeur collaboratif en temps réel évolutif pour des milliers Cette version d'Etherpad est préconfigurée avec une collection de plugins: - [ep_mypads](https://www.npmjs.com/package/ep_mypads) - *Groupes et pads privés pour etherpad* -- [ep_table_of_contents](https://www.npmjs.com/package/ep_table_of_contents) - *Affichage de la table des matières* - [ep_align](https://www.npmjs.com/package/ep_align) - *Ajout de l'alignement à gauche/centre/droit/justifié* - [ep_author_hover](https://www.npmjs.com/package/ep_author_hover) - *Affichage de l'auteur lorsqu'on passe la souris au dessus d'un texte* - [ep_comments_page](https://www.npmjs.com/package/ep_comments_page) - *Ajout de commentaire dans la barre latéral + lien avec le texte du pad* From 2115d21e1e77525576da85ec6bb9cdc58798f962 Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Sun, 27 Aug 2023 12:08:58 +0200 Subject: [PATCH 05/44] Update manifest.toml --- manifest.toml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/manifest.toml b/manifest.toml index f12b43e..5690516 100644 --- a/manifest.toml +++ b/manifest.toml @@ -43,7 +43,7 @@ ram.runtime = "50M" [install.language] ask.en = "Choose your language" ask.fr = "Choisissez la langue" - type = "string" + type = "select" choices = ["ca", "de", "en", "es", "fr", "gl", "hu", "it", "nl", "pt"] default = "fr" @@ -56,7 +56,7 @@ ram.runtime = "50M" [install.export] ask.en = "Use AbiWord (~260 Mo) or LibreOffice (~400 Mo) (more stable) to expand export possibilities (PDF, doc)?" ask.fr = "Utiliser AbiWord (~260 Mo) ou LibreOffice (~400 Mo) (plus stable) pour étendre les possibilités d'export (PDF, doc) ?" - type = "string" + type = "select" choices = ["none", "abiword", "libreoffice"] default = "none" From b0c4783a103bedfc02bf6c1b031eaa791bd4a836 Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Sun, 27 Aug 2023 12:14:15 +0200 Subject: [PATCH 06/44] Update _common.sh --- scripts/_common.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/_common.sh b/scripts/_common.sh index b3861a7..5759254 100755 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -5,7 +5,7 @@ #================================================= # NodeJS version -nodejs_version=14 +nodejs_version=18 # MyPads version # This variable is mostly used to force an upgrade of the package in case of new versions of MyPads. From 3a624fdfbdcd33eeba8e11c9242f47f713069315 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sun, 27 Aug 2023 23:13:48 +0200 Subject: [PATCH 07/44] new path --- scripts/install | 2 +- scripts/upgrade | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/install b/scripts/install index bb1bea0..aaa61fe 100644 --- a/scripts/install +++ b/scripts/install @@ -158,7 +158,7 @@ popd ynh_script_progression --message="Installing Etherpad..." --weight=90 pushd $install_dir - ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH bin/installDeps.sh + ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH src/bin/installDeps.sh popd #================================================= diff --git a/scripts/upgrade b/scripts/upgrade index 6cfc080..c2f7715 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -301,7 +301,7 @@ popd ynh_script_progression --message="Upgrading Etherpad..." --weight=60 pushd $install_dir - ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH bin/installDeps.sh + ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH src/bin/installDeps.sh popd #================================================= From 244a7258c93f67837f366c7f12c12e712877fe6e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sun, 27 Aug 2023 23:14:52 +0200 Subject: [PATCH 08/44] Update _common.sh --- scripts/_common.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/_common.sh b/scripts/_common.sh index e6fe4f2..9a4571d 100755 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -5,7 +5,7 @@ #================================================= # NodeJS version -nodejs_version=18 +nodejs_version=20 # MyPads version # This variable is mostly used to force an upgrade of the package in case of new versions of MyPads. From c97975008aecde8e198b2ae3ed48b67e4afd21c6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sun, 27 Aug 2023 23:21:41 +0200 Subject: [PATCH 09/44] Update tests.toml --- tests.toml | 1 + 1 file changed, 1 insertion(+) diff --git a/tests.toml b/tests.toml index 049b456..e754b01 100644 --- a/tests.toml +++ b/tests.toml @@ -9,6 +9,7 @@ test_format = 1.0 args.export = "libreoffice" args.mypads = 1 args.useldap = 1 + args.password = "admin!42" # ------------------------------- # Commits to test upgrade from From 01cf073131222c71bca32778a7c73a3d95335872 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Mon, 28 Aug 2023 09:26:21 +0200 Subject: [PATCH 10/44] Update tests.toml --- tests.toml | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/tests.toml b/tests.toml index e754b01..2d300eb 100644 --- a/tests.toml +++ b/tests.toml @@ -7,8 +7,8 @@ test_format = 1.0 # ------------------------------- args.export = "libreoffice" - args.mypads = 1 - args.useldap = 1 + args.mypads = 0 + args.useldap = 0 args.password = "admin!42" # ------------------------------- @@ -19,11 +19,11 @@ test_format = 1.0 # This is an additional test suite -#[without_mypads] -# args.export = "libreoffice" -# args.mypads = 0 -# args.useldap = 0 -# only = ["install.root"] +[with_mypads] + args.export = "libreoffice" + args.mypads = 1 + args.useldap = 1 + only = ["install.root"] #[with_abiword] # args.export = "abiword" From 7d659b27a63ac6ea0f722b662d84a50451e2ca33 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Mon, 28 Aug 2023 11:11:35 +0200 Subject: [PATCH 11/44] Update install --- scripts/install | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/scripts/install b/scripts/install index aaa61fe..2db89e6 100644 --- a/scripts/install +++ b/scripts/install @@ -170,11 +170,11 @@ then ynh_script_progression --message="Tweaking mypad configuration..." --weight=1 # Add a link to Etherpad to allow anonymous pads creation from MyPads. - ynh_replace_string --match_string="^ *\"DESCRIPTION\": .*" --replace_string="&Pads anonymes" --target_file=$install_dir/node_modules/ep_mypads/static/l10n/fr.json - ynh_replace_string --match_string="^ *\"DESCRIPTION\": .*" --replace_string="&Anonymous pads" --target_file=$install_dir/node_modules/ep_mypads/static/l10n/en.json + ynh_replace_string --match_string="^ *\"DESCRIPTION\": .*" --replace_string="&Pads anonymes" --target_file=$install_dir/node_modules/ep_mypads/src/static/l10n/fr.json + ynh_replace_string --match_string="^ *\"DESCRIPTION\": .*" --replace_string="&Anonymous pads" --target_file=$install_dir/node_modules/ep_mypads/src/static/l10n/en.json # And a link to etherpad admin from Mypads. - ynh_replace_string --match_string="^ *\"FOOTER\": .*2.0" --replace_string="& | Etherpad admin" --target_file=$install_dir/node_modules/ep_mypads/static/l10n/en.json - ynh_replace_string --match_string="^ *\"FOOTER\": .*2.0" --replace_string="& | Etherpad admin" --target_file=$install_dir/node_modules/ep_mypads/static/l10n/fr.json + ynh_replace_string --match_string="^ *\"FOOTER\": .*2.0" --replace_string="& | Etherpad admin" --target_file=$install_dir/node_modules/ep_mypads/src/static/l10n/en.json + ynh_replace_string --match_string="^ *\"FOOTER\": .*2.0" --replace_string="& | Etherpad admin" --target_file=$install_dir/node_modules/ep_mypads/src/static/l10n/fr.json # Find the /div just after the field to open a pad in order to add a link to MyPads plugin. sed -i '157i

MyPads
' $install_dir/src/templates/index.html From 6c538b8562031cfb8dabde206f3b86932c24f9b1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Mon, 28 Aug 2023 11:29:34 +0200 Subject: [PATCH 12/44] fix --- scripts/install | 10 +++++----- scripts/upgrade | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/scripts/install b/scripts/install index 2db89e6..bb1bea0 100644 --- a/scripts/install +++ b/scripts/install @@ -158,7 +158,7 @@ popd ynh_script_progression --message="Installing Etherpad..." --weight=90 pushd $install_dir - ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH src/bin/installDeps.sh + ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH bin/installDeps.sh popd #================================================= @@ -170,11 +170,11 @@ then ynh_script_progression --message="Tweaking mypad configuration..." --weight=1 # Add a link to Etherpad to allow anonymous pads creation from MyPads. - ynh_replace_string --match_string="^ *\"DESCRIPTION\": .*" --replace_string="&Pads anonymes" --target_file=$install_dir/node_modules/ep_mypads/src/static/l10n/fr.json - ynh_replace_string --match_string="^ *\"DESCRIPTION\": .*" --replace_string="&Anonymous pads" --target_file=$install_dir/node_modules/ep_mypads/src/static/l10n/en.json + ynh_replace_string --match_string="^ *\"DESCRIPTION\": .*" --replace_string="&Pads anonymes" --target_file=$install_dir/node_modules/ep_mypads/static/l10n/fr.json + ynh_replace_string --match_string="^ *\"DESCRIPTION\": .*" --replace_string="&Anonymous pads" --target_file=$install_dir/node_modules/ep_mypads/static/l10n/en.json # And a link to etherpad admin from Mypads. - ynh_replace_string --match_string="^ *\"FOOTER\": .*2.0" --replace_string="& | Etherpad admin" --target_file=$install_dir/node_modules/ep_mypads/src/static/l10n/en.json - ynh_replace_string --match_string="^ *\"FOOTER\": .*2.0" --replace_string="& | Etherpad admin" --target_file=$install_dir/node_modules/ep_mypads/src/static/l10n/fr.json + ynh_replace_string --match_string="^ *\"FOOTER\": .*2.0" --replace_string="& | Etherpad admin" --target_file=$install_dir/node_modules/ep_mypads/static/l10n/en.json + ynh_replace_string --match_string="^ *\"FOOTER\": .*2.0" --replace_string="& | Etherpad admin" --target_file=$install_dir/node_modules/ep_mypads/static/l10n/fr.json # Find the /div just after the field to open a pad in order to add a link to MyPads plugin. sed -i '157i

MyPads
' $install_dir/src/templates/index.html diff --git a/scripts/upgrade b/scripts/upgrade index c2f7715..6cfc080 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -301,7 +301,7 @@ popd ynh_script_progression --message="Upgrading Etherpad..." --weight=60 pushd $install_dir - ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH src/bin/installDeps.sh + ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH bin/installDeps.sh popd #================================================= From 8d2a5cb7cb506f252ee7f5495919ff5e464a6099 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sat, 23 Sep 2023 15:19:17 +0200 Subject: [PATCH 13/44] Update manifest.toml --- manifest.toml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/manifest.toml b/manifest.toml index 5690516..ab78ffe 100644 --- a/manifest.toml +++ b/manifest.toml @@ -5,7 +5,7 @@ name = "Etherpad MyPads" description.en = "Online editor providing collaborative editing in real-time" description.fr = "Éditeur en ligne fournissant l'édition collaborative en temps réel" -version = "1.9.2~ynh1" +version = "1.9.3~ynh1" maintainers = [] @@ -80,8 +80,8 @@ ram.runtime = "50M" [resources.sources] [resources.sources.main] - url = "https://github.com/ether/etherpad-lite/archive/1.9.2.tar.gz" - sha256 = "7d8168cdb6d6ca84ee48978e8c654f75703d6431203c756ba55c50aa54cc75a3" + url = "https://github.com/ether/etherpad-lite/archive/1.9.3.tar.gz" + sha256 = "e2907f35f4f7026860bed6b6e847ec964f1c3d51d2e2212247d7bf9db5b4f18d" autoupdate.strategy = "latest_github_tag" [resources.system_user] From c25d5bff9daa36c79e509b64349ba7f84d17fc70 Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Sat, 23 Sep 2023 13:19:22 +0000 Subject: [PATCH 14/44] Auto-update README --- README.md | 2 +- README_fr.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index f1ca048..e9a3593 100644 --- a/README.md +++ b/README.md @@ -34,7 +34,7 @@ This version of Etherpad is preconfigured with a collection of plugins: - [ep_subscript_and_superscript](https://www.npmjs.com/package/ep_subscript_and_superscript) - *Support for subscript and superscript* -**Shipped version:** 1.9.2~ynh1 +**Shipped version:** 1.9.3~ynh1 **Demo:** https://video.etherpad.com diff --git a/README_fr.md b/README_fr.md index 9279f29..731954a 100644 --- a/README_fr.md +++ b/README_fr.md @@ -34,7 +34,7 @@ Cette version d'Etherpad est préconfigurée avec une collection de plugins: - [ep_subscript_and_superscript](https://www.npmjs.com/package/ep_subscript_and_superscript) - *Support des exposants et indices* -**Version incluse :** 1.9.2~ynh1 +**Version incluse :** 1.9.3~ynh1 **Démo :** https://video.etherpad.com From 3d4cf1d4ac07899ff1c28473d65a6d5b00463dd6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sat, 23 Sep 2023 15:41:14 +0200 Subject: [PATCH 15/44] Update manifest.toml --- manifest.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/manifest.toml b/manifest.toml index ab78ffe..f42042b 100644 --- a/manifest.toml +++ b/manifest.toml @@ -81,7 +81,7 @@ ram.runtime = "50M" [resources.sources.main] url = "https://github.com/ether/etherpad-lite/archive/1.9.3.tar.gz" - sha256 = "e2907f35f4f7026860bed6b6e847ec964f1c3d51d2e2212247d7bf9db5b4f18d" + sha256 = "7d8168cdb6d6ca84ee48978e8c654f75703d6431203c756ba55c50aa54cc75a3" autoupdate.strategy = "latest_github_tag" [resources.system_user] From 668689b5ec63eee5de9d3338695eb706b631edce Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sat, 23 Sep 2023 15:43:08 +0200 Subject: [PATCH 16/44] Update manifest.toml --- manifest.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/manifest.toml b/manifest.toml index f42042b..ab78ffe 100644 --- a/manifest.toml +++ b/manifest.toml @@ -81,7 +81,7 @@ ram.runtime = "50M" [resources.sources.main] url = "https://github.com/ether/etherpad-lite/archive/1.9.3.tar.gz" - sha256 = "7d8168cdb6d6ca84ee48978e8c654f75703d6431203c756ba55c50aa54cc75a3" + sha256 = "e2907f35f4f7026860bed6b6e847ec964f1c3d51d2e2212247d7bf9db5b4f18d" autoupdate.strategy = "latest_github_tag" [resources.system_user] From af69eb097d27f7ba31c608c583ab0a08b703867d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Wed, 25 Oct 2023 18:10:29 +0200 Subject: [PATCH 17/44] Update _common.sh --- scripts/_common.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/_common.sh b/scripts/_common.sh index 9a4571d..53abd29 100755 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -5,7 +5,7 @@ #================================================= # NodeJS version -nodejs_version=20 +nodejs_version=16 # MyPads version # This variable is mostly used to force an upgrade of the package in case of new versions of MyPads. From 117d0fe9c3864a2511d460fd4081bdc9b4859367 Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Wed, 25 Oct 2023 16:10:34 +0000 Subject: [PATCH 18/44] Auto-update README --- README.md | 1 - README_fr.md | 1 - 2 files changed, 2 deletions(-) diff --git a/README.md b/README.md index e9a3593..ca79108 100644 --- a/README.md +++ b/README.md @@ -47,7 +47,6 @@ This version of Etherpad is preconfigured with a collection of plugins: * Official app website: * Official admin documentation: * Upstream app code repository: -* YunoHost documentation for this app: * Report a bug: ## Developer info diff --git a/README_fr.md b/README_fr.md index 731954a..aa4d64f 100644 --- a/README_fr.md +++ b/README_fr.md @@ -47,7 +47,6 @@ Cette version d'Etherpad est préconfigurée avec une collection de plugins: * Site officiel de l’app : * Documentation officielle de l’admin : * Dépôt de code officiel de l’app : -* Documentation YunoHost pour cette app : * Signaler un bug : ## Informations pour les développeurs From 83f6e8d1d10db66ebd325e27795eaf055b4a2ef3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sat, 28 Oct 2023 20:55:41 +0200 Subject: [PATCH 19/44] Update manifest.toml --- manifest.toml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/manifest.toml b/manifest.toml index ab78ffe..84f5eef 100644 --- a/manifest.toml +++ b/manifest.toml @@ -5,7 +5,7 @@ name = "Etherpad MyPads" description.en = "Online editor providing collaborative editing in real-time" description.fr = "Éditeur en ligne fournissant l'édition collaborative en temps réel" -version = "1.9.3~ynh1" +version = "1.9.4~ynh1" maintainers = [] @@ -80,8 +80,8 @@ ram.runtime = "50M" [resources.sources] [resources.sources.main] - url = "https://github.com/ether/etherpad-lite/archive/1.9.3.tar.gz" - sha256 = "e2907f35f4f7026860bed6b6e847ec964f1c3d51d2e2212247d7bf9db5b4f18d" + url = "https://github.com/ether/etherpad-lite/archive/1.9.4.tar.gz" + sha256 = "5b8ccf2a3c92cbd9bb578f684bc52d2ea27fc3fb30cdc76341f9ccffe0c0ff7f" autoupdate.strategy = "latest_github_tag" [resources.system_user] From 27f357c4d8b418ce9c5fb0dd3e918f523010e687 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sat, 28 Oct 2023 22:34:09 +0200 Subject: [PATCH 20/44] Update install --- scripts/install | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/scripts/install b/scripts/install index bb1bea0..4028d6f 100644 --- a/scripts/install +++ b/scripts/install @@ -75,9 +75,8 @@ chown $app -R /var/log/$app #================================================= ynh_script_progression --message="Adding a configuration file..." --weight=6 -cp ../conf/settings.json "$install_dir/settings.json" +ynh_add_config --template="../conf/settings.json" --destination="$install_dir/settings.json" -ynh_replace_string --match_string="__PORT__" --replace_string="$port" --target_file="$install_dir/settings.json" if [ "$export" = "abiword" ] then # Get Abiword binary path @@ -91,7 +90,6 @@ then # Set the path of soffice into Etherpad config ynh_replace_string --match_string="\"soffice\" : null" --replace_string="\"soffice\" : \"$soffice_path\"" --target_file="$install_dir/settings.json" fi -ynh_replace_string --match_string="__LANGUAGE__" --replace_string="$language" --target_file="$install_dir/settings.json" # Use ldap for mypads if [ $mypads -eq 1 ] && [ $useldap -eq 1 ] From 60de584ff445127eba27fe42eb578c72730d549d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sat, 28 Oct 2023 22:36:58 +0200 Subject: [PATCH 21/44] Update upgrade --- scripts/upgrade | 27 +++++++++++++-------------- 1 file changed, 13 insertions(+), 14 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index 6cfc080..b5de61c 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -63,13 +63,13 @@ ynh_systemd_action --service_name=$app --action="stop" ynh_script_progression --message="Ensuring downward compatibility..." --weight=2 # If abiword setting doesn't exist -if [ -z "$abiword" ]; then +if [ -z "${abiword:-}" ]; then abiword=0 ynh_app_setting_set --app=$app --key=abiword --value=$abiword fi # If abiword setting exists -if [ -n "$abiword" ]; then +if [ -n "${abiword:-}" ]; then if [ $abiword -eq 1 ]; then export=abiword fi @@ -78,49 +78,49 @@ if [ -n "$abiword" ]; then fi # If export setting doesn't exist -if [ -z "$export" ]; then +if [ -z "${export:-}" ]; then export=none ynh_app_setting_set --app=$app --key=export --value=$export fi # If mypads setting doesn't exist -if [ -z "$mypads" ]; then +if [ -z "${mypads:-}" ]; then mypads=1 ynh_app_setting_set --app=$app --key=mypads --value=$mypads fi # If useldap setting doesn't exist -if [ -z "$useldap" ]; then +if [ -z "${useldap:-}" ]; then useldap=0 ynh_app_setting_set --app=$app --key=useldap --value=$useldap fi # If path setting doesn't exist -if [ -z "$path" ]; then +if [ -z "${path:-}" ]; then path="/" ynh_app_setting_set --app=$app --key=path --value=$path fi # If overwrite_settings doesn't exist, create it -if [ -z "$overwrite_settings" ]; then +if [ -z "${overwrite_settings:-}" ]; then overwrite_settings=1 ynh_app_setting_set --app=$app --key=overwrite_settings --value=$overwrite_settings fi # If overwrite_credentials doesn't exist, create it -if [ -z "$overwrite_credentials" ]; then +if [ -z "${overwrite_credentials:-}" ]; then overwrite_credentials=1 ynh_app_setting_set --app=$app --key=overwrite_credentials --value=$overwrite_credentials fi # If overwrite_nginx doesn't exist, create it -if [ -z "$overwrite_nginx" ]; then +if [ -z "${overwrite_nginx:-}" ]; then overwrite_nginx=1 ynh_app_setting_set --app=$app --key=overwrite_nginx --value=$overwrite_nginx fi # If overwrite_systemd doesn't exist, create it -if [ -z "$overwrite_systemd" ]; then +if [ -z "${overwrite_systemd:-}" ]; then overwrite_systemd=1 ynh_app_setting_set --app=$app --key=overwrite_systemd --value=$overwrite_systemd fi @@ -186,8 +186,8 @@ then then # Verify the checksum of a file, stored by `ynh_store_file_checksum` in the install script. ynh_backup_if_checksum_is_different --file="$install_dir/settings.json" - cp ../conf/settings.json "$install_dir/settings.json" - ynh_replace_string --match_string="__PORT__" --replace_string="$port" --target_file="$install_dir/settings.json" + + ynh_add_config --template="../conf/settings.json" --destination="$install_dir/settings.json" if [ "$export" = "abiword" ] then @@ -208,7 +208,6 @@ then language=en ynh_app_setting_set --app=$app --key=language --value=$language fi - ynh_replace_string --match_string="__LANGUAGE__" --replace_string="$language" --target_file="$install_dir/settings.json" # Use LDAP for MyPads if [ $mypads -eq 1 ] && [ $useldap -eq 1 ] @@ -298,7 +297,7 @@ popd #================================================= # UPGRADE NPM MODULES #================================================= -ynh_script_progression --message="Upgrading Etherpad..." --weight=60 +ynh_script_progression --message="Upgrading Etherpad..." --weight=10 pushd $install_dir ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH bin/installDeps.sh From a8dd6e6399301951ac0d08a3503e404e43d71def Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sat, 28 Oct 2023 22:38:38 +0200 Subject: [PATCH 22/44] clean --- conf/systemd.service | 3 ++- scripts/install | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/conf/systemd.service b/conf/systemd.service index cc46515..e92b888 100644 --- a/conf/systemd.service +++ b/conf/systemd.service @@ -9,7 +9,8 @@ Group=__APP__ WorkingDirectory=__INSTALL_DIR__/ Environment=NODE_ENV=production Environment="__YNH_NODE_LOAD_PATH__" -ExecStart=__YNH_NODE__ __INSTALL_DIR__/src/node/server.js +ExecStart=__INSTALL_DIR__/src/bin/run.sh +#ExecStart=__YNH_NODE__ __INSTALL_DIR__/src/node/server.js StandardOutput=append:/var/log/__APP__/etherpad.log StandardError=inherit Restart=always diff --git a/scripts/install b/scripts/install index 4028d6f..27f6a55 100644 --- a/scripts/install +++ b/scripts/install @@ -156,7 +156,7 @@ popd ynh_script_progression --message="Installing Etherpad..." --weight=90 pushd $install_dir - ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH bin/installDeps.sh + ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH src/bin/installDeps.sh popd #================================================= From c8c402c4cc2065ade5efadcef3c8934dd8cc1f16 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sat, 28 Oct 2023 22:39:55 +0200 Subject: [PATCH 23/44] Update upgrade --- scripts/upgrade | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/upgrade b/scripts/upgrade index b5de61c..b9d3dfc 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -300,7 +300,7 @@ popd ynh_script_progression --message="Upgrading Etherpad..." --weight=10 pushd $install_dir - ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH bin/installDeps.sh + ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH src/bin/installDeps.sh popd #================================================= From 21441cff1541563d5fefdd725014e18d7a190b39 Mon Sep 17 00:00:00 2001 From: Robles Rodolphe Date: Mon, 27 Nov 2023 04:42:24 +0100 Subject: [PATCH 24/44] Update settings.json resolve an issue since v1.9.1 --- conf/settings.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/conf/settings.json b/conf/settings.json index baf5fc3..bac69b4 100644 --- a/conf/settings.json +++ b/conf/settings.json @@ -194,8 +194,8 @@ "showChat": true, "showLineNumbers": true, "useMonospaceFont": false, - "userName": false, - "userColor": false, + "userName": null, + "userColor": null, "rtl": false, "alwaysShowChat": false, "chatAndUsers": false, From 69eba155eec90f133b3072131705801aa54b3552 Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Tue, 28 Nov 2023 08:59:54 +0000 Subject: [PATCH 25/44] Auto-update README --- README.md | 3 ++- README_fr.md | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index ca79108..1b5993f 100644 --- a/README.md +++ b/README.md @@ -34,7 +34,7 @@ This version of Etherpad is preconfigured with a collection of plugins: - [ep_subscript_and_superscript](https://www.npmjs.com/package/ep_subscript_and_superscript) - *Support for subscript and superscript* -**Shipped version:** 1.9.3~ynh1 +**Shipped version:** 1.9.4~ynh1 **Demo:** https://video.etherpad.com @@ -47,6 +47,7 @@ This version of Etherpad is preconfigured with a collection of plugins: * Official app website: * Official admin documentation: * Upstream app code repository: +* YunoHost Store: * Report a bug: ## Developer info diff --git a/README_fr.md b/README_fr.md index aa4d64f..3837642 100644 --- a/README_fr.md +++ b/README_fr.md @@ -34,7 +34,7 @@ Cette version d'Etherpad est préconfigurée avec une collection de plugins: - [ep_subscript_and_superscript](https://www.npmjs.com/package/ep_subscript_and_superscript) - *Support des exposants et indices* -**Version incluse :** 1.9.3~ynh1 +**Version incluse :** 1.9.4~ynh1 **Démo :** https://video.etherpad.com @@ -47,6 +47,7 @@ Cette version d'Etherpad est préconfigurée avec une collection de plugins: * Site officiel de l’app : * Documentation officielle de l’admin : * Dépôt de code officiel de l’app : +* YunoHost Store: * Signaler un bug : ## Informations pour les développeurs From f5a61802a859fae32d5e05a82fb3623c65f77df4 Mon Sep 17 00:00:00 2001 From: Alexandre Aubin <4533074+alexAubin@users.noreply.github.com> Date: Sun, 10 Dec 2023 22:11:06 +0100 Subject: [PATCH 26/44] sources: There's been many node dependency bump so let's try using a more recent commit ... --- manifest.toml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/manifest.toml b/manifest.toml index 84f5eef..2404549 100644 --- a/manifest.toml +++ b/manifest.toml @@ -80,8 +80,8 @@ ram.runtime = "50M" [resources.sources] [resources.sources.main] - url = "https://github.com/ether/etherpad-lite/archive/1.9.4.tar.gz" - sha256 = "5b8ccf2a3c92cbd9bb578f684bc52d2ea27fc3fb30cdc76341f9ccffe0c0ff7f" + url = "https://github.com/ether/etherpad-lite/archive/bbaa6a7e8dee3223dfed7a73397d599e3194c9a6.tar.gz" + sha256 = "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855" autoupdate.strategy = "latest_github_tag" [resources.system_user] From cd67c087cef18e850104cc8039241275284f9804 Mon Sep 17 00:00:00 2001 From: Alexandre Aubin <4533074+alexAubin@users.noreply.github.com> Date: Sun, 10 Dec 2023 22:19:48 +0100 Subject: [PATCH 27/44] We probably want to use ETHERPAD_PRODUCTION=true rather than having dev dependencies.. --- scripts/install | 2 +- scripts/upgrade | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/install b/scripts/install index 27f6a55..58912c2 100644 --- a/scripts/install +++ b/scripts/install @@ -156,7 +156,7 @@ popd ynh_script_progression --message="Installing Etherpad..." --weight=90 pushd $install_dir - ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH src/bin/installDeps.sh + ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH ETHERPAD_PRODUCTION=true src/bin/installDeps.sh popd #================================================= diff --git a/scripts/upgrade b/scripts/upgrade index b9d3dfc..0d41435 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -300,7 +300,7 @@ popd ynh_script_progression --message="Upgrading Etherpad..." --weight=10 pushd $install_dir - ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH src/bin/installDeps.sh + ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH ETHERPAD_PRODUCTION=true src/bin/installDeps.sh popd #================================================= From 20420635539d03ab819df79b5e827c564261a0a6 Mon Sep 17 00:00:00 2001 From: Alexandre Aubin <4533074+alexAubin@users.noreply.github.com> Date: Sun, 10 Dec 2023 22:23:59 +0100 Subject: [PATCH 28/44] sources: fix checksum --- manifest.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/manifest.toml b/manifest.toml index 2404549..d533efb 100644 --- a/manifest.toml +++ b/manifest.toml @@ -81,7 +81,7 @@ ram.runtime = "50M" [resources.sources.main] url = "https://github.com/ether/etherpad-lite/archive/bbaa6a7e8dee3223dfed7a73397d599e3194c9a6.tar.gz" - sha256 = "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855" + sha256 = "83a5c24e27e93e26d660f60724400d3f47e2780e4ec07a7a080310948836a589" autoupdate.strategy = "latest_github_tag" [resources.system_user] From f1de672c820ef81f6c2a9c15aeef10821894c841 Mon Sep 17 00:00:00 2001 From: Alexandre Aubin <4533074+alexAubin@users.noreply.github.com> Date: Sun, 10 Dec 2023 23:26:05 +0100 Subject: [PATCH 29/44] Update scripts/_common.sh: revert to node 14 in the hope to fix the package json hell with express-session --- scripts/_common.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/_common.sh b/scripts/_common.sh index 53abd29..e2d83e7 100755 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -5,7 +5,7 @@ #================================================= # NodeJS version -nodejs_version=16 +nodejs_version=14 # MyPads version # This variable is mostly used to force an upgrade of the package in case of new versions of MyPads. From 77f8435fb3badfd77249e537039bcf264cec375d Mon Sep 17 00:00:00 2001 From: Alexandre Aubin <4533074+alexAubin@users.noreply.github.com> Date: Sun, 10 Dec 2023 23:27:23 +0100 Subject: [PATCH 30/44] Update conf/systemd.service: production=true --- conf/systemd.service | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/conf/systemd.service b/conf/systemd.service index e92b888..df09538 100644 --- a/conf/systemd.service +++ b/conf/systemd.service @@ -7,7 +7,7 @@ Type=simple User=__APP__ Group=__APP__ WorkingDirectory=__INSTALL_DIR__/ -Environment=NODE_ENV=production +Environment=ETHERPAD_PRODUCTION=true Environment="__YNH_NODE_LOAD_PATH__" ExecStart=__INSTALL_DIR__/src/bin/run.sh #ExecStart=__YNH_NODE__ __INSTALL_DIR__/src/node/server.js From 2d56a02f9d57a531d1b0fe73f6e1d6fb087e22b4 Mon Sep 17 00:00:00 2001 From: Alexandre Aubin <4533074+alexAubin@users.noreply.github.com> Date: Sun, 10 Dec 2023 23:50:06 +0100 Subject: [PATCH 31/44] Update conf/systemd.service: revert to previous ExecStart syntax that seemed to be working in current master branch... --- conf/systemd.service | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/conf/systemd.service b/conf/systemd.service index df09538..0684052 100644 --- a/conf/systemd.service +++ b/conf/systemd.service @@ -9,8 +9,7 @@ Group=__APP__ WorkingDirectory=__INSTALL_DIR__/ Environment=ETHERPAD_PRODUCTION=true Environment="__YNH_NODE_LOAD_PATH__" -ExecStart=__INSTALL_DIR__/src/bin/run.sh -#ExecStart=__YNH_NODE__ __INSTALL_DIR__/src/node/server.js +ExecStart=__YNH_NODE__ __INSTALL_DIR__/src/node/server.js StandardOutput=append:/var/log/__APP__/etherpad.log StandardError=inherit Restart=always From 016825ae3e9d07754c3e9f1889649e9cb34b9151 Mon Sep 17 00:00:00 2001 From: Alexandre Aubin Date: Mon, 11 Dec 2023 00:04:31 +0100 Subject: [PATCH 32/44] sources: back to the real 1.9.4 ? x_x --- manifest.toml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/manifest.toml b/manifest.toml index d533efb..49ce555 100644 --- a/manifest.toml +++ b/manifest.toml @@ -80,8 +80,8 @@ ram.runtime = "50M" [resources.sources] [resources.sources.main] - url = "https://github.com/ether/etherpad-lite/archive/bbaa6a7e8dee3223dfed7a73397d599e3194c9a6.tar.gz" - sha256 = "83a5c24e27e93e26d660f60724400d3f47e2780e4ec07a7a080310948836a589" + url = "https://github.com/ether/etherpad-lite/archive/1.9.4.tar.gz" + sha256 = "5b8ccf2a3c92cbd9bb578f684bc52d2ea27fc3fb30cdc76341f9ccffe0c0ff7f" autoupdate.strategy = "latest_github_tag" [resources.system_user] @@ -112,4 +112,4 @@ ram.runtime = "50M" [resources.database] type = "mysql" - \ No newline at end of file + From 10e2bfe5bcaa90043b3036cda0e75424f49b431c Mon Sep 17 00:00:00 2001 From: Alexandre Aubin Date: Mon, 11 Dec 2023 00:10:40 +0100 Subject: [PATCH 33/44] Cleanup tests.toml --- tests.toml | 31 ++++++++++++++++--------------- 1 file changed, 16 insertions(+), 15 deletions(-) diff --git a/tests.toml b/tests.toml index 2d300eb..acca843 100644 --- a/tests.toml +++ b/tests.toml @@ -2,37 +2,38 @@ test_format = 1.0 [default] + exclude = ["install.private"] + # ------------------------------- # Default args to use for install # ------------------------------- - - args.export = "libreoffice" + + args.export = "none" args.mypads = 0 args.useldap = 0 - args.password = "admin!42" + args.password = "##SuperAdminPassword##" # ------------------------------- # Commits to test upgrade from # ------------------------------- - test_upgrade_from.4d613658.name = "Upgrade from 1.8.17" + test_upgrade_from.4d613658.name = "1.8.17" -# This is an additional test suite [with_mypads] args.export = "libreoffice" args.mypads = 1 args.useldap = 1 only = ["install.root"] -#[with_abiword] -# args.export = "abiword" -# args.mypads = 1 -# args.useldap = 1 -# only = ["install.root"] +[with_abiword] + args.export = "libreoffice" + args.mypads = 0 + args.useldap = 0 + only = ["install.root"] -#[without_export] -# args.export = "none" -# args.mypads = 1 -# args.useldap = 0 -# only = ["install.root"] +[with_libreoffice] + args.export = "libreoffice" + args.mypads = 0 + args.useldap = 0 + only = ["install.root"] From 3b19355854fdaa29043f9fa8437d276d8f82b0b9 Mon Sep 17 00:00:00 2001 From: Alexandre Aubin Date: Mon, 11 Dec 2023 00:17:43 +0100 Subject: [PATCH 34/44] Revert again to 1.9.1 ... --- manifest.toml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/manifest.toml b/manifest.toml index 49ce555..2cfbc3f 100644 --- a/manifest.toml +++ b/manifest.toml @@ -80,8 +80,8 @@ ram.runtime = "50M" [resources.sources] [resources.sources.main] - url = "https://github.com/ether/etherpad-lite/archive/1.9.4.tar.gz" - sha256 = "5b8ccf2a3c92cbd9bb578f684bc52d2ea27fc3fb30cdc76341f9ccffe0c0ff7f" + url = "https://github.com/ether/etherpad-lite/archive/1.9.1.tar.gz" + sha256 = "667741235a2bcd8d28a32f5e611b82fb2ea7d11525ff41b8b5478b05a987b047" autoupdate.strategy = "latest_github_tag" [resources.system_user] From f1c517ef341d867437c01217e83f08bf2cc7cdd7 Mon Sep 17 00:00:00 2001 From: Alexandre Aubin Date: Mon, 11 Dec 2023 00:52:20 +0100 Subject: [PATCH 35/44] Simplify ynh_replace_string madness to handle configuration --- conf/settings.json | 50 ++++++++++++------------- scripts/install | 26 ++++++------- scripts/upgrade | 91 ++++++++++++++-------------------------------- 3 files changed, 64 insertions(+), 103 deletions(-) diff --git a/conf/settings.json b/conf/settings.json index baf5fc3..99f4736 100644 --- a/conf/settings.json +++ b/conf/settings.json @@ -246,29 +246,29 @@ "highlightSelectedText": false }, // ep_mypads -//noldap "ep_mypads": { -//noldap "ldap": { -//noldap // Your LDAP URL -//noldap "url": "ldap://127.0.0.1", -//noldap // Where to search your users -//noldap "searchBase": "ou=users,dc=yunohost,dc=org", -//noldap // A LDAP filter ({{username}} is replaced by user's login) -//noldap "searchFilter": "(&(|(objectclass=posixAccount))(uid={{username}}))", -//noldap // LDAP properties mapping for MyPads -//noldap "properties": { -//noldap // Which LDAP property will be used as user's login? -//noldap "login": "uid", -//noldap // as user's email -//noldap "email": "mail", -//noldap // as user's firstname -//noldap "firstname": "givenName", -//noldap // as users's lastname -//noldap "lastname": "sn" -//noldap }, -//noldap // Default langage for LDAP created users -//noldap "defaultLang": "__LANGUAGE__" -//noldap } -//noldap }, +__COMMENT_IF_LDAP_DISABLED__ "ep_mypads": { +__COMMENT_IF_LDAP_DISABLED__ "ldap": { +__COMMENT_IF_LDAP_DISABLED__ // Your LDAP URL +__COMMENT_IF_LDAP_DISABLED__ "url": "ldap://127.0.0.1", +__COMMENT_IF_LDAP_DISABLED__ // Where to search your users +__COMMENT_IF_LDAP_DISABLED__ "searchBase": "ou=users,dc=yunohost,dc=org", +__COMMENT_IF_LDAP_DISABLED__ // A LDAP filter ({{username}} is replaced by user's login) +__COMMENT_IF_LDAP_DISABLED__ "searchFilter": "(&(|(objectclass=posixAccount))(uid={{username}}))", +__COMMENT_IF_LDAP_DISABLED__ // LDAP properties mapping for MyPads +__COMMENT_IF_LDAP_DISABLED__ "properties": { +__COMMENT_IF_LDAP_DISABLED__ // Which LDAP property will be used as user's login? +__COMMENT_IF_LDAP_DISABLED__ "login": "uid", +__COMMENT_IF_LDAP_DISABLED__ // as user's email +__COMMENT_IF_LDAP_DISABLED__ "email": "mail", +__COMMENT_IF_LDAP_DISABLED__ // as user's firstname +__COMMENT_IF_LDAP_DISABLED__ "firstname": "givenName", +__COMMENT_IF_LDAP_DISABLED__ // as users's lastname +__COMMENT_IF_LDAP_DISABLED__ "lastname": "sn" +__COMMENT_IF_LDAP_DISABLED__ }, +__COMMENT_IF_LDAP_DISABLED__ // Default langage for LDAP created users +__COMMENT_IF_LDAP_DISABLED__ "defaultLang": "__LANGUAGE__" +__COMMENT_IF_LDAP_DISABLED__ } +__COMMENT_IF_LDAP_DISABLED__ }, /* * Should we suppress errors from being visible in the default Pad Text? @@ -312,7 +312,7 @@ * it to null disables Abiword and will only allow plain text and HTML * import/exports. */ - "abiword" : null, + "abiword" : __ABIWORD_PATH__, /* * This is the absolute path to the soffice executable. @@ -320,7 +320,7 @@ * LibreOffice can be used in lieu of Abiword to export pads. * Setting it to null disables LibreOffice exporting. */ - "soffice" : null, + "soffice" : __SOFFICE_PATH__, /* * Path to the Tidy executable. diff --git a/scripts/install b/scripts/install index 58912c2..ce29600 100644 --- a/scripts/install +++ b/scripts/install @@ -73,34 +73,30 @@ chown $app -R /var/log/$app #================================================= # ADD A CONFIGURATION #================================================= -ynh_script_progression --message="Adding a configuration file..." --weight=6 +ynh_script_progression --message="Configure etherpad..." -ynh_add_config --template="../conf/settings.json" --destination="$install_dir/settings.json" +abiword_path="null" +soffice_path="null" -if [ "$export" = "abiword" ] +if [[ "$export" == "abiword" ]] then - # Get Abiword binary path - abiword_path=`which abiword` - # Set the path of abiword into Etherpad config - ynh_replace_string --match_string="\"abiword\" : null" --replace_string="\"abiword\" : \"$abiword_path\"" --target_file="$install_dir/settings.json" -elif [ "$export" = "libreoffice" ] + abiword_path="\"$(which abiword)\"" +elif [[ "$export" == "libreoffice" ]] then - # Get soffice binary path - soffice_path=`which soffice` - # Set the path of soffice into Etherpad config - ynh_replace_string --match_string="\"soffice\" : null" --replace_string="\"soffice\" : \"$soffice_path\"" --target_file="$install_dir/settings.json" + soffice_path="\"$(which soffice)\"" fi # Use ldap for mypads +comment_if_ldap_disabled="//ldap_disabled" if [ $mypads -eq 1 ] && [ $useldap -eq 1 ] then - ynh_replace_string --match_string="//noldap\(.*\)" --replace_string="\1 //useldap" --target_file="$install_dir/settings.json" + comment_if_ldap_disabled="" fi # Calculate and store the config file checksum into the app settings -ynh_store_file_checksum --file="$install_dir/settings.json" -ynh_add_config --template="../conf/credentials.json" --destination="$install_dir/credentials.json" +ynh_add_config --template="settings.json" --destination="$install_dir/settings.json" +ynh_add_config --template="credentials.json" --destination="$install_dir/credentials.json" chmod 600 "$install_dir/settings.json" chown $app:$app "$install_dir/settings.json" diff --git a/scripts/upgrade b/scripts/upgrade index 0d41435..c92b8cb 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -77,6 +77,12 @@ if [ -n "${abiword:-}" ]; then ynh_app_setting_delete --app=$app --key=abiword fi +if [ -z "${language:-}" ]; then + # If upgrading from a version which doesn't support translations, set language to English by default + language=en + ynh_app_setting_set --app=$app --key=language --value=$language +fi + # If export setting doesn't exist if [ -z "${export:-}" ]; then export=none @@ -177,72 +183,31 @@ chown $app -R /var/log/$app # CONFIGURE ETHERPAD #================================================= -if [ "$upgrade_type" == "UPGRADE_APP" ] +ynh_script_progression --message="Configure etherpad..." + +abiword_path="null" +soffice_path="null" + +if [[ "$export" == "abiword" ]] then - ynh_script_progression --message="Reconfiguring Etherpad..." --weight=3 - - # Overwrite the settings config file only if it's allowed - if [ $overwrite_settings -eq 1 ] - then - # Verify the checksum of a file, stored by `ynh_store_file_checksum` in the install script. - ynh_backup_if_checksum_is_different --file="$install_dir/settings.json" - - ynh_add_config --template="../conf/settings.json" --destination="$install_dir/settings.json" - - if [ "$export" = "abiword" ] - then - # Get abiword binary path - abiword_path=`which abiword` - # Set the path of Abiword into Etherpad config - ynh_replace_string --match_string="\"abiword\" : null" --replace_string="\"abiword\" : \"$abiword_path\"" --target_file="$install_dir/settings.json" - elif [ "$export" = "libreoffice" ] - then - # Get soffice binary path - soffice_path=`which soffice` - # Set the path of soffice into Etherpad config - ynh_replace_string --match_string="\"soffice\" : null" --replace_string="\"soffice\" : \"$soffice_path\"" --target_file="$install_dir/settings.json" - fi - - if test -z "$language"; then - # If upgrading from a version which doesn't support translations, set language to English by default - language=en - ynh_app_setting_set --app=$app --key=language --value=$language - fi - - # Use LDAP for MyPads - if [ $mypads -eq 1 ] && [ $useldap -eq 1 ] - then - ynh_replace_string --match_string="//noldap" --replace_string="" --target_file="$install_dir/settings.json" - fi - - # Optional parameters from config-panel feature - if [ -n "$pad_config_nocolors" ]; then - ynh_replace_string --match_string="\(\"noColors\" *: \).*," --replace_string="\1$pad_config_nocolors," --target_file="$install_dir/settings.json" - fi - if [ -n "$pad_config_showlinenumbers" ]; then - ynh_replace_string --match_string="\(\"showLineNumbers\" *: \).*," --replace_string="\1$pad_config_showlinenumbers," --target_file="$install_dir/settings.json" - fi - if [ -n "$pad_config_chatandusers" ]; then - ynh_replace_string --match_string="\(\"chatAndUsers\" *: \).*," --replace_string="\1$pad_config_chatandusers," --target_file="$install_dir/settings.json" - fi - if [ -n "$pad_config_alwaysshowchat" ]; then - ynh_replace_string --match_string="\(\"alwaysShowChat\" *: \).*," --replace_string="\1$pad_config_alwaysshowchat," --target_file="$install_dir/settings.json" - fi - if [ -n "$pad_config_show_markdown" ]; then - ynh_replace_string --match_string="\(\"ep_markdown_default\" *: \).*," --replace_string="\1$pad_config_show_markdown," --target_file="$install_dir/settings.json" - fi - - # Recalculate and store the checksum of the file for the next upgrade. - ynh_store_file_checksum --file="$install_dir/settings.json" - fi - - # Overwrite the credentials config file only if it's allowed - if [ $overwrite_credentials -eq 1 ] - then - ynh_add_config --template="../conf/credentials.json" --destination="$install_dir/credentials.json" - fi + abiword_path="\"$(which abiword)\"" +elif [[ "$export" == "libreoffice" ]] +then + soffice_path="\"$(which soffice)\"" fi +# Use ldap for mypads +comment_if_ldap_disabled="//ldap_disabled" +if [ $mypads -eq 1 ] && [ $useldap -eq 1 ] +then + comment_if_ldap_disabled="" +fi + +# Calculate and store the config file checksum into the app settings + +ynh_add_config --template="settings.json" --destination="$install_dir/settings.json" +ynh_add_config --template="credentials.json" --destination="$install_dir/credentials.json" + chmod 600 "$install_dir/settings.json" chown $app:$app "$install_dir/settings.json" From 3e5cd682e4cb97a3e528e39fe3f858c15bc10bf1 Mon Sep 17 00:00:00 2001 From: Alexandre Aubin Date: Mon, 11 Dec 2023 01:08:57 +0100 Subject: [PATCH 36/44] More madness cleanup ... the whole thing about config panel is unmainained, trash it, simplify everything --- config_panel.toml.example | 84 ------------ scripts/_common.sh | 16 --- scripts/config | 264 -------------------------------------- scripts/install | 19 +-- scripts/remove | 7 - scripts/restore | 31 ++--- scripts/upgrade | 94 +------------- 7 files changed, 15 insertions(+), 500 deletions(-) delete mode 100644 config_panel.toml.example delete mode 100644 scripts/config diff --git a/config_panel.toml.example b/config_panel.toml.example deleted file mode 100644 index 604bb12..0000000 --- a/config_panel.toml.example +++ /dev/null @@ -1,84 +0,0 @@ -version = "1.0" - -[main] -name = "Etherpad configuration" - - - [main.export] - name = "Export" - - [main.export.export] - ask = "Use AbiWord (~260 Mo) or LibreOffice (~400 Mo) (more stable) to expand export possibilities (PDF, doc)?" - choices = ["none", "abiword", "libreoffice"] - default = "none" - - - [main.pad_configuration] - name = "Default pad configuration" - - [main.pad_configuration.pad_config_nocolors] - ask = "Hide authorship colors?" - type = "boolean" - default = false - - [main.pad_configuration.pad_config_showlinenumbers] - ask = "Show line numbers?" - type = "boolean" - default = true - - [main.pad_configuration.pad_config_chatandusers] - ask = "Show chat and users?" - type = "boolean" - default = false - - [main.pad_configuration.pad_config_alwaysshowchat] - ask = "Always show chat?" - type = "boolean" - default = false - - [main.pad_configuration.pad_config_show_markdown] - ask = "Show markdown syntax?" - type = "boolean" - default = false - - - [main.mypads_configuration] - name = "MyPads configuration" - - [main.mypads_configuration.mypads] - ask = "Enable MyPads plugin?" - type = "boolean" - default = true - - [main.mypads_configuration.useldap] - ask = "Use LDAP with MyPads?" - type = "boolean" - default = true - - - [main.overwrite_files] - name = "Overwriting config files during an upgrade" - - [main.overwrite_files.overwrite_settings] - ask = "Overwrite the config file settings.json?" - type = "boolean" - default = true - help = "If the file is overwritten, a backup will be created." - - [main.overwrite_files.overwrite_credentials] - ask = "Overwrite the config file credentials.json?" - type = "boolean" - default = true - help = "If the file is overwritten, a backup will be created." - - [main.overwrite_files.overwrite_nginx] - ask = "Overwrite the NGINX config file?" - type = "boolean" - default = true - help = "If the file is overwritten, a backup will be created." - - [main.overwrite_files.overwrite_systemd] - ask = "Overwrite the systemd config file?" - type = "boolean" - default = true - help = "If the file is overwritten, a backup will be created." diff --git a/scripts/_common.sh b/scripts/_common.sh index e2d83e7..d8e6290 100755 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -33,14 +33,6 @@ ep_font_size_version=0.4.44 #================================================= ynh_maintenance_mode_ON () { - # Load value of $path and $domain from the config if their not set - if [ -z $path ]; then - path=$(ynh_app_setting_get $app path) - fi - if [ -z $domain ]; then - domain=$(ynh_app_setting_get $app domain) - fi - mkdir -p /var/www/html/ # Create an html to serve as maintenance notice @@ -89,14 +81,6 @@ include conf.d/yunohost_panel.conf.inc; } ynh_maintenance_mode_OFF () { - # Load value of $path and $domain from the config if their not set - if [ -z $path ]; then - path=$(ynh_app_setting_get $app path) - fi - if [ -z $domain ]; then - domain=$(ynh_app_setting_get $app domain) - fi - # Rewrite the nginx config file to redirect from ${path}_maintenance to the real url of the app. echo "rewrite ^${path}_maintenance/(.*)$ ${path}/\$1 redirect;" > "/etc/nginx/conf.d/$domain.d/maintenance.$app.conf" systemctl reload nginx diff --git a/scripts/config b/scripts/config deleted file mode 100644 index fc3a7d0..0000000 --- a/scripts/config +++ /dev/null @@ -1,264 +0,0 @@ -#!/bin/bash - -#================================================= -# GENERIC STARTING -#================================================= -# IMPORT GENERIC HELPERS -#================================================= - -# Load common variables for all scripts. -source _common.sh -source /usr/share/yunohost/helpers - -#================================================= -# SPECIFIC CODE -#================================================= -# DECLARE GENERIC FUNCTION -#================================================= - -config_file="$final_path/settings.json" - -get_config_value() { - option_name="$1" - # Get the value of this option in the config file - grep "^ *\"$option_name\" *:" "$config_file" | cut -d':' -f2 | sed s'/[ \"]//g' | cut -d',' -f1 -} - -#================================================= -# LOAD VALUES -#================================================= - -# Load the real value from the app config or elsewhere. -# Then get the value from the form. -# If the form has a value for a variable, take the value from the form, -# Otherwise, keep the value from the app config. - -# Export -old_export="$(ynh_app_setting_get $app export)" -export="${YNH_CONFIG_MAIN_EXPORT_EXPORT:-$old_export}" - -# padOptions noColors -old_pad_config_nocolors="$(get_config_value noColors)" -pad_config_nocolors="${YNH_CONFIG_MAIN_PAD_CONFIGURATION_PAD_CONFIG_NOCOLORS:-$old_pad_config_nocolors}" - -# padOptions showLineNumbers -old_pad_config_showlinenumbers="$(get_config_value showLineNumbers)" -pad_config_showlinenumbers="${YNH_CONFIG_MAIN_PAD_CONFIGURATION_PAD_CONFIG_SHOWLINENUMBERS:-$old_pad_config_showlinenumbers}" - -# padOptions chatAndUsers -old_pad_config_chatandusers="$(get_config_value chatAndUsers)" -pad_config_chatandusers="${YNH_CONFIG_MAIN_PAD_CONFIGURATION_PAD_CONFIG_CHATANDUSERS:-$old_pad_config_chatandusers}" - -# padOptions alwaysShowChat -old_pad_config_alwaysshowchat="$(get_config_value alwaysShowChat)" -pad_config_alwaysshowchat="${YNH_CONFIG_MAIN_PAD_CONFIGURATION_PAD_CONFIG_ALWAYSSHOWCHAT:-$old_pad_config_alwaysshowchat}" - -# Plugin option ep_markdown_default -old_pad_config_show_markdown="$(get_config_value ep_markdown_default)" -pad_config_show_markdown="${YNH_CONFIG_MAIN_PAD_CONFIGURATION_PAD_CONFIG_SHOW_MARKDOWN:-$old_pad_config_show_markdown}" - -# MyPads -if [ -d $final_path/node_modules/ep_mypads ] -then - # Enable - old_mypads=1 -else - # Disable - old_mypads=0 -fi -mypads="${YNH_CONFIG_MAIN_MYPADS_CONFIGURATION_MYPADS:-$old_mypads}" - -# LDAP for MyPads -if grep -q "//noldap" $config_file -then - # Disable - old_useldap=0 -else - # Enable - old_useldap=1 -fi -useldap="${YNH_CONFIG_MAIN_MYPADS_CONFIGURATION_USELDAP:-$old_useldap}" - -# Overwrite settings.json file -old_overwrite_settings="$(ynh_app_setting_get --app=$app --key=overwrite_settings)" -overwrite_settings="${YNH_CONFIG_MAIN_OVERWRITE_FILES_OVERWRITE_SETTINGS:-$old_overwrite_settings}" - -# Overwrite credentials.json file -old_overwrite_credentials="$(ynh_app_setting_get --app=$app --key=overwrite_credentials)" -overwrite_credentials="${YNH_CONFIG_MAIN_OVERWRITE_FILES_OVERWRITE_CREDENTIALS:-$old_overwrite_credentials}" - -# Overwrite nginx configuration -old_overwrite_nginx="$(ynh_app_setting_get --app=$app --key=overwrite_nginx)" -overwrite_nginx="${YNH_CONFIG_MAIN_OVERWRITE_FILES_OVERWRITE_NGINX:-$old_overwrite_nginx}" - -# Overwrite systemd configuration -old_overwrite_systemd="$(ynh_app_setting_get --app=$app --key=overwrite_systemd)" -overwrite_systemd="${YNH_CONFIG_MAIN_OVERWRITE_FILES_OVERWRITE_SYSTEMD:-$old_overwrite_systemd}" - -#================================================= -# SHOW_CONFIG FUNCTION FOR 'SHOW' COMMAND -#================================================= - -show_config() { - # here you are supposed to read some config file/database/other then print the values - # ynh_return "YNH_CONFIG_${PANEL_ID}_${SECTION_ID}_${OPTION_ID}=value" - - ynh_return "YNH_CONFIG_MAIN_EXPORT_EXPORT=$export" - - ynh_return "YNH_CONFIG_MAIN_PAD_CONFIGURATION_PAD_CONFIG_NOCOLORS=$pad_config_nocolors" - ynh_return "YNH_CONFIG_MAIN_PAD_CONFIGURATION_PAD_CONFIG_SHOWLINENUMBERS=$pad_config_showlinenumbers" - ynh_return "YNH_CONFIG_MAIN_PAD_CONFIGURATION_PAD_CONFIG_CHATANDUSERS=$pad_config_chatandusers" - ynh_return "YNH_CONFIG_MAIN_PAD_CONFIGURATION_PAD_CONFIG_ALWAYSSHOWCHAT=$pad_config_alwaysshowchat" - ynh_return "YNH_CONFIG_MAIN_PAD_CONFIGURATION_PAD_CONFIG_SHOW_MARKDOWN=$pad_config_show_markdown" - ynh_return "YNH_CONFIG_MAIN_MYPADS_CONFIGURATION_MYPADS=$mypads" - ynh_return "YNH_CONFIG_MAIN_MYPADS_CONFIGURATION_USELDAP=$useldap" - ynh_return "YNH_CONFIG_MAIN_OVERWRITE_FILES_OVERWRITE_SETTINGS=$overwrite_settings" - ynh_return "YNH_CONFIG_MAIN_OVERWRITE_FILES_OVERWRITE_CREDENTIALS=$overwrite_credentials" - ynh_return "YNH_CONFIG_MAIN_OVERWRITE_FILES_OVERWRITE_NGINX=$overwrite_nginx" - ynh_return "YNH_CONFIG_MAIN_OVERWRITE_FILES_OVERWRITE_SYSTEMD=$overwrite_systemd" -} - -#================================================= -# MODIFY THE CONFIGURATION -#================================================= - -apply_config() { - - #================================================= - # MODIFY ETHERPAD CONFIG - #================================================= - - restart_etherpad=0 - - # Change configuration if needed - # padOptions noColors - if [ "$pad_config_nocolors" != "$old_pad_config_nocolors" ] - then - ynh_replace_string --match_string="\(\"noColors\" *: \).*," --replace_string="\1$pad_config_nocolors," --target_file="$config_file" - ynh_app_setting_set --app=$app --key=pad_config_nocolors --value="$pad_config_nocolors" - restart_etherpad=1 - fi - - # padOptions showLineNumbers - if [ "$pad_config_showlinenumbers" != "$old_pad_config_showlinenumbers" ] - then - ynh_replace_string --match_string="\(\"showLineNumbers\" *: \).*," --replace_string="\1$pad_config_showlinenumbers," --target_file="$config_file" - ynh_app_setting_set --app=$app --key=pad_config_showlinenumbers --value="$pad_config_showlinenumbers" - restart_etherpad=1 - fi - - # padOptions chatAndUsers - if [ "$pad_config_chatandusers" != "$old_pad_config_chatandusers" ] - then - ynh_replace_string --match_string="\(\"chatAndUsers\" *: \).*," --replace_string="\1$pad_config_chatandusers," --target_file="$config_file" - ynh_app_setting_set --app=$app --key=pad_config_chatandusers --value="$pad_config_chatandusers" - restart_etherpad=1 - fi - - # padOptions alwaysShowChat - if [ "$pad_config_alwaysshowchat" != "$old_pad_config_alwaysshowchat" ] - then - ynh_replace_string --match_string="\(\"alwaysShowChat\" *: \).*," --replace_string="\1$pad_config_alwaysshowchat," --target_file="$config_file" - ynh_app_setting_set --app=$app --key=pad_config_alwaysshowchat --value="$pad_config_alwaysshowchat" - restart_etherpad=1 - fi - - # Plugin option ep_markdown_default - if [ "$pad_config_show_markdown" != "$old_pad_config_show_markdown" ] - then - ynh_replace_string --match_string="\(\"ep_markdown_default\" *: \).*," --replace_string="\1$pad_config_show_markdown," --target_file="$config_file" - ynh_app_setting_set --app=$app --key=pad_config_show_markdown --value="$pad_config_show_markdown" - restart_etherpad=1 - fi - - # Export - if [ "$export" != "$old_export" ] - then - if [ "$export" = "abiword" ] - then - # if Abiword isn't installed, call the action add_remove_abiword. - if ! which abiword > /dev/null - then - yunohost app action run $app add_remove_abiword - fi - ynh_replace_string --match_string="\(\"abiword\" *: \).*," --replace_string="\1\"$(which abiword)\"," --target_file="$config_file" - ynh_replace_string --match_string="\(\"soffice\" *: \).*," --replace_string="\1null," --target_file="$config_file" - elif [ "$export" = "libreoffice" ] - then - # if LibreOffice isn't installed, call the action add_remove_libreoffice. - if ! which soffice > /dev/null - then - yunohost app action run $app add_remove_libreoffice - fi - ynh_replace_string --match_string="\(\"abiword\" *: \).*," --replace_string="\1null," --target_file="$config_file" - ynh_replace_string --match_string="\(\"soffice\" *: \).*," --replace_string="\1\"$(which soffice)\"," --target_file="$config_file" - else - ynh_replace_string --match_string="\(\"abiword\" *: \).*," --replace_string="\1null," --target_file="$config_file" - ynh_replace_string --match_string="\(\"soffice\" *: \).*," --replace_string="\1null," --target_file="$config_file" - fi - - ynh_app_setting_set --app=$app --key=export --value="$export" - - restart_etherpad=1 - fi - - # MyPads - if [ "$mypads" != "$old_mypads" ] - then - ynh_use_nodejs - #pushd "$final_path/src" - #ynh_secure_remove --file="$final_path/src/package-lock.json" #added to fix saveError ENOENT: no such file or directory - if [ "$mypads" = "1" ] - then - ynh_exec_as $app env "$ynh_node_load_PATH" npm install ep_mypads@${mypads_version} - else - ynh_exec_as $app env "$ynh_node_load_PATH" npm uninstall ep_mypads - fi - popd - chown -R $app: $final_path/node_modules - - ynh_app_setting_set --app=$app --key=mypads --value="$mypads" - - restart_etherpad=1 - fi - - # LDAP for MyPads - if [ "$useldap" != "$old_useldap" ] - then - if [ "$useldap" = "1" ] - then - ynh_replace_string --match_string="//noldap\(.*\)" --replace_string="\1 //useldap" --target_file="$final_path/settings.json" - else - ynh_replace_string --match_string="\(.*\) //useldap" --replace_string="//noldap\1" --target_file="$final_path/settings.json" - fi - - ynh_app_setting_set --app=$app --key=useldap --value="$useldap" - - restart_etherpad=1 - fi - - - if [ $restart_etherpad -eq 1 ] - then - # Wait for etherpad to be fully started - ynh_systemd_action --action=restart --line_match="You can access your Etherpad instance at" --log_path="/var/log/$app/etherpad.log" --timeout="120" - fi - - #================================================= - # MODIFY OVERWRITTING SETTINGS - #================================================= - - # Set overwrite_settings - ynh_app_setting_set --app=$app --key=overwrite_settings --value="$overwrite_settings" - # Set overwrite_credentials - ynh_app_setting_set --app=$app --key=overwrite_credentials --value="$overwrite_credentials" - # Set overwrite_nginx - ynh_app_setting_set --app=$app --key=overwrite_nginx --value="$overwrite_nginx" - # Set overwrite_systemd - ynh_app_setting_set --app=$app --key=overwrite_systemd --value="$overwrite_systemd" -} - -#================================================= -# GENERIC FINALIZATION -#================================================= -ynh_app_config_run $1 diff --git a/scripts/install b/scripts/install index ce29600..5595ee1 100644 --- a/scripts/install +++ b/scripts/install @@ -1,29 +1,12 @@ #!/bin/bash -#================================================= -# GENERIC START -#================================================= -# IMPORT GENERIC HELPERS -#================================================= - if [ ${PACKAGE_CHECK_EXEC:-0} -eq 1 ]; then - sleep 60 + sleep 10 fi source _common.sh source /usr/share/yunohost/helpers -#================================================= -# RETRIEVE ARGUMENTS FROM THE MANIFEST -#================================================= - -password="$YNH_APP_ARG_PASSWORD" - -ynh_app_setting_set --app=$app --key=overwrite_settings --value="1" -ynh_app_setting_set --app=$app --key=overwrite_credentials --value="1" -ynh_app_setting_set --app=$app --key=overwrite_nginx --value="1" -ynh_app_setting_set --app=$app --key=overwrite_systemd --value="1" - #================================================= # INSTALL DEPENDENCIES #================================================= diff --git a/scripts/remove b/scripts/remove index 5008d7e..60e0cd2 100755 --- a/scripts/remove +++ b/scripts/remove @@ -9,13 +9,6 @@ source _common.sh source /usr/share/yunohost/helpers -#================================================= -# LOAD SETTINGS -#================================================= -ynh_script_progression --message="Loading installation settings..." --weight=3 - -export=$(ynh_app_setting_get --app=$app --key=export) - #================================================= # REMOVE SYSTEM CONFIGURATIONS #================================================= diff --git a/scripts/restore b/scripts/restore index 7005a1c..78789ad 100644 --- a/scripts/restore +++ b/scripts/restore @@ -1,26 +1,13 @@ #!/bin/bash -#================================================= -# GENERIC START -#================================================= -# IMPORT GENERIC HELPERS -#================================================= - -# Keep this path for calling _common.sh inside the execution's context of backup and restore scripts source ../settings/scripts/_common.sh source /usr/share/yunohost/helpers -#================================================= -# LOAD SETTINGS -#================================================= -ynh_script_progression --message="Loading installation settings..." --weight=3 - -password=$(ynh_app_setting_get --app=$app --key=password) - #================================================= # RESTORE THE APP MAIN DIR #================================================= -ynh_script_progression --message="Restoring the app main directory..." --weight=2 +# +ynh_script_progression --message="Restoring the app main directory..." --weight=5 ynh_restore_file --origin_path="$install_dir" @@ -38,11 +25,7 @@ chown $app:$app "$install_dir/credentials.json" #================================================= # RESTORE THE PHP-FPM CONFIGURATION #================================================= -ynh_script_progression --message="Restoring system configurations related to $app..." --weight=1 - -ynh_restore_file --origin_path="/etc/fail2ban/jail.d/$app.conf" -ynh_restore_file --origin_path="/etc/fail2ban/filter.d/$app.conf" -ynh_systemd_action --action=restart --service_name=fail2ban +ynh_script_progression --message="Restoring system configurations related to $app..." ynh_install_nodejs --nodejs_version=$nodejs_version ynh_use_nodejs @@ -60,10 +43,14 @@ ynh_restore_file --origin_path="/etc/logrotate.d/$app" yunohost service add $app --description="Collaborative editor" --log="/var/log/$app/etherpad.log" +ynh_restore_file --origin_path="/etc/fail2ban/jail.d/$app.conf" +ynh_restore_file --origin_path="/etc/fail2ban/filter.d/$app.conf" +ynh_systemd_action --action=restart --service_name=fail2ban + #================================================= # RESTORE THE MYSQL DATABASE #================================================= -ynh_script_progression --message="Restoring the MySQL database..." --weight=2 +ynh_script_progression --message="Restoring the MySQL database..." --weight=5 echo "ALTER DATABASE $db_name CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci" | ynh_mysql_connect_as --user=$db_user --password=$db_pwd --database=$db_name ynh_mysql_connect_as --user=$db_user --password=$db_pwd --database=$db_name < ./db.sql @@ -73,7 +60,7 @@ ynh_mysql_connect_as --user=$db_user --password=$db_pwd --database=$db_name < ./ #================================================= # RELOAD NGINX AND PHP-FPM OR THE APP SERVICE #================================================= -ynh_script_progression --message="Reloading NGINX web server and $app's service..." --weight=1 +ynh_script_progression --message="Reloading NGINX web server and $app's service..." ynh_systemd_action --service_name=$app --action=restart --line_match="You can access your Etherpad instance at" --log_path="/var/log/$app/etherpad.log" --timeout="120" diff --git a/scripts/upgrade b/scripts/upgrade index c92b8cb..ed0dab2 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -1,44 +1,8 @@ #!/bin/bash -#================================================= -# GENERIC START -#================================================= -# IMPORT GENERIC HELPERS -#================================================= - source _common.sh source /usr/share/yunohost/helpers -#================================================= -# LOAD SETTINGS -#================================================= -ynh_script_progression --message="Loading installation settings..." --weight=20 - -export=$(ynh_app_setting_get --app=$app --key=export) -password=$(ynh_app_setting_get --app=$app --key=password) -mypads=$(ynh_app_setting_get --app=$app --key=mypads) -useldap=$(ynh_app_setting_get --app=$app --key=useldap) -abiword=$(ynh_app_setting_get --app=$app --key=abiword) -overwrite_settings=$(ynh_app_setting_get --app=$app --key=overwrite_settings) -overwrite_credentials=$(ynh_app_setting_get --app=$app --key=overwrite_credentials) -overwrite_nginx=$(ynh_app_setting_get --app=$app --key=overwrite_nginx) -overwrite_systemd=$(ynh_app_setting_get --app=$app --key=overwrite_systemd) - -# Optional parameters from config-panel feature -pad_config_nocolors=$(ynh_app_setting_get --app=$app --key=pad_config_nocolors) -pad_config_showlinenumbers=$(ynh_app_setting_get --app=$app --key=pad_config_showlinenumbers) -pad_config_chatandusers=$(ynh_app_setting_get --app=$app --key=pad_config_chatandusers) -pad_config_alwaysshowchat=$(ynh_app_setting_get --app=$app --key=pad_config_alwaysshowchat) -pad_config_show_markdown=$(ynh_app_setting_get --app=$app --key=pad_config_show_markdown) - -#================================================= -# CHECK VERSION -#================================================= -ynh_script_progression --message="Checking version..." --weight=1 - -# Wait for etherpad to be fully started -ynh_systemd_action --action=restart --line_match="You can access your Etherpad instance at" --log_path="/var/log/$app/etherpad.log" --timeout="120" - upgrade_type=$(ynh_check_app_version_changed) #================================================= @@ -46,6 +10,9 @@ upgrade_type=$(ynh_check_app_version_changed) #================================================= ynh_script_progression --message="Activating maintenance mode..." --weight=2 +# Wait for etherpad to be fully started # (... but why ???) +ynh_systemd_action --action=restart --line_match="You can access your Etherpad instance at" --log_path="/var/log/$app/etherpad.log" --timeout="120" + ynh_maintenance_mode_ON #================================================= @@ -62,75 +29,32 @@ ynh_systemd_action --service_name=$app --action="stop" #================================================= ynh_script_progression --message="Ensuring downward compatibility..." --weight=2 -# If abiword setting doesn't exist -if [ -z "${abiword:-}" ]; then - abiword=0 - ynh_app_setting_set --app=$app --key=abiword --value=$abiword -fi - -# If abiword setting exists -if [ -n "${abiword:-}" ]; then - if [ $abiword -eq 1 ]; then - export=abiword - fi - ynh_app_setting_set --app=$app --key=export --value=$export - ynh_app_setting_delete --app=$app --key=abiword -fi - if [ -z "${language:-}" ]; then # If upgrading from a version which doesn't support translations, set language to English by default language=en ynh_app_setting_set --app=$app --key=language --value=$language fi -# If export setting doesn't exist if [ -z "${export:-}" ]; then export=none ynh_app_setting_set --app=$app --key=export --value=$export fi -# If mypads setting doesn't exist if [ -z "${mypads:-}" ]; then mypads=1 ynh_app_setting_set --app=$app --key=mypads --value=$mypads fi -# If useldap setting doesn't exist if [ -z "${useldap:-}" ]; then useldap=0 ynh_app_setting_set --app=$app --key=useldap --value=$useldap fi -# If path setting doesn't exist if [ -z "${path:-}" ]; then path="/" ynh_app_setting_set --app=$app --key=path --value=$path fi -# If overwrite_settings doesn't exist, create it -if [ -z "${overwrite_settings:-}" ]; then - overwrite_settings=1 - ynh_app_setting_set --app=$app --key=overwrite_settings --value=$overwrite_settings -fi - -# If overwrite_credentials doesn't exist, create it -if [ -z "${overwrite_credentials:-}" ]; then - overwrite_credentials=1 - ynh_app_setting_set --app=$app --key=overwrite_credentials --value=$overwrite_credentials -fi - -# If overwrite_nginx doesn't exist, create it -if [ -z "${overwrite_nginx:-}" ]; then - overwrite_nginx=1 - ynh_app_setting_set --app=$app --key=overwrite_nginx --value=$overwrite_nginx -fi - -# If overwrite_systemd doesn't exist, create it -if [ -z "${overwrite_systemd:-}" ]; then - overwrite_systemd=1 - ynh_app_setting_set --app=$app --key=overwrite_systemd --value=$overwrite_systemd -fi - # Support full Unicode in MySQL databases ynh_mysql_connect_as --user=$db_user --password="$db_pwd" --database=$db_name \ <<< "ALTER DATABASE $db_name CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci;" @@ -163,11 +87,7 @@ ynh_use_nodejs #================================================= ynh_script_progression --message="Upgrading NGINX web server configuration..." --weight=2 -# Overwrite the NGINX configuration only if it's allowed -if [ $overwrite_nginx -eq 1 ] -then - ynh_add_nginx_config -fi +ynh_add_nginx_config #================================================= # SPECIFIC UPGRADE @@ -219,11 +139,7 @@ chown $app:$app "$install_dir/credentials.json" #================================================= ynh_script_progression --message="Upgrading systemd configuration..." --weight=2 -# Create a dedicated systemd config -if [ $overwrite_systemd -eq 1 ] -then - ynh_add_systemd_config -fi +ynh_add_systemd_config #================================================= # INSTALL ETHERPAD'S PLUGINS From 648503a3661764478029ba254af1dc04ab740986 Mon Sep 17 00:00:00 2001 From: Alexandre Aubin Date: Mon, 11 Dec 2023 01:48:52 +0100 Subject: [PATCH 37/44] Save the password as setting to be able to later regenerate the conf file --- scripts/install | 3 +++ scripts/upgrade | 5 +++++ 2 files changed, 8 insertions(+) diff --git a/scripts/install b/scripts/install index 5595ee1..99e7840 100644 --- a/scripts/install +++ b/scripts/install @@ -7,6 +7,9 @@ fi source _common.sh source /usr/share/yunohost/helpers +# Save the passord (not saved automatically by the core) +ynh_app_setting_set --app=$app --key=password --value="$password" + #================================================= # INSTALL DEPENDENCIES #================================================= diff --git a/scripts/upgrade b/scripts/upgrade index ed0dab2..6a43c06 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -55,6 +55,11 @@ if [ -z "${path:-}" ]; then ynh_app_setting_set --app=$app --key=path --value=$path fi +if [ -z "${password:-}" ]; then + password=$(ynh_string_random --length=32) + ynh_app_setting_set --app=$app --key=password --value="$password" +fi + # Support full Unicode in MySQL databases ynh_mysql_connect_as --user=$db_user --password="$db_pwd" --database=$db_name \ <<< "ALTER DATABASE $db_name CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci;" From fcc35f6e1a72f205f5940c41d6fd3505b37f8b6d Mon Sep 17 00:00:00 2001 From: Alexandre Aubin <4533074+alexAubin@users.noreply.github.com> Date: Mon, 11 Dec 2023 08:30:30 +0100 Subject: [PATCH 38/44] Update tests.toml: typo: libreoffice/abiword Co-authored-by: eric_G <46165813+ericgaspar@users.noreply.github.com> --- tests.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests.toml b/tests.toml index acca843..3d73345 100644 --- a/tests.toml +++ b/tests.toml @@ -27,7 +27,7 @@ test_format = 1.0 only = ["install.root"] [with_abiword] - args.export = "libreoffice" + args.export = "abiword" args.mypads = 0 args.useldap = 0 only = ["install.root"] From 3915c6336e8b775c46de62c80bb41d11895d6a6d Mon Sep 17 00:00:00 2001 From: Alexandre Aubin Date: Mon, 11 Dec 2023 09:12:01 +0100 Subject: [PATCH 39/44] Fix version number in manifest --- manifest.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/manifest.toml b/manifest.toml index 2cfbc3f..5a807cd 100644 --- a/manifest.toml +++ b/manifest.toml @@ -5,7 +5,7 @@ name = "Etherpad MyPads" description.en = "Online editor providing collaborative editing in real-time" description.fr = "Éditeur en ligne fournissant l'édition collaborative en temps réel" -version = "1.9.4~ynh1" +version = "1.9.1~ynh2" maintainers = [] From 89642cd165a7dad4a525cfeba157a7f46d9ad2c6 Mon Sep 17 00:00:00 2001 From: Alexandre Aubin Date: Mon, 11 Dec 2023 09:12:42 +0100 Subject: [PATCH 40/44] Regroup systemd-related stuff together --- scripts/install | 29 +++++++++-------------------- scripts/upgrade | 29 ++++++++++------------------- 2 files changed, 19 insertions(+), 39 deletions(-) diff --git a/scripts/install b/scripts/install index 99e7840..c239422 100644 --- a/scripts/install +++ b/scripts/install @@ -90,14 +90,6 @@ chown $app:$app "$install_dir/settings.json" chmod 600 "$install_dir/credentials.json" chown $app:$app "$install_dir/credentials.json" -#================================================= -# SETUP SYSTEMD -#================================================= -ynh_script_progression --message="Configuring a systemd service..." --weight=4 - -# Create a dedicated systemd config -ynh_add_systemd_config - #================================================= # INSTALL ETHERPAD'S PLUGINS #================================================= @@ -161,26 +153,23 @@ then fi #================================================= -# GENERIC FINALIZATION +# SETUP SYSTEMD #================================================= -# SETUP LOGROTATE -#================================================= -ynh_script_progression --message="Configuring log rotation..." --weight=1 +ynh_script_progression --message="Configuring systemd service..." --weight=4 + +# Create a dedicated systemd config +ynh_add_systemd_config + +# Intgrate in YunoHost +yunohost service add $app --description="Collaborative editor" --log="/var/log/$app/etherpad.log" # Use logrotate to manage application logfile(s) ynh_use_logrotate --specific_user=$app/$app -#================================================= -# INTEGRATE SERVICE IN YUNOHOST -#================================================= -ynh_script_progression --message="Integrating service in YunoHost..." --weight=2 - -yunohost service add $app --description="Collaborative editor" --log="/var/log/$app/etherpad.log" - #================================================= # START SYSTEMD SERVICE #================================================= -ynh_script_progression --message="Starting a systemd service..." --weight=20 +ynh_script_progression --message="Starting systemd service..." --weight=20 # Start a systemd service ynh_systemd_action --service_name=$app --action=restart --line_match="You can access your Etherpad instance at" --log_path="/var/log/$app/etherpad.log" --timeout="120" diff --git a/scripts/upgrade b/scripts/upgrade index 6a43c06..187bd76 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -139,16 +139,11 @@ chown $app:$app "$install_dir/settings.json" chmod 600 "$install_dir/credentials.json" chown $app:$app "$install_dir/credentials.json" -#================================================= -# SETUP SYSTEMD -#================================================= -ynh_script_progression --message="Upgrading systemd configuration..." --weight=2 - -ynh_add_systemd_config - #================================================= # INSTALL ETHERPAD'S PLUGINS #================================================= + + ynh_script_progression --message="Installing Etherpad plugins..." --weight=90 pushd "$install_dir" @@ -200,26 +195,22 @@ then fi #================================================= -# GENERIC FINALIZATION +# SETUP SYSTEMD #================================================= -# SETUP LOGROTATE -#================================================= -ynh_script_progression --message="Upgrading logrotate configuration..." --weight=2 +ynh_script_progression --message="Configuring systemd service..." --weight=2 + +ynh_add_systemd_config + +# Integrate in YunoHost +yunohost service add $app --description="Collaborative editor" --log="/var/log/$app/etherpad.log" # Use logrotate to manage app-specific logfile(s) ynh_use_logrotate --non-append --specific_user=$app/$app -#================================================= -# INTEGRATE SERVICE IN YUNOHOST -#================================================= -ynh_script_progression --message="Integrating service in YunoHost..." --weight=1 - -yunohost service add $app --description="Collaborative editor" --log="/var/log/$app/etherpad.log" - #================================================= # START SYSTEMD SERVICE #================================================= -ynh_script_progression --message="Starting a systemd service..." --weight=9 +ynh_script_progression --message="Starting systemd service..." --weight=9 ynh_systemd_action --service_name=$app --action=restart --line_match="You can access your Etherpad instance at" --log_path="/var/log/$app/etherpad.log" --timeout="120" From 1e67c5ed31bcbbc52bef214e29c55d9c746f5036 Mon Sep 17 00:00:00 2001 From: Alexandre Aubin Date: Mon, 11 Dec 2023 09:13:12 +0100 Subject: [PATCH 41/44] Add explicit removal of ep_table_of_contents when upgrading from a version older than 1.9.1~ynh2 --- scripts/upgrade | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/scripts/upgrade b/scripts/upgrade index 187bd76..d58741f 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -143,6 +143,14 @@ chown $app:$app "$install_dir/credentials.json" # INSTALL ETHERPAD'S PLUGINS #================================================= +# If upgrading from an old version and table of content is there, remove it +if ynh_compare_current_package_version --comparison lt --version 1.9.1~ynh2 + if ynh_exec_as $app env $ynh_node_load_PATH $ynh_npm ls 2>/dev/null | grep -q ep_table_of_contents + then + ynh_script_progression --message="Uninstalling ep_table_of_contents..." --weight=90 + ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH $ynh_npm uninstall ep_table_of_contents + fi +then ynh_script_progression --message="Installing Etherpad plugins..." --weight=90 From 7f95be86531928e1a08bee78986104812d109cb0 Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Mon, 11 Dec 2023 08:13:25 +0000 Subject: [PATCH 42/44] Auto-update README --- README.md | 2 +- README_fr.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 1b5993f..9ecb1e9 100644 --- a/README.md +++ b/README.md @@ -34,7 +34,7 @@ This version of Etherpad is preconfigured with a collection of plugins: - [ep_subscript_and_superscript](https://www.npmjs.com/package/ep_subscript_and_superscript) - *Support for subscript and superscript* -**Shipped version:** 1.9.4~ynh1 +**Shipped version:** 1.9.1~ynh2 **Demo:** https://video.etherpad.com diff --git a/README_fr.md b/README_fr.md index 3837642..4446326 100644 --- a/README_fr.md +++ b/README_fr.md @@ -34,7 +34,7 @@ Cette version d'Etherpad est préconfigurée avec une collection de plugins: - [ep_subscript_and_superscript](https://www.npmjs.com/package/ep_subscript_and_superscript) - *Support des exposants et indices* -**Version incluse :** 1.9.4~ynh1 +**Version incluse :** 1.9.1~ynh2 **Démo :** https://video.etherpad.com From ee28f61d873c580a3e411ba8664bda4b3074d3a2 Mon Sep 17 00:00:00 2001 From: Alexandre Aubin Date: Mon, 11 Dec 2023 11:27:31 +0100 Subject: [PATCH 43/44] Aaaand forgot to add a then after if :| --- scripts/upgrade | 1 + 1 file changed, 1 insertion(+) diff --git a/scripts/upgrade b/scripts/upgrade index d58741f..1f56e5e 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -145,6 +145,7 @@ chown $app:$app "$install_dir/credentials.json" # If upgrading from an old version and table of content is there, remove it if ynh_compare_current_package_version --comparison lt --version 1.9.1~ynh2 +then if ynh_exec_as $app env $ynh_node_load_PATH $ynh_npm ls 2>/dev/null | grep -q ep_table_of_contents then ynh_script_progression --message="Uninstalling ep_table_of_contents..." --weight=90 From d49c6f7b82852cf99473fae555960b96691b315e Mon Sep 17 00:00:00 2001 From: Alexandre Aubin Date: Mon, 11 Dec 2023 12:37:40 +0100 Subject: [PATCH 44/44] :| --- scripts/upgrade | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/upgrade b/scripts/upgrade index 1f56e5e..de234d8 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -151,7 +151,7 @@ then ynh_script_progression --message="Uninstalling ep_table_of_contents..." --weight=90 ynh_exec_warn_less ynh_exec_as $app env $ynh_node_load_PATH $ynh_npm uninstall ep_table_of_contents fi -then +fi ynh_script_progression --message="Installing Etherpad plugins..." --weight=90