This is an archive of the discontinued Mercurial Phabricator instance.

status: extract helper for producing relative or absolute path for UI
ClosedPublic

Authored by martinvonz on Jan 30 2019, 3:19 PM.

Details

Summary

I put the helper in scmutil so it can be used by most modules. I would
have put it in utils.pathutil, but I think that's supposed to be
unaware of repos.

Diff Detail

Repository
rHG Mercurial
Lint
Lint Skipped
Unit
Unit Tests Skipped

Event Timeline

martinvonz created this revision.Jan 30 2019, 3:19 PM
pulkit accepted this revision.Jan 31 2019, 3:53 PM
This revision was automatically updated to reflect the committed changes.
mharbison72 added inline comments.
mercurial/commands.py
5417–5418

Not sure if it's worth fixing the syntax error here before it goes public. I only noticed because I was bisecting a test failure. The next patch drops the trailing :.

yuja added a subscriber: yuja.Feb 1 2019, 10:56 PM

+ relative = pats or ui.configbool('commands', 'status.relative'):
+ uipathfn = scmutil.getuipathfn(repo, relative)

Not sure if it's worth fixing the syntax error here before it goes public. I only noticed because I was bisecting a test failure. The next patch drops the trailing :.

Fixed, thanks.

In D5745#85049, @yuja wrote:

+ relative = pats or ui.configbool('commands', 'status.relative'):
+ uipathfn = scmutil.getuipathfn(repo, relative)

Not sure if it's worth fixing the syntax error here before it goes public. I only noticed because I was bisecting a test failure. The next patch drops the trailing :.

Fixed, thanks.

Thanks to both of you. I'll try to be more careful in the future.