( )⚙ D9988 gendoc: support defaults on customopts a bit better

This is an archive of the discontinued Mercurial Phabricator instance.

gendoc: support defaults on customopts a bit better
ClosedPublic

Authored by spectral on Feb 12 2021, 3:05 PM.

Details

Summary

Without this, a customopt will very likely render like this:

-foo   does foo (default: <hgext.myextension.MyOpt object at 0x7f31...>)

I copied this logic from how this is handled in mercurial/help.py.

Diff Detail

Repository
rHG Mercurial
Branch
default
Lint
No Linters Available
Unit
No Unit Test Coverage

Event Timeline

spectral created this revision.Feb 12 2021, 3:05 PM
pulkit accepted this revision.Feb 14 2021, 10:15 AM
This revision is now accepted and ready to land.Feb 14 2021, 10:15 AM
This revision was automatically updated to reflect the committed changes.