Asciidoctor installation - pacman vs gem

I’ve been using asciidoc (format and application) for years. In recent years, asciidoc has become officially a markup language and there are a number of asciidoc tools that convert asciidoc to html, epub, pdf, etc. The original asciidoc application was written in python. The current conversion tools are written in everything but it seems.

I’m still researching options, but I’m not keen on using anything outside of pacman (i.e., pip, gem, cpan)…

I’m looking at asciidoctor, which is written in ruby. I know very little about ruby’s packaging system, gem.

  1. asciidoctor is in the manjaro repository :heavy_check_mark: (one done :slight_smile: )

  2. the pkgbuild at archlinux, shows it obtaining the gem

    • Is this a system-wide install or $HOME? I suppose the line below is key. Does the user have to set a ruby environmental variable to control default_dir?
       local _gemdir="$(ruby -e 'puts Gem.default_dir')"
  1. The gem shows a number of gem dependencies (cucumber, haml, etc)

    • Is the gem system smart enough to pull these in, or does the user have to install them separately?
  2. I noticed a number of asciidoctor packages in the AUR, that appear to be addon’s for various document conversions. I don’t know if these are necessary or is everything to produce epub, pdf, html installed in #2. If it isn’t, that would mean I have to chose between the AUR or the gem repository. I’m think’n if I need to go to the AUR to support epub, pdf, html, I might be better off installing everything using gem.

    • Does ruby have a virtual environment like python?

Anyone else using asciidoctor? If so, how did you install it (pacman or gem), $HOME or system?

Or are you using something else to convert asciidoc to epub, pdf, html?

  1. Right.
  2. It’s installed system-wide. You don’t need any options.
  3. I don’t know but in this case, your linked gem lists the dependencies as development, so you need them when you are building the gem rather than installing.
  4. Yes, if you want a custom build, you need to install the AUR package.
  5. It is the origin of pyenv: GitHub - rbenv/rbenv: Manage your app's Ruby environment

If I ever need asciidoctor, I’ll first use the repo version, then AUR, then if I need more, I’ll try to create a custom PKGBUILD, and only then if nothing else works, I’d resort back to a user-local gem install.

It is this: https://rvm.io/

If you’re playing around with Ruby, I wouldn’t recommend a system-wide installation. It’s more comfortable to compile and run Ruby ONLY in your home folder, at least it’s safer and you don’t break things. Also, it’s great for projects like Jekyll, Asciidoc, etc. I would really recommend installing it with RVM.

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.