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

No option for force upgrade to user

This commit is contained in:
Amo 2021-06-02 01:44:07 +05:30
parent c2bedff12c
commit 2d8707440d
4 changed files with 4 additions and 15 deletions

View file

@ -9,7 +9,6 @@
admin="john" (USER) admin="john" (USER)
registration=1 registration=1
is_public=1 (PUBLIC|public=1|private=0) is_public=1 (PUBLIC|public=1|private=0)
update=0
; Checks ; Checks
pkg_linter=1 pkg_linter=1
setup_sub_dir=0 setup_sub_dir=0

View file

@ -68,16 +68,6 @@
"cs": "Mohou se noví uživatelé registrovat?" "cs": "Mohou se noví uživatelé registrovat?"
}, },
"default": false "default": false
}, } ]
{
"name": "update",
"type": "boolean",
"ask":{
"en": "Making this option to true will give you an option to force upgrade to new version without the package being updated to that version. WARNING: This can be risky and break your app if specific version have additional steps than noraml upgrade. Keep the option false, if you are not sure."
},
"default": false
}
]
} }
} }

View file

@ -31,7 +31,7 @@ is_public=$YNH_APP_ARG_IS_PUBLIC
registration=$YNH_APP_ARG_REGISTRATION registration=$YNH_APP_ARG_REGISTRATION
random_key=$(ynh_string_random 32) random_key=$(ynh_string_random 32)
app=$YNH_APP_INSTANCE_NAME app=$YNH_APP_INSTANCE_NAME
update=$YNH_APP_ARG_UPDATE update=0
#================================================= #=================================================
# CHECK IF THE APP CAN BE INSTALLED WITH THESE ARGS # CHECK IF THE APP CAN BE INSTALLED WITH THESE ARGS

View file

@ -79,10 +79,10 @@ then
pushd "$final_path" pushd "$final_path"
if [ $update -eq 1 ] if [ $update -eq 1 ]
then then
git fetch --tags git fetch origin tag $latest_tag --no-tags
git checkout $latest_tag git checkout $latest_tag
else else
git fetch --tags git fetch origin tag $tag --no-tags
git checkout $tag git checkout $tag
fi fi
popd popd