Quellcode durchsuchen

Re-added fn_update_functions

To allow users to delete legacy functions
Daniel Gibbs vor 10 Jahren
Ursprung
Commit
750d67db1a
1 geänderte Dateien mit 22 neuen und 0 gelöschten Zeilen
  1. 22 0
      functions/fn_update_functions

+ 22 - 0
functions/fn_update_functions

@@ -0,0 +1,22 @@
+#!/bin/bash
+# LGSM update_functions.sh function
+# Author: Daniel Gibbs
+# Website: http://gameservermanagers.com
+lgsm_version="271215"
+
+# Description: LEGACY FUNCTION Deletes the functions dir to allow re-downloading of functions from GitHub.
+
+fn_printdots "Updating functions"
+fn_scriptlog "Updating functions"
+sleep 1
+echo -ne "\n"
+rm -rfv "${rootdir}/functions/"*
+exitcode=$?
+if [ "${exitcode}" == "0" ]; then
+	fn_printok "Updating functions"
+	fn_scriptlog "Successfull! Updating functions"
+else
+	fn_printokfail "Updating functions"
+	fn_scriptlog "Failure! Updating functions"
+fi
+echo -ne "\n"