diff options
author | makefu <github@syntax-fehler.de> | 2013-11-05 23:40:11 +0100 |
---|---|---|
committer | makefu <github@syntax-fehler.de> | 2013-11-05 23:40:11 +0100 |
commit | 940d07624c6b82d5e7ec790c2ef49b4694a48794 (patch) | |
tree | 3f4bb46333429d8e9a4f566579f82cacbd3096c9 /.graveyard/meta/bin/update | |
parent | fe1017207310d0cfd6448750205d08b2455f20a2 (diff) | |
parent | 85c99011060b4b37a760fa24d0a0e23e83413bef (diff) |
Merge branch 'master' of github.com:krebscode/painload
Diffstat (limited to '.graveyard/meta/bin/update')
-rwxr-xr-x | .graveyard/meta/bin/update | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/.graveyard/meta/bin/update b/.graveyard/meta/bin/update new file mode 100755 index 00000000..9b2289ad --- /dev/null +++ b/.graveyard/meta/bin/update @@ -0,0 +1,15 @@ +#! /bin/sh +set -euf + +cd $(dirname $(readlink -f $0))/../.. +id=`ls -lnd . | awk '{print$3}'` + +if test "${nosudo-false}" != true -a `id -u` != $id; then + echo "we're going sudo..." >&2 + exec sudo -u "#$id" "$0" "$@" + exit 23 # go to hell +fi + +echo "// is $PWD owned by $id" + +git pull |