On 6 Oct 2022, at 20.31, 'Sanjay Vasandani' via hg-git <
hg-...@googlegroups.com> wrote:
> With Git, there are refs created for remote branches but there's not automatically a tracking branch for each remote branch. hg-git, on the other hand, creates a bookmark for each remote branch unconditionally in addition to the git-remote pseudo-tag which is equivalent to the Git ref. This requires unnecessary bookkeeping and noise in the set of bookmarks, especially when following the pattern of personal remote branches (i.e. allowing rewriting of history on remote branches that nobody else is expected to use).
>
> I'd prefer an option to not have tracking bookmarks automatically, allowing one to create them as-needed. Arguably this should be the default to match Git behavior. We also may want to persist some additional metadata to associate a bookmark with its remote Git branch (pseudo-tag) rather than relying on name.
I think the main challenge with that setup up is that the “remote branch” concept doesn't exist in Mercurial, so you'd _never_ get any bookmarks unless you create them yourself. And if other people force-push their branches, those commits would still litter your history…
I think a better solution is to just not pull (in Mercurial terms) all branches. You can do that at the moment by specifying a default revision to using the URL fragment, e.g. `#master`. Personally, I set it up like that, and when I want any _other_ branch, I pull it using `hg pull -r otherbranch`. Having multiple default revisions/names on the remote would be nice, but I don't think that's possible even with a regular Mercurial repository…
(Apologies for the late response, but I haven't had much time for hg-git lately.)
--
Dan Villiom Podlaski Christiansen
dan...@gmail.com —
+45 2728 9771