diff --git a/README.md b/README.md index ca9bd7d..2f5cc79 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,8 @@ It shall NOT be edited by hand. # Libreto for YunoHost -[![Integration level](https://dash.yunohost.org/integration/libreto.svg)](https://dash.yunohost.org/appci/app/libreto) ![Working status](https://ci-apps.yunohost.org/ci/badges/libreto.status.svg) ![Maintenance status](https://ci-apps.yunohost.org/ci/badges/libreto.maintain.svg) +[![Integration level](https://dash.yunohost.org/integration/libreto.svg)](https://dash.yunohost.org/appci/app/libreto) ![Working status](https://ci-apps.yunohost.org/ci/badges/libreto.status.svg) ![Maintenance status](https://ci-apps.yunohost.org/ci/badges/libreto.maintain.svg) + [![Install Libreto with YunoHost](https://install-app.yunohost.org/install-with-yunohost.svg)](https://install-app.yunohost.org/?app=libreto) *[Lire ce readme en français.](./README_fr.md)* diff --git a/README_fr.md b/README_fr.md index c0cb369..629801d 100644 --- a/README_fr.md +++ b/README_fr.md @@ -5,15 +5,16 @@ It shall NOT be edited by hand. # Libreto pour YunoHost -[![Niveau d'intégration](https://dash.yunohost.org/integration/libreto.svg)](https://dash.yunohost.org/appci/app/libreto) ![Statut du fonctionnement](https://ci-apps.yunohost.org/ci/badges/libreto.status.svg) ![Statut de maintenance](https://ci-apps.yunohost.org/ci/badges/libreto.maintain.svg) +[![Niveau d’intégration](https://dash.yunohost.org/integration/libreto.svg)](https://dash.yunohost.org/appci/app/libreto) ![Statut du fonctionnement](https://ci-apps.yunohost.org/ci/badges/libreto.status.svg) ![Statut de maintenance](https://ci-apps.yunohost.org/ci/badges/libreto.maintain.svg) + [![Installer Libreto avec YunoHost](https://install-app.yunohost.org/install-with-yunohost.svg)](https://install-app.yunohost.org/?app=libreto) *[Read this readme in english.](./README.md)* -> *Ce package vous permet d'installer Libreto rapidement et simplement sur un serveur YunoHost. -Si vous n'avez pas YunoHost, regardez [ici](https://yunohost.org/#/install) pour savoir comment l'installer et en profiter.* +> *Ce package vous permet d’installer Libreto rapidement et simplement sur un serveur YunoHost. +Si vous n’avez pas YunoHost, regardez [ici](https://yunohost.org/#/install) pour savoir comment l’installer et en profiter.* -## Vue d'ensemble +## Vue d’ensemble Libreto est un carnet de note collaboratif fondé sur etherpad. Il peut devenir un mini-site, le carnet de bord d'un workshop ou le support de rédaction d'un livre collectif. @@ -22,15 +23,15 @@ Libreto est un carnet de note collaboratif fondé sur etherpad. Il peut devenir **Démo :** https://libreto.net -## Captures d'écran +## Captures d’écran -![Capture d'écran de Libreto](./doc/screenshots/home.png) -![Capture d'écran de Libreto](./doc/screenshots/menu.png) +![Capture d’écran de Libreto](./doc/screenshots/home.png) +![Capture d’écran de Libreto](./doc/screenshots/menu.png) ## Documentations et ressources -* Site officiel de l'app : -* Dépôt de code officiel de l'app : +* Site officiel de l’app : +* Dépôt de code officiel de l’app : * Documentation YunoHost pour cette app : * Signaler un bug : @@ -46,4 +47,4 @@ ou sudo yunohost app upgrade libreto -u https://github.com/YunoHost-Apps/libreto_ynh/tree/testing --debug ``` -**Plus d'infos sur le packaging d'applications :** +**Plus d’infos sur le packaging d’applications :** \ No newline at end of file diff --git a/scripts/install b/scripts/install index 99b7e75..7550dd0 100755 --- a/scripts/install +++ b/scripts/install @@ -68,12 +68,15 @@ ynh_system_user_create --username=$app --home_dir="$final_path" ynh_script_progression --message="Setting up source files..." --weight=4 ynh_app_setting_set --app=$app --key=final_path --value=$final_path + # Note: We use git instead of ynh_setup_source, cause this repo use submodules git clone https://github.com/zamentur/libreto.git "$final_path" --quiet +chown -R $app:www-data "$final_path" + pushd "$final_path" - git checkout $COMMIT --quiet - git submodule update --init --recursive --quiet + ynh_exec_as $app git checkout $COMMIT --quiet + ynh_exec_as $app git submodule update --init --recursive --quiet popd chmod 750 "$final_path" diff --git a/scripts/upgrade b/scripts/upgrade index 336e383..e3a8997 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -75,12 +75,14 @@ if [ "$upgrade_type" == "UPGRADE_APP" ] then ynh_script_progression --message="Upgrading source files..." --weight=5 + chown -R $app:www-data "$final_path" + # Download, check integrity, uncompress and patch the source from app.src pushd "$final_path" - git checkout master - git pull --quiet - git checkout $COMMIT --quiet - git submodule update --init --recursive --quiet + ynh_exec_as $app git checkout master + ynh_exec_as $app git pull --quiet + ynh_exec_as $app git checkout $COMMIT --quiet + ynh_exec_as $app git submodule update --init --recursive --quiet popd fi