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

Merge pull request #8 from YunoHost-Apps/fix-linter

Fix linter warnings
This commit is contained in:
farvardin 2021-03-21 17:52:05 +01:00 committed by GitHub
commit dfbfa37904
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 20 additions and 44 deletions

View file

@ -12,6 +12,8 @@ If you don't have YunoHost, please see [here](https://yunohost.org/#/install) to
LionWiki-t2t is a minimalist Wiki engine programmed in PHP. It is extensible, templatable, file based (it doesn't need database like MySQL) and requires just one file to function (30 kb). It is suitable for small websites, personal notebooks or journals. This version is using the lightweight markup language TXT2TAGS.
**Shipped version:** 3.2.11b
## Screenshot
![](screenshot_lionwikit2t.png)

View file

@ -12,6 +12,8 @@ Si vous n'avez pas YunoHost, regardez [ici](https://yunohost.org/#/install) pour
Lionwiki-t2t est un système de type wiki minimaliste, programmé en PHP. Il est extensible et n'utilise que des fichiers plats pour sa base de données. Il est adapté pour la création de petits sites web, de notes personnelles ou de journaux. Cette version utilise le langage de balisage léger TXT2TAGS.
**Version incluse :** 3.2.11b
## Capture d'écran
![](screenshot_lionwikit2t.png)

View file

@ -17,7 +17,7 @@
setup_private=1
setup_public=1
upgrade=1
upgrade=1 from_commit=fde26800233eb9d312ef2885d747555c79ee779b
upgrade=1 from_commit=69db9a386081d9241f5548e09052fd58dee45463
backup_restore=1
multi_instance=1
port_already_use=0
@ -26,6 +26,6 @@
Email=
Notification=none
;;; Upgrade options
; commit=fde26800233eb9d312ef2885d747555c79ee779b
name=updating to latest lionwiki-t2t release
; commit=69db9a386081d9241f5548e09052fd58dee45463
name=Merge pull request #4 from YunoHost-Apps/testing
manifest_arg=domain=DOMAIN&path=PATH&admin=USER&is_public=Yes&language=en&

View file

@ -6,57 +6,41 @@
"en": "Lightweight wiki-style CMS using the txt2tags syntax",
"fr": "CMS léger, géré sous forme de wiki utilisant la syntaxe txt2tags"
},
"version": "3.2.11b~ynh6",
"version": "3.2.11~ynh6",
"url": "https://lionwiki-t2t.sourceforge.io/",
"license": "MIT",
"maintainer": {
"name": "Eric Forgeot"
},
"requirements": {
"yunohost": ">= 3.8.1"
"yunohost": ">= 4.1.7"
},
"multi_instance": true,
"services": [
"nginx",
"php7.0-fpm"
"php7.3-fpm"
],
"arguments": {
"install" : [
{
"name": "domain",
"type": "domain",
"ask": {
"en": "Choose a domain name for Lionwiki",
"fr": "Choisissez un nom de domaine pour Lionwiki"
},
"example": "domain.org"
},
{
"name": "path",
"type": "path",
"ask": {
"en": "Choose a path for Lionwiki",
"fr": "Choisissez un chemin pour Lionwiki"
},
"example": "/lionwiki",
"default": "/lionwiki"
},
{
"name": "admin",
"type": "user",
"ask": {
"en": "Choose an admin user",
"fr": "Choisissez l'administrateur"
},
"example": "johndoe"
},
{
"name": "is_public",
"type": "boolean",
"ask": {
"en": "Is it a public application?",
"fr": "Est-ce une application publique ?"
},
"help": {
"en": "If it's not public, only SSO registered users will be able to user it.",
"fr": "Si ce n'est pas public, seuls les utilisateurs enregistrés sur le SSO pourront l'utiliser."
@ -76,10 +60,6 @@
{
"name": "password",
"type": "password",
"ask": {
"en": "Set the password for edition",
"fr": "Définissez le mot de passe pour l'édition"
},
"help": {
"en": "Define a password which will be used for wiki edition and administration.",
"fr": "Veuillez définir un mot de passe qui sera valable pour l'édition des pages de ce wiki ainsi que pour l'administration."

View file

@ -13,6 +13,4 @@
## Package_check results
---
*If you have access to [App Continuous Integration for packagers](https://yunohost.org/#/packaging_apps_ci) you can provide a link to the package_check results like below, replacing '-NUM-' in this link by the PR number and USERNAME by your username on the ci-apps-dev. Or you provide a screenshot or a pastebin of the results*
[![Build Status](https://ci-apps-dev.yunohost.org/jenkins/job/lionwiki-t2t_ynh%20PR-NUM-%20(USERNAME)/badge/icon)](https://ci-apps-dev.yunohost.org/jenkins/job/lionwiki-t2t_ynh%20PR-NUM-%20(USERNAME)/)
* An automatic package_check will be launch at https://ci-apps-dev.yunohost.org/, when you add a specific comment to your Pull Request: "!testme", "!gogogadgetoci" or "By the power of systemd, I invoke The Great App CI to test this Pull Request!"*

View file

@ -54,7 +54,6 @@ ynh_script_progression --message="Storing installation settings..." --weight=1
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=admin --value=$admin
ynh_app_setting_set --app=$app --key=is_public --value=$is_public
ynh_app_setting_set --app=$app --key=language --value=$language
#=================================================
@ -203,14 +202,12 @@ find $final_path/templates/minimaxing/minimaxing.css -type f -print0 | xargs -0
#=================================================
# SETUP SSOWAT
#=================================================
ynh_script_progression --message="Configuring SSOwat..." --weight=1
ynh_script_progression --message="Configuring permissions..." --weight=1
# Make app public if necessary or protect it
if [ $is_public -eq 1 ]
then
# Everyone can access the app.
# The "main" permission is automatically created before the install script.
ynh_permission_update --permission "main" --add "visitors"
ynh_permission_update --permission="main" --add="visitors"
fi
#=================================================

View file

@ -19,7 +19,6 @@ app=$YNH_APP_INSTANCE_NAME
domain=$(ynh_app_setting_get --app=$app --key=domain)
path_url=$(ynh_app_setting_get --app=$app --key=path)
admin=$(ynh_app_setting_get --app=$app --key=admin)
is_public=$(ynh_app_setting_get --app=$app --key=is_public)
final_path=$(ynh_app_setting_get --app=$app --key=final_path)
language=$(ynh_app_setting_get --app=$app --key=language)
phpversion=$(ynh_app_setting_get --app=$app --key=phpversion)
@ -35,21 +34,19 @@ upgrade_type=$(ynh_check_app_version_changed)
#=================================================
ynh_script_progression --message="Ensuring downward compatibility..." --weight=1
# Fix is_public as a boolean value
if [ "$is_public" = "Yes" ]; then
ynh_app_setting_set --app=$app --key=is_public --value=1
is_public=1
elif [ "$is_public" = "No" ]; then
ynh_app_setting_set --app=$app --key=is_public --value=0
is_public=0
fi
# If final_path doesn't exist, create it
if [ -z "$final_path" ]; then
final_path=/var/www/$app
ynh_app_setting_set --app=$app --key=final_path --value=$final_path
fi
# Cleaning legacy permissions
if ynh_legacy_permissions_exists; then
ynh_legacy_permissions_delete_all
ynh_app_setting_delete --app=$app --key=is_public
fi
#=================================================
# BACKUP BEFORE UPGRADE THEN ACTIVE TRAP
#=================================================