( )⚙ D1758 remotenames: add new namespaces for remotebookmarks and remotebranches

This is an archive of the discontinued Mercurial Phabricator instance.

remotenames: add new namespaces for remotebookmarks and remotebranches
ClosedPublic

Authored by pulkit on Dec 25 2017, 3:51 PM.

Details

Summary

This patch adds two new namespaces which will be enabled by remotenames
extension. The namespaces are remotebookmarks and remotebranches. Adding them
as namespaces will show them in various commands' output such as log, show work.
This will also unable to access changesets using that name.

Tests are also added for the same.

This is a part of moving hgremotenames extension to core.

hgremotenames: https://bitbucket.org/seanfarley/hgremotenames

Diff Detail

Repository
rHG Mercurial
Lint
Lint Skipped
Unit
Unit Tests Skipped

Event Timeline

pulkit created this revision.Dec 25 2017, 3:51 PM
durin42 requested changes to this revision.Jan 18 2018, 3:06 PM
durin42 added a subscriber: durin42.

Easiest path is to mark this as experimental, and then we can do an iteration in the next cycle and remove the warning label.

hgext/remotenames.py
187

Hm, I'm not sure if we want to name remote{bookmarks,branches} the same as local ones in log output. It may make sense to defer this until after the freeze, or else mark the remotenames extension as experimental for a cycle.

This revision now requires changes to proceed.Jan 18 2018, 3:06 PM
pulkit added inline comments.Jan 19 2018, 2:39 AM
hgext/remotenames.py
187

I am fine either way.

pulkit added inline comments.Jan 22 2018, 12:53 PM
hgext/remotenames.py
187

Hm, I'm not sure if we want to name remote{bookmarks,branches} the same as local ones in log > output.

Does remotebookmark, and remotebranch sounds good?

durin42 added inline comments.Jan 22 2018, 1:10 PM
hgext/remotenames.py
187

Works for me.

martinvonz added inline comments.
hgext/remotenames.py
187

Does remotebookmark, and remotebranch sounds good?

Will the log output get aligned for these longer names?

Should we include a space? "remote bookmark:" looks more user-friendly

pulkit updated this revision to Diff 5147.Feb 2 2018, 2:47 AM
pulkit added inline comments.Feb 2 2018, 2:50 AM
hgext/remotenames.py
187

I made it remote bookmark and remote branch and the log output does not get aligned. :(

durin42 accepted this revision.Feb 12 2018, 3:26 PM
This revision is now accepted and ready to land.Feb 12 2018, 3:26 PM
This revision was automatically updated to reflect the committed changes.
martinvonz added inline comments.Feb 14 2018, 2:11 AM
tests/test-logexchange.t
130–131

This is pretty hard to read. Should we at least add a space between the label-and-colon and the value?

pulkit added inline comments.Feb 14 2018, 5:04 AM
tests/test-logexchange.t
130–131

I agree with you. I will send a followup for this.