Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.user > #274085

Re: asciidoctor-pdf

From Jeffrey Walton <noloader@gmail.com>
Newsgroups linux.debian.user
Subject Re: asciidoctor-pdf
Date 2024-10-26 23:40 +0200
Message-ID <JBWFP-4qxe-13@gated-at.bofh.it> (permalink)
References <JBQAp-4mZJ-7@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Sat, Oct 26, 2024 at 2:13 PM Tom Browder <tom.browder@gmail.com> wrote:
>
> I am running Debian 11 and trying to run asciidoctor and
> asciidoctor-pdf with no luck so far.
>
> I run it with this bash script:
>
> asciidoctor -r asciidoctor-pdf -b pdf \
>   -a pdf-theme=binder \
>   -a pdf-themesdir=./data/themes \
>   -a document_name=”Raku Guide” \
>   -o rakuguide-binder.pdf rakuguide-binder.adoc
>
> and get this error:
>
> Traceback (most recent call last):
> 9: from /usr/bin/asciidoctor-pdf:21:in `<main>'
> 8: from /usr/lib/ruby/vendor_ruby/asciidoctor/cli/options.rb:193:in `parse!'
> 7: from /usr/lib/ruby/2.7.0/optparse.rb:1691:in `parse!'
> 6: from /usr/lib/ruby/2.7.0/optparse.rb:1666:in `permute!'
> 5: from /usr/lib/ruby/2.7.0/optparse.rb:1569:in `order!'
> 4: from /usr/lib/ruby/2.7.0/optparse.rb:1575:in `parse_in_order'
> 3: from /usr/lib/ruby/2.7.0/optparse.rb:1575:in `catch'
> 2: from /usr/lib/ruby/2.7.0/optparse.rb:1621:in `block in parse_in_order'
> 1: from /usr/lib/ruby/vendor_ruby/asciidoctor/cli/options.rb:87:in
> `block (2 levels) in parse!'
> /usr/lib/ruby/vendor_ruby/asciidoctor/cli/options.rb:87:in `encode':
> "\\xE2" from ASCII-8BIT to UTF-8 (Encoding::UndefinedConversionError)
>
> I have asked for help from the asciidoctor community but no response so far.
>
> Anyone here running asciidoctor have any suggestions?

And one more comment. According to <https://asciidoctor.org/>:

<SNIP>

If you’re using a non-English Windows environment, you may bump into
an Encoding::UndefinedConversionError when invoking Asciidoctor. To
solve this issue, we recommend overriding the default external and
internal character encodings to utf-8. You can do so by setting the
RUBYOPT environment variable as follows:

    RUBYOPT="-E utf-8:utf-8"

Once you make this change, all your Unicode headaches should be behind you.

If you’re using an IDE like Eclipse, make sure you set the encoding to
UTF-8 there as well. Asciidoctor is optimized to work with UTF-8 as
the default encoding.
</SNIP>

Jeff

Back to linux.debian.user | Previous | Next — Previous in thread | Find similar | Unroll thread


Thread

asciidoctor-pdf Tom Browder <tom.browder@gmail.com> - 2024-10-26 17:10 +0200
  Re: asciidoctor-pdf <tomas@tuxteam.de> - 2024-10-26 18:10 +0200
    Re: asciidoctor-pdf Tom Browder <tom.browder@gmail.com> - 2024-10-26 22:30 +0200
  Re: asciidoctor-pdf Jeffrey Walton <noloader@gmail.com> - 2024-10-26 23:30 +0200
  Re: asciidoctor-pdf Jeffrey Walton <noloader@gmail.com> - 2024-10-26 23:40 +0200

csiph-web