X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ian/git?p=topgit.git;a=blobdiff_plain;f=tg-remote.sh;h=3a40081b6b32435837c3b597ee4593f38e79de08;hp=4f60c7394b7fcca6ddc4e4c3fabb25f59237e359;hb=d400bb3263ab1239cc219541bb4364135b1b753e;hpb=459c340fd5ac765ff1e5d82895b59b53b028aaca diff --git a/tg-remote.sh b/tg-remote.sh index 4f60c73..3a40081 100644 --- a/tg-remote.sh +++ b/tg-remote.sh @@ -27,9 +27,9 @@ git config "remote.$name.url" >/dev/null || die "unknown remote '$name'" ## Configure the remote -git config --add "remote.$name.fetch" "+refs/top-bases/*:refs/remotes/$name/top-bases/*" -git config --add "remote.$name.push" "+refs/top-bases/*:refs/top-bases/*" -git config --add "remote.$name.push" "+refs/heads/*:refs/heads/*" +git config --replace-all "remote.$name.fetch" "+refs/top-bases/*:refs/remotes/$name/top-bases/*" "\\+refs/top-bases/\\*:refs/remotes/$name/top-bases/\\*" +git config --replace-all "remote.$name.push" "+refs/top-bases/*:refs/top-bases/*" "\\+refs/top-bases/\\*:refs/top-bases/\\*" +git config --replace-all "remote.$name.push" "+refs/heads/*:refs/heads/*" "\\+refs/heads/\\*:refs/heads/\\*" info "Remote $name can now follow TopGit topic branches." if [ -z "$populate" ]; then @@ -59,3 +59,5 @@ git for-each-ref "refs/remotes/$name/top-bases" | git config "topgit.remote" "$name" info "The remote '$name' is now the default source of topic branches." + +# vim:noet