1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/mattermost_ynh.git synced 2024-09-03 19:36:29 +02:00

Remove ynh_detect_arch helper

ynh_detect_arch is deprecated in favor of YNH_ARCH
This commit is contained in:
ericgaspar 2021-12-03 23:16:00 +01:00
parent e86192b7a6
commit 61508a475c
No known key found for this signature in database
GPG key ID: 574F281483054D44
5 changed files with 2 additions and 28 deletions

View file

@ -12,32 +12,6 @@
# EXPERIMENTAL HELPERS # EXPERIMENTAL HELPERS
#================================================= #=================================================
# Check the architecture
#
# example: architecture=$(ynh_detect_arch)
#
# usage: ynh_detect_arch
#
# Requires YunoHost version 2.2.4 or higher.
ynh_detect_arch(){
local architecture
if [ -n "$(uname -m | grep arm64)" ] || [ -n "$(uname -m | grep aarch64)" ]; then
architecture="arm64"
elif [ -n "$(uname -m | grep 64)" ]; then
architecture="x86-64"
elif [ -n "$(uname -m | grep armv7)" ]; then
architecture="arm"
elif [ -n "$(uname -m | grep armv6)" ]; then
architecture="arm"
elif [ -n "$(uname -m | grep armv5)" ]; then
architecture="arm"
else
architecture="unknown"
fi
echo $architecture
}
#================================================= #=================================================
# FUTURE OFFICIAL HELPERS # FUTURE OFFICIAL HELPERS
#================================================= #=================================================

View file

@ -31,7 +31,7 @@ email=$(ynh_user_get_info --username=$admin --key=mail)
password=$YNH_APP_ARG_PASSWORD password=$YNH_APP_ARG_PASSWORD
language=$YNH_APP_ARG_LANGUAGE language=$YNH_APP_ARG_LANGUAGE
team_display_name=$YNH_APP_ARG_TEAM_DISPLAY_NAME team_display_name=$YNH_APP_ARG_TEAM_DISPLAY_NAME
architecture=$(ynh_detect_arch) architecture=$YNH_ARCH
version=$YNH_APP_ARG_VERSION version=$YNH_APP_ARG_VERSION
app=$YNH_APP_INSTANCE_NAME app=$YNH_APP_INSTANCE_NAME

View file

@ -32,7 +32,7 @@ port=$(ynh_app_setting_get --app=$app --key=port)
final_path=$(ynh_app_setting_get --app=$app --key=final_path) final_path=$(ynh_app_setting_get --app=$app --key=final_path)
language=$(ynh_app_setting_get --app=$app --key=language) language=$(ynh_app_setting_get --app=$app --key=language)
db_name=$(ynh_app_setting_get --app=$app --key=db_name) db_name=$(ynh_app_setting_get --app=$app --key=db_name)
architecture=$(ynh_detect_arch) architecture=$YNH_ARCH
version=$(ynh_app_setting_get --app=$app --key=version) version=$(ynh_app_setting_get --app=$app --key=version)
data_path=$(ynh_app_setting_get --app=$app --key=data_path) data_path=$(ynh_app_setting_get --app=$app --key=data_path)