Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Consider antora #9

Closed
borkdude opened this issue Nov 29, 2020 · 8 comments
Closed

Consider antora #9

borkdude opened this issue Nov 29, 2020 · 8 comments

Comments

@borkdude
Copy link
Contributor

borkdude commented Nov 29, 2020

WIP branch: https://github.com/babashka/book/tree/antora

We have a working version:

$ antora generate antora-playbook.yml --to-dir /tmp/antora --clean

References:

This seems like a nice starting point:

https://blog.anoff.io/2019-02-15-antora-first-steps/

Trade-offs:

  • Antaro seems like a pretty heavy framework.
  • PDF generation doesn't seem to be supported.
  • We might want to build our own solution using asciidoctor in Clojure
    E.g. see https://git.sr.ht/~severeoverfl0w/anansi/tree/master/src2/io/dominic/anansi/adoc.clj
  • The only reason I am considering antaro is a collapsible menu. This is now fixed with a JS plugin (tocify).
  • Ctrl-f just works with the asciidoctor version, not with the antora version which needs a specific plugin.
@borkdude borkdude changed the title Try out antora Consider antora Nov 29, 2020
@borkdude
Copy link
Contributor Author

For now we will continue with the master branch and leave the antora branch as is. At least we have a nice reference of how things could look, but it adds too much complexity imo.

@borkdude borkdude reopened this Nov 30, 2020
@borkdude
Copy link
Contributor Author

borkdude commented Nov 30, 2020

The next issue:

Screenshot 2020-11-30 at 11 24 24

This page is obviously in the gh-pages tree:
https://github.com/babashka/book/blob/gh-pages/_/intro.html
But somehow it doesn't get served:
https://book.babashka.org/_/intro.html

@oxalorg
Copy link

oxalorg commented Nov 30, 2020

@borkdude Can you try adding a .nojekyll empty file in the root of gh-pages branch file. I've had some similar issues with gh-pages in the past.

@bbatsov
Copy link

bbatsov commented Nov 30, 2020

Ctrl-f just works with the asciidoctor version, not with the antora version which needs a specific plugin.

Not sure what this is, but implementing search is fairly easy with Algolia Docsearch (it's something like 10 lines of code).

@borkdude
Copy link
Contributor Author

That's it! https://book.babashka.org/_/intro.html

@borkdude
Copy link
Contributor Author

From @bbatsov on Slack:

Btw, if you need search - you can just copy a couple of snippets from https://github.com/nrepl/nrepl.org/blob/master/supplemental-ui/partials/ It's a manual change, but it's pretty simple.
12:25 PM
And if you need some end user instructions - you can just borrow https://docs.cider.mx/cider/0.26/contributing/docs.html

@borkdude
Copy link
Contributor Author

@bbatsov The ctrl-f thing is explained well in this tweet:

https://twitter.com/_softwar_/status/1333389984313831424

@borkdude
Copy link
Contributor Author

borkdude commented Dec 1, 2020

According to this poll roughly 2/3rd of people prefer the simpler one-page approach:

https://twitter.com/borkdude/status/1333429147855708160

The main reasons that were mentioned for #1:

  • Easier continuous reading without reloads or nav
  • Ctrl-f just works for the entire corpus

Since I'm not writing docs for myself but for end users, I'm fine with this outcome.

@borkdude borkdude closed this as completed Dec 1, 2020
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants