clj-http
clj-http copied to clipboard
Export README.md from .org for cljdoc
https://cljdoc.org/ is a popular single-source-for-all-libs documentation hub so it would be ideal if the much used clj-http showed up well there. However it doesn't currently because cljdoc currently only supports .md and .adoc files while here we have an .org.
A solution would be to either export .md from the .org file (perhaps in a git push hook?) or to add .org support to Cljdoc.
This sounds like a good idea! @dakrone do you have any preference of an approach.
I've thought about a few ways to go about this.
-
Write a build script that generates README.md at build time. This could be done with an emacs script, hypothetically. I took a stab at this and found some issues with the current org file settings. I had to disable org-babel and the TOC generation to get export as markdown working. If we choose this strategy, we'd need to tweak the org file settings such that it's repeatable.
-
Migrate to markdown moving forward. This means doing a one-time pass to convert README.org to README.md and use it moving forward.
-
Stick with org and wait it out until
orgsupport incljdoc. There are no JVM-based org to HTML translators. However, it may be possible to reduce some effort spent on output generation if cljdoc can translate orgmode AST to flexmark AST.orgzlyhas a org-parser library which looks like a promising starting point -- that could be a fun project 🤷♂️
Ultimately, I think this depends on having the maintainer have final weigh in on the workflow. @dakrone if there's one strategy you prefer, I could take a stab at doing the work. :)
I don't mind switching the readme to Markdown, as not everyone uses org-mode (even though I enjoy Org more than Markdown :)). @rymndhng go ahead and do the conversion!
BTW pandoc can covnert org-mode to markdown, I believe.