mirror of
https://github.com/YunoHost-Apps/minidlna_ynh.git
synced 2024-09-03 19:36:34 +02:00
Remove 2.2 compatibility
This commit is contained in:
parent
5e5af5f725
commit
fa12706ce1
5 changed files with 14 additions and 32 deletions
|
@ -2,11 +2,8 @@
|
|||
|
||||
# Récupère les infos de l'application.
|
||||
ynh_version=$(sudo yunohost -v | grep "moulinette:" | cut -d' ' -f2 | cut -d'.' -f1,2) # Récupère le numéro de version de Yunohost.
|
||||
if [ $ynh_version = "2.4" ]; then
|
||||
app=$YNH_APP_INSTANCE_NAME
|
||||
else
|
||||
app=minidlna
|
||||
fi
|
||||
app=$YNH_APP_INSTANCE_NAME
|
||||
|
||||
version=$(sudo yunohost app setting $app version)
|
||||
port=$(sudo yunohost app setting $app port)
|
||||
|
||||
|
|
|
@ -12,18 +12,12 @@ CLEAN_SETUP () {
|
|||
TRAP_ON # Active trap pour arrêter le script si une erreur est détectée.
|
||||
|
||||
# Retrieve arguments
|
||||
if [ $ynh_version = "2.4" ]
|
||||
then
|
||||
version=$YNH_APP_ARG_VERSION
|
||||
version=$YNH_APP_ARG_VERSION
|
||||
|
||||
app=$YNH_APP_INSTANCE_NAME
|
||||
app=$YNH_APP_INSTANCE_NAME
|
||||
|
||||
# Source app helpers
|
||||
source /usr/share/yunohost/helpers
|
||||
else
|
||||
version=$1
|
||||
app=minidlna
|
||||
fi
|
||||
# Source app helpers
|
||||
source /usr/share/yunohost/helpers
|
||||
|
||||
# Vérifie que les variables ne sont pas vides.
|
||||
CHECK_VAR "$app" "app name not set"
|
||||
|
|
|
@ -4,14 +4,11 @@ source .fonctions # Charge les fonctions génériques habituellement utilisées
|
|||
|
||||
# Récupère les infos de l'application.
|
||||
YNH_VERSION # Récupère le numéro de version de Yunohost.
|
||||
if [ $ynh_version = "2.4" ]; then
|
||||
app=$YNH_APP_INSTANCE_NAME
|
||||
app=$YNH_APP_INSTANCE_NAME
|
||||
|
||||
# Source app helpers
|
||||
source /usr/share/yunohost/helpers
|
||||
|
||||
# Source app helpers
|
||||
source /usr/share/yunohost/helpers
|
||||
else
|
||||
app=minidlna
|
||||
fi
|
||||
port=$(sudo yunohost app setting $app port)
|
||||
|
||||
# Ferme les ports dans le firewall
|
||||
|
|
|
@ -2,11 +2,8 @@
|
|||
|
||||
# Récupère les infos de l'application.
|
||||
ynh_version=$(sudo yunohost -v | grep "moulinette:" | cut -d' ' -f2 | cut -d'.' -f1,2) # Récupère le numéro de version de Yunohost.
|
||||
if [ $ynh_version = "2.4" ]; then
|
||||
app=$YNH_APP_INSTANCE_NAME
|
||||
else
|
||||
app=minidlna
|
||||
fi
|
||||
app=$YNH_APP_INSTANCE_NAME
|
||||
|
||||
version=$(sudo yunohost app setting $app version)
|
||||
port=$(sudo yunohost app setting $app port)
|
||||
|
||||
|
|
|
@ -4,11 +4,8 @@ source .fonctions # Charge les fonctions génériques habituellement utilisées
|
|||
|
||||
# Récupère les infos de l'application.
|
||||
YNH_VERSION # Récupère le numéro de version de Yunohost.
|
||||
if [ $ynh_version = "2.4" ]; then
|
||||
app=$YNH_APP_INSTANCE_NAME
|
||||
else
|
||||
app=minidlna
|
||||
fi
|
||||
app=$YNH_APP_INSTANCE_NAME
|
||||
|
||||
version=$(sudo yunohost app setting $app version)
|
||||
port=$(sudo yunohost app setting $app port)
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue