You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hey, thanks for the great tool! It's very helpful.
Is your feature request related to a problem? Please describe.
Currently, the suggest command outputs the names in rST format. With the rise of MyST to write Sphinx docs in Markdown, it would be very useful if this tool could also output the suggested names in MyST format.
Interesting idea -- MyST is definitely here to stay, and odds are the next time I do anything major in Sphinx, I'll look carefully at doing that work in MyST.
The plan you lay out makes good sense to me, and I can't think of any implementation steps you've missed.
The one thing I'll push back on, lightly, is to ask: How valuable is emitting MyST formatting in addition to reST formatting, given that neither the reST currently emitted nor the MyST that'd be implemented for this would actually be a directly-usable cross-reference? (This being because the objects.inv, and thus sphobjinv, works with the long role names, which can't be used in cross-references.)
In other words -- MyST output wouldn't be directly copy-paste usable anyways, so isn't the current reST output good enough?
(That said, see #234, proposing a possible approach to having sphobjinv emit short-form role names, which if it worked should allow both reST and MyST output to be copy-paste usable. It would really be nice if this worked, but I'm a bit nervous that it'd turn out to be a major maintenance headache, trying to keep the directive conversion behavior compatible across Sphinx versions and over time.)
Hey, thanks for the great tool! It's very helpful.
Is your feature request related to a problem? Please describe.
Currently, the
suggest
command outputs the names in rST format. With the rise of MyST to write Sphinx docs in Markdown, it would be very useful if this tool could also output the suggested names in MyST format.https://myst-parser.readthedocs.io/en/latest/syntax/cross-referencing.html#cross-project-intersphinx-links
Describe the solution you'd like
Provide an argument for
suggest
to control the output format, e.g.--format
, defaulting to--format=rst
.Describe alternatives you've considered
Don't implement it, and let something else convert rST-formatted name to MyST?
Additional context
From a quick look, we probably need to add a method e.g.
as_myst
inSuperDataObj
, similar toas_rst
:sphobjinv/src/sphobjinv/data.py
Lines 226 to 236 in ff9151a
and then maybe add an
objects_myst
property toInventory
:sphobjinv/src/sphobjinv/inventory.py
Lines 276 to 291 in ff9151a
then add a parameter to
suggest()
for the format:sphobjinv/src/sphobjinv/inventory.py
Lines 430 to 438 in ff9151a
and finally expose that in the parser...
sphobjinv/src/sphobjinv/cli/suggest.py
Lines 41 to 79 in ff9151a
sphobjinv/src/sphobjinv/cli/parser.py
Lines 37 to 38 in ff9151a
The text was updated successfully, but these errors were encountered: