From 677999232b8b7f0bede2831b4073f2c6b5f1abc1 Mon Sep 17 00:00:00 2001 From: yalh76 Date: Thu, 14 Mar 2019 01:10:25 +0100 Subject: [PATCH] Apply last example_ynh --- pull_request_template.md | 23 +++++++++++++++++++++++ scripts/_common.sh | 7 +++++++ scripts/install | 2 +- scripts/restore | 2 +- scripts/upgrade | 4 +++- 5 files changed, 35 insertions(+), 3 deletions(-) create mode 100644 pull_request_template.md diff --git a/pull_request_template.md b/pull_request_template.md new file mode 100644 index 0000000..4f6a1d4 --- /dev/null +++ b/pull_request_template.md @@ -0,0 +1,23 @@ +## Problem +- *Description of why you made this PR* + +## Solution +- *And how do you fix that problem* + +## PR Status +- [ ] Code finished. +- [ ] Tested with Package_check. +- [ ] Fix or enhancement tested. +- [ ] Upgrade from last version tested. +- [ ] Can be reviewed and tested. + +## Validation +--- +- [ ] **Code review** +- [ ] **Approval (LGTM)** +*Code review and approval have to be from a member of @YunoHost/apps group* +- **CI succeeded** : +[![Build Status](https://ci-apps-hq.yunohost.org/jenkins/job/APP_ynh%20-BRANCH-/badge/icon)](https://ci-apps-hq.yunohost.org/jenkins/job/APP_ynh%20-BRANCH-/) +*Please replace '-BRANCH-' in this link by the name of the branch used.* +*If the PR is from a forked repository. Please provide public results from package_check.* +When the PR is marked as ready to merge, you have to wait for 3 days before really merging it. diff --git a/scripts/_common.sh b/scripts/_common.sh index b905339..7427ffb 100755 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -1,5 +1,12 @@ #!/bin/bash +#================================================= +# COMMON VARIABLES +#================================================= + +# dependencies used by the app +pkg_dependencies="git build-essential openssl ssh sudo postgresql postgresql-contrib elixir erlang-dev erlang-parsetools erlang-xmerl erlang-tools" + #================================================= # PERSONAL HELPERS #================================================= diff --git a/scripts/install b/scripts/install index 253589d..dc4bc65 100755 --- a/scripts/install +++ b/scripts/install @@ -132,7 +132,7 @@ ynh_print_info "Installing dependencies ..." ### - As well as the section "REINSTALL DEPENDENCIES" in the restore script ### - And the section "UPGRADE DEPENDENCIES" in the upgrade script -ynh_install_app_dependencies git build-essential openssl ssh sudo postgresql postgresql-contrib elixir erlang-dev erlang-parsetools erlang-xmerl erlang-tools +ynh_install_app_dependencies $pkg_dependencies #================================================= # CREATE A POSTGRESQL DATABASE diff --git a/scripts/restore b/scripts/restore index 55909ad..97a8b4e 100755 --- a/scripts/restore +++ b/scripts/restore @@ -109,7 +109,7 @@ fi ynh_print_info "Reinstalling dependencies..." # Define and install dependencies -ynh_install_app_dependencies git build-essential openssl ssh sudo postgresql postgresql-contrib elixir erlang-dev erlang-parsetools erlang-xmerl erlang-tools +ynh_install_app_dependencies $pkg_dependencies #================================================= # RESTORE THE POSTGRESQL DATABASE diff --git a/scripts/upgrade b/scripts/upgrade index fcdc0c6..62f883e 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -109,6 +109,8 @@ path_url=$(ynh_normalize_url_path $path_url) ynh_print_info "Upgrading source files..." # Download, check integrity, uncompress and patch the source from app.src +#ynh_setup_source "$final_path" + git clone --quiet https://git.pleroma.social/pleroma/pleroma "$final_path/upgrade" pushd "$final_path/upgrade" git checkout -b master @@ -157,7 +159,7 @@ fi ynh_print_info "Upgrading dependencies..." # install dependencies -ynh_install_app_dependencies git build-essential openssl ssh sudo postgresql postgresql-contrib elixir erlang-dev erlang-parsetools erlang-xmerl erlang-tools +ynh_install_app_dependencies $pkg_dependencies #================================================= # CREATE DEDICATED USER