summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authortv <tv@xso>2011-09-06 21:28:50 +0200
committertv <tv@xso>2011-09-06 21:28:50 +0200
commit6cac66363039097f0ee89db1f15e9c91ff698bab (patch)
treee7e0892b24288f27d4c025c631529e647399a890
parented7dce49a177d622858e8eb0a09576c88b0412a1 (diff)
//meta/bin/update: initial commit
-rwxr-xr-xmeta/bin/update12
1 files changed, 12 insertions, 0 deletions
diff --git a/meta/bin/update b/meta/bin/update
new file mode 100755
index 00000000..98a69257
--- /dev/null
+++ b/meta/bin/update
@@ -0,0 +1,12 @@
+#! /bin/sh
+set -euf
+
+if test "${nosudo-false}" != true -a `id -u` != 0; then
+ echo "we're going sudo..." >&2
+ exec sudo "$0" "$@"
+ exit 23 # go to hell
+fi
+
+set -x
+cd $(dirname $(readlink -f $0))`
+git pull