1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/pixelfed_ynh.git synced 2024-09-03 20:06:04 +02:00

add language

This commit is contained in:
ericgaspar 2022-03-18 09:37:18 +01:00
parent 3ec2b9f63d
commit 4452e74697
No known key found for this signature in database
GPG key ID: 574F281483054D44
3 changed files with 13 additions and 1 deletions

View file

@ -16,7 +16,7 @@ PF_MAX_USERS=1000
OAUTH_ENABLED=true OAUTH_ENABLED=true
APP_TIMEZONE=UTC APP_TIMEZONE=UTC
APP_LOCALE=en APP_LOCALE=__LANGUAGE__
## Pixelfed Tweaks ## Pixelfed Tweaks
LIMIT_ACCOUNT_SIZE=true LIMIT_ACCOUNT_SIZE=true

View file

@ -46,6 +46,16 @@
"name": "is_public", "name": "is_public",
"type": "boolean", "type": "boolean",
"default": true "default": true
},
{
"name": "language",
"type": "string",
"ask": {
"en": "Choose the application language",
"fr": "Choisissez la langue de l'application"
},
"choices": ["fr", "en"],
"default": "fr"
} }
] ]
} }

View file

@ -29,6 +29,7 @@ domain=$YNH_APP_ARG_DOMAIN
path_url="/" path_url="/"
is_public=$YNH_APP_ARG_IS_PUBLIC is_public=$YNH_APP_ARG_IS_PUBLIC
app_key="base64:$(ynh_string_random --length=32 | base64)" app_key="base64:$(ynh_string_random --length=32 | base64)"
language=$YNH_APP_ARG_LANGUAGE
app=$YNH_APP_INSTANCE_NAME app=$YNH_APP_INSTANCE_NAME
@ -51,6 +52,7 @@ ynh_script_progression --message="Storing installation settings..."
ynh_app_setting_set --app=$app --key=domain --value=$domain ynh_app_setting_set --app=$app --key=domain --value=$domain
ynh_app_setting_set --app=$app --key=path --value=$path_url ynh_app_setting_set --app=$app --key=path --value=$path_url
ynh_app_setting_set --app=$app --key=app_key --value=$app_key ynh_app_setting_set --app=$app --key=app_key --value=$app_key
ynh_app_setting_set --app=$app --key=language --value=$language
#================================================= #=================================================
# STANDARD MODIFICATIONS # STANDARD MODIFICATIONS