moved an init.sh function to newly created utils.sh
This commit is contained in:
8
init.sh
8
init.sh
@@ -31,7 +31,7 @@ set -o errexit
|
||||
# to be complete (even if it's bad practice)
|
||||
set +o nounset
|
||||
|
||||
# We want english messages
|
||||
# We want english messages, all the time (can be redefined in configuration)
|
||||
export LC_ALL=C
|
||||
export LANG=C
|
||||
|
||||
@@ -54,12 +54,6 @@ unset lib
|
||||
# ==== Basic sanity checks ====
|
||||
# =============================
|
||||
|
||||
# Check if a function exists, return 0 if so
|
||||
function_exists() {
|
||||
declare -f -F $1 > /dev/null
|
||||
return $?
|
||||
}
|
||||
|
||||
function_exists prnt || (
|
||||
echo "*** ERREUR FATALE !"
|
||||
echo "*** Il manque des fonctions vitales venant des bibliothèques."
|
||||
|
||||
Reference in New Issue
Block a user