summaryrefslogtreecommitdiff
path: root/utils/lib.sh
diff options
context:
space:
mode:
authorMarkus Heiser <markus.heiser@darmarit.de>2020-02-26 19:07:55 +0100
committerMarkus Heiser <markus.heiser@darmarit.de>2020-02-26 19:07:55 +0100
commitaf6acd3417bf53c151b9ba6068186c1e472a2776 (patch)
treeee77e2c18fec10fe71df1494743fda7f586f6bff /utils/lib.sh
parentd5917cc029e2736b11412a570470c666af093ec9 (diff)
downloadsearxng-af6acd3417bf53c151b9ba6068186c1e472a2776.tar.gz
searxng-af6acd3417bf53c151b9ba6068186c1e472a2776.zip
LXC: install searx-suite installs searx, filtron & morty on all containers
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
Diffstat (limited to 'utils/lib.sh')
-rwxr-xr-xutils/lib.sh9
1 files changed, 9 insertions, 0 deletions
diff --git a/utils/lib.sh b/utils/lib.sh
index 39b9134d0..aeb38e150 100755
--- a/utils/lib.sh
+++ b/utils/lib.sh
@@ -290,6 +290,15 @@ cache_download() {
fi
}
+backup_file() {
+
+ # usage: backup_file /path/to/file.foo
+
+ local stamp=$(date +"_%Y%m%d_%H%M%S")
+ info_msg "create backup: ${1}${stamp}"
+ cp -a "${1}" "${1}${stamp}"
+}
+
choose_one() {
# usage: