golang / go

The Go programming language
https://go.dev
BSD 3-Clause "New" or "Revised" License
123.55k stars 17.61k forks source link

x/tools/cmd/present2md: support full translation #37917

Open johanbrandhorst opened 4 years ago

johanbrandhorst commented 4 years ago

Not sure this should be considered part of #33955. Please close if so.

The new present2md tool converts the present format to markdown. However, it is still missing some pieces of the present format when converting, namely:

There may be more types I've missed, but these were the ones I noticed so far.

These are being caught by the fallback PresentCmd interface here:

https://github.com/golang/tools/blob/11a475a590acad44f466dde7d3e988cf52bad01c/cmd/present2md/main.go#L236-L247

I think it should be possible to convert both of these to markdown, though the caption may be more complicated.

cagedmantis commented 4 years ago

/cc @ianthehat @matloob

matloob commented 4 years ago

/cc @rsc @bcmills @jayconrod