This is useful if the remote has new topics and you need to populate the local
top-bases.
Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
and 'git push' to operate on them. (Do NOT use 'git push --all'
for your pushes - plain 'git push' will do the right thing.)
and 'git push' to operate on them. (Do NOT use 'git push --all'
for your pushes - plain 'git push' will do the right thing.)
- It takes a mandatory remote name argument, and optional
+ It takes a optional remote name argument, and optional
'--populate' switch - use that for your origin-style remote,
it will seed the local topic branch system based on the
remote topic branches. '--populate' will also make 'tg remote'
'--populate' switch - use that for your origin-style remote,
it will seed the local topic branch system based on the
remote topic branches. '--populate' will also make 'tg remote'
--populate)
populate=1;;
-*)
--populate)
populate=1;;
-*)
- echo "Usage: tg [...] remote [--populate] REMOTE" >&2
+ echo "Usage: tg [...] remote [--populate] [REMOTE]" >&2
exit 1;;
*)
name="$arg";;
esac
done
exit 1;;
*)
name="$arg";;
esac
done
+[ -n "$name" ] ||
+ name="$base_remote"
+
git config "remote.$name.url" >/dev/null || die "unknown remote '$name'"
git config "remote.$name.url" >/dev/null || die "unknown remote '$name'"