-
Notifications
You must be signed in to change notification settings - Fork 139
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added pki-server markdown page #160
Conversation
92d50d2
to
560581e
Compare
@edewata this looks like a good approach. I have few comments. I see that cpuguys83/go-md2man is used to convert md to man pages.
My original plan was to host docs in a central server and publish the man page as HTML as well. Here is the issue that I submitted to readthedocs. I have included a flow diagram for reference :) |
The pki-server.8 man page has been converted into Markdown page. The CMake script has been modified to generate a man page from the Markdown page. The pki.spec has been modified to add build dependency on go-md2man. https://pagure.io/dogtagpki/issue/2858
Thanks for the feedback.
In terms of bugs or availability? I'm not sure we can find a definitive answer to that, but judging from the build history it looks like it has been used for sometime and is continuously being built in Fedora and RHEL:
I suppose you're referring to this? https://github.com/cpuguy83/go-md2man What matters is we can use the actual package on the platform. I can confirm that it is available on Fedora and RHEL, and it looks like it is available on Debian too.
I'm not familiar with sphinx and I don't see an actual example. I think we can use md2man as an initial implementation, but later we can certainly switch to sphinx if that is superior to md2man.
I couldn't find ronn in RHEL.
We can still do that. With this patch at least we can start converting the man pages to markdown. The markdown pages will be the master document and stored in git repo to simplify the development. The build artifacts (i.e. the man pages and HTML pages) can be published somewhere else if necessary. |
The issue is: different packages expect different md styles. If we decide to move from md2man to sphinx in future, we might have to reformat all the markdown files. Here is an example that is given as input to
It goes by the name |
There might be some differences, but I don't expect that to be major since they are all markdown files.
Actually, we want to be able to view the source (i.e. markdown) directly on GitHub so that mistakes can be found and fixed quickly. Compare the md2man input with the ronn input above, it looks good when viewed online (as markdown) and offline (as man pages). If necessary we can later find a tool that can convert it to a good HTML too, but it's a lower priority since the markdown page already looks pretty good.
Right, but it's not in buildroot. |
Here's another md2man example. |
Tested on local. The generated |
Thanks! |
The pki-server.8 man page has been converted into Markdown
page. The CMake script has been modified to generate a man
page from the Markdown page.
The pki.spec has been modified to add build dependency on
golang-github-cpuguy83-go-md2man.
https://pagure.io/dogtagpki/issue/2858
The Markdown page can be viewed here.