summaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
Diffstat (limited to 'bin')
-rwxr-xr-xbin/clone_formulas.sh12
1 files changed, 12 insertions, 0 deletions
diff --git a/bin/clone_formulas.sh b/bin/clone_formulas.sh
new file mode 100755
index 0000000..e6f9e56
--- /dev/null
+++ b/bin/clone_formulas.sh
@@ -0,0 +1,12 @@
+#!/bin/sh
+set -Ceu
+
+FORMULASDIR='/srv/formulas'
+
+if [ ! -d "$FORMULASDIR" ]
+then
+ git clone --recurse-submodules --single-branch -b production https://git.com.de/LibertaCasa/salt-formulas.git "$FORMULASDIR"
+ exit "$?"
+fi
+
+git -C "$FORMULASDIR" pull --recurse-submodules