mirror of
https://github.com/YunoHost-Apps/ttrss_ynh.git
synced 2024-10-01 13:34:46 +02:00
[fix] Source helpers.
This commit is contained in:
parent
1bff97c8e6
commit
375f1653c7
1 changed files with 13 additions and 4 deletions
|
@ -3,11 +3,20 @@
|
||||||
# causes the shell to exit if any subcommand or pipeline returns a non-zero status
|
# causes the shell to exit if any subcommand or pipeline returns a non-zero status
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
# The parameter $1 is the backup directory location dedicated to the app
|
# Source YNH helpers
|
||||||
backup_dir=$1
|
. /usr/share/yunohost/helpers
|
||||||
|
|
||||||
# The last parameter is the id of the app instance
|
# This is a multi-instance app, meaning it can be installed several times independently
|
||||||
app=${!#}
|
# The id of the app as stated in the manifest is available as $YNH_APP_ID
|
||||||
|
# The instance number is available as $YNH_APP_INSTANCE_NUMBER (equals "1", "2", ...)
|
||||||
|
# The app instance name is available as $YNH_APP_INSTANCE_NAME
|
||||||
|
# - the first time the app is installed, YNH_APP_INSTANCE_NAME = ynhexample
|
||||||
|
# - the second time the app is installed, YNH_APP_INSTANCE_NAME = ynhexample__2
|
||||||
|
# - ynhexample__{N} for the subsequent installations, with N=3,4, ...
|
||||||
|
# The app instance name is probably what you are interested the most, since this is
|
||||||
|
# guaranteed to be unique. This is a good unique identifier to define installation path,
|
||||||
|
# db names, ...
|
||||||
|
app=$YNH_APP_INSTANCE_NAME
|
||||||
|
|
||||||
domain=$(sudo yunohost app setting $app domain)
|
domain=$(sudo yunohost app setting $app domain)
|
||||||
path=$(sudo yunohost app setting $app path)
|
path=$(sudo yunohost app setting $app path)
|
||||||
|
|
Loading…
Add table
Reference in a new issue