Option not to activate bookmarks
Created originally on Bitbucket by steve-spencer (Steve Spencer)
TortoiseHg is central to my team's workflow. I want to improve it further by displaying annotations for every revision to indicate:
- which bugs were filed against that revision, if any
- which TeamCity automated tests & builds have run, if any, and what outcome.
This will allow a developer to instantly eyeball whether a feature branch is safe to integrate, or at least make it impossible for them to ignore failing tests or crashing revisions.
I first considered using "hg tag" to inject this data (via some scheduled task). But this would result in a new revision for every tag, massively polluting the repository history, and with conflict risk. And over time, I'm concerned performance may degrade.
So I am now considering using "hg bookmark --inactive", since it is automatically shared without creating revisions. This would work very well, providing no developer accidentally made a bookmark active and started moving its revision. (Ideally there'd be a core hg option to 'lock' bookmarks as inactive, but I doubt I'd get any traction with that).
Using command-line, bookmarks are only activated explicitly when you create them by default, and when you update to them by name. I can live with the relatively low risk of them moving in this circumstance. And I think I can prevent this being pushed using hooks (although can't find any python docs on the relevant hg hook).
However using THg, if you choose "Update" on a given revision, it automatically selects the first bookmark name in the drop-down. There's no way to prevent this behaviour. You then have to edit the drop-down and copy the revision number below into it. This behaviour and its risk of mutating bookmarks is preventing me from rolling out this incredible new workflow!
In the settings I found "Activate Bookmarks" and set it to "never". But strangely this seems to refer to the showing of the prompt, not the activating of the bookmarks. Or something else.
So, is it possible to have an option in THg something like this:
"Update to bookmarks: never"?
Or: "Activate bookmarks on update: never"?