X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~cjwatson/git?a=blobdiff_plain;f=baz-update-config;h=71588857cf05a071aa174c184359ebe5e9f722b2;hb=cdb79bca0737bc6c9e39cad2076d392387bc0ff0;hp=ed53853825d19a6592fa44a8122f045f864e2a44;hpb=499cabb0a1773a426c59838a523f73ec62c6127f;p=bin.git diff --git a/baz-update-config b/baz-update-config index ed53853..7158885 100755 --- a/baz-update-config +++ b/baz-update-config @@ -42,6 +42,17 @@ for line in $(baz cat-config "$1" 2>/dev/null || cat "$1"); do esac fi ;; + git://*|git+*://*) + if [ -d "$DIR" ]; then + if [ ! -d "$DIR/.git" ]; then + echo "$DIR is not a git checkout; cannot update" >&2 + continue + fi + (cd "$DIR" && git pull "$VERSION") + else + git clone "$VERSION" "$DIR" + fi + ;; *) if [ -d "$DIR" ]; then if [ ! -d "$DIR/{arch}" ]; then