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

Update _common.sh

- Remove unused script that generates an error
- Remove openssl that is part of PHP as default
This commit is contained in:
ericgaspar 2020-11-11 14:02:45 +01:00
parent dd3251ebb9
commit 0999a92d53
No known key found for this signature in database
GPG key ID: 574F281483054D44

View file

@ -8,11 +8,10 @@
YNH_PHP_VERSION="7.3"
# dependencies used by the app
pkg_dependencies="openssl"
pkg_dependencies=""
extra_php_dependencies="php${YNH_PHP_VERSION}-cli php${YNH_PHP_VERSION}-gettext php${YNH_PHP_VERSION}-curl php${YNH_PHP_VERSION}-intl php${YNH_PHP_VERSION}-gd php${YNH_PHP_VERSION}-mbstring"
#=================================================
# PERSONAL HELPERS
#=================================================
@ -24,23 +23,3 @@ extra_php_dependencies="php${YNH_PHP_VERSION}-cli php${YNH_PHP_VERSION}-gettext
#=================================================
# FUTURE OFFICIAL HELPERS
#=================================================
# Check if there's enough free space in a directory
is_there_enough_space () {
local free_space=$(df --output=avail "$1" | sed 1d)
test $free_space -ge $min_size
}
if is_there_enough_space /tmp; then
local tmpdir=/tmp
elif is_there_enough_space /var; then
local tmpdir=/var
elif is_there_enough_space /; then
local tmpdir=/
elif is_there_enough_space /home; then
local tmpdir=/home
else
ynh_die "Insufficient free space to continue..."
fi
echo "$(mktemp --directory --tmpdir="$tmpdir")"
}