Loading... |
Reply to author |
Edit post |
Move post |
Delete this post |
Delete this post and replies |
Change post date |
Print post |
Permalink |
Raw mail |
![]() ![]() ![]() ![]() ![]() ![]() ![]() |
19 posts
|
Hi, this command worked already. Yesterday, I wanted to use this command again but get an exception.
AsciiDoctorJ -b pdf 0_Documentation_de.adoc I installed AsciiDoctorJ via Chocolatey. The command works with the zip-installation. Could somebody tell me the reason? Conrad Jan 20, 2020 7:01:15 AM org.asciidoctor.jruby.internal.JRubyAsciidoctor convertFile SEVERE: (NoMethodError) undefined method `highlight?' for nil:NilClass Exception in thread "main" org.asciidoctor.jruby.internal.AsciidoctorCoreException: org.jruby.exceptions.NoMethodError: (NoMethodError) undefined method `highlight?' for nil:NilClass at org.asciidoctor.jruby.internal.JRubyAsciidoctor.convertFile(JRubyAsciidoctor.java:391) at org.asciidoctor.jruby.internal.JRubyAsciidoctor.convertFile(JRubyAsciidoctor.java:405) at org.asciidoctor.jruby.internal.JRubyAsciidoctor.convertFile(JRubyAsciidoctor.java:400) at org.asciidoctor.jruby.cli.AsciidoctorInvoker.renderInput(AsciidoctorInvoker.java:169) at org.asciidoctor.jruby.cli.AsciidoctorInvoker.invoke(AsciidoctorInvoker.java:72) at org.asciidoctor.jruby.cli.AsciidoctorInvoker.main(AsciidoctorInvoker.java:229) Caused by: org.jruby.exceptions.NoMethodError: (NoMethodError) undefined method `highlight?' for nil:NilClass at RUBY.convert_listing_or_literal(uri:classloader:/gems/asciidoctor-pdf-1.5.0.alpha.18/lib/asciidoctor-pdf/converter.rb:1441) at RUBY.convert(uri:classloader:/gems/asciidoctor-pdf-1.5.0.alpha.18/lib/asciidoctor-pdf/converter.rb:127) at RUBY.convert(uri:classloader:/gems/asciidoctor-2.0.10/lib/asciidoctor/abstract_block.rb:75) at RUBY.content(uri:classloader:/gems/asciidoctor-2.0.10/lib/asciidoctor/abstract_block.rb:84) at org.jruby.RubyArray.map(org/jruby/RubyArray.java:2577) at RUBY.content(uri:classloader:/gems/asciidoctor-2.0.10/lib/asciidoctor/abstract_block.rb:84) at RUBY.convert_content_for_block(uri:classloader:/gems/asciidoctor-pdf-1.5.0.alpha.18/lib/asciidoctor-pdf/converter.rb:143) at RUBY.convert_section(uri:classloader:/gems/asciidoctor-pdf-1.5.0.alpha.18/lib/asciidoctor-pdf/converter.rb:498) at RUBY.convert(uri:classloader:/gems/asciidoctor-pdf-1.5.0.alpha.18/lib/asciidoctor-pdf/converter.rb:127) at RUBY.convert(uri:classloader:/gems/asciidoctor-2.0.10/lib/asciidoctor/abstract_block.rb:75) at RUBY.content(uri:classloader:/gems/asciidoctor-2.0.10/lib/asciidoctor/abstract_block.rb:84) at org.jruby.RubyArray.map(org/jruby/RubyArray.java:2577) at RUBY.content(uri:classloader:/gems/asciidoctor-2.0.10/lib/asciidoctor/abstract_block.rb:84) at RUBY.content(uri:classloader:/gems/asciidoctor-2.0.10/lib/asciidoctor/document.rb:1020) at RUBY.convert_content_for_block(uri:classloader:/gems/asciidoctor-pdf-1.5.0.alpha.18/lib/asciidoctor-pdf/converter.rb:143) at RUBY.convert_document(uri:classloader:/gems/asciidoctor-pdf-1.5.0.alpha.18/lib/asciidoctor-pdf/converter.rb:268) at RUBY.convert(uri:classloader:/gems/asciidoctor-pdf-1.5.0.alpha.18/lib/asciidoctor-pdf/converter.rb:127) at RUBY.convert(uri:classloader:/gems/asciidoctor-2.0.10/lib/asciidoctor/document.rb:951) at RUBY.convert(uri:classloader:/gems/asciidoctor-2.0.10/lib/asciidoctor/convert.rb:118) at RUBY.convert_file(uri:classloader:/gems/asciidoctor-2.0.10/lib/asciidoctor/convert.rb:183) at org.jruby.RubyIO.open(org/jruby/RubyIO.java:1157) at RUBY.convert_file(uri:classloader:/gems/asciidoctor-2.0.10/lib/asciidoctor/convert.rb:183) |
Loading... |
Reply to author |
Edit post |
Move post |
Delete this post |
Delete this post and replies |
Change post date |
Print post |
Permalink |
Raw mail |
![]() ![]() ![]() ![]() ![]() ![]() ![]() |
Administrator
2681 posts
|
There are two reasons for this. First, it's likely that your document header is not properly defined. And the old version of Asciidoctor PDF that you're using would crash when that happened. The latest version of Asciidoctor PDF is 1.0.0.rc.2. If you upgrade, it will fix the crash. If you fix your document header, it will remove the condition that caused that crash. Best, -Dan On Sun, Jan 19, 2020 at 11:07 PM Conrad [via Asciidoctor :: Discussion] <[hidden email]> wrote: Hi, this command worked already. Yesterday, I wanted to use this command again but get an exception. ... [show rest of quote] -- Dan Allen | @mojavelinux | https://twitter.com/mojavelinux |
Loading... |
Reply to author |
Edit post |
Move post |
Delete this post |
Delete this post and replies |
Change post date |
Print post |
Permalink |
Raw mail |
![]() ![]() ![]() ![]() ![]() ![]() ![]() |
19 posts
|
I run AsciiDoctorJ 2.2.0 from https://github.com/asciidoctor/asciidoctorj/releases.
This version includes Asciidoctor PDF 1.5.0-beta.8. Are there newer versions available? |
Loading... |
Reply to author |
Edit post |
Move post |
Delete this post |
Delete this post and replies |
Change post date |
Print post |
Permalink |
Raw mail |
![]() ![]() ![]() ![]() ![]() ![]() ![]() |
242 posts
|
The zip package has some default versions for ease of installation, but you can override them if you need with more recent ones.
Last asciidoctorj-pdf is `v1.5.0-rc.2` https://github.com/asciidoctor/asciidoctorj-pdf/releases. This is one of those scenarios in which using a build tool can make life easier, for instance there's an example using maven in whcih you can set the versions to use separatedly https://github.com/asciidoctor/asciidoctor-maven-examples/blob/master/asciidoctor-pdf-example/pom.xml. |
Loading... |
Reply to author |
Edit post |
Move post |
Delete this post |
Delete this post and replies |
Change post date |
Print post |
Permalink |
Raw mail |
![]() ![]() ![]() ![]() ![]() ![]() ![]() |
Administrator
2681 posts
|
The stacktace says it's alpha.18, not beta.8.
|
Loading... |
Reply to author |
Edit post |
Move post |
Delete this post |
Delete this post and replies |
Change post date |
Print post |
Permalink |
Raw mail |
![]() ![]() ![]() ![]() ![]() ![]() ![]() |
19 posts
|
The bin folder has following content:
asciidoctorj-2.2.0.jar asciidoctorj-api-2.2.0.jar asciidoctorj-diagram-2.0.0.jar asciidoctorj-epub3-1.5.0-alpha.9.jar asciidoctorj-pdf-1.5.0-beta.8.jar jcommander-1.72.jar jruby-complete-9.2.9.0.jar |
Loading... |
Reply to author |
Edit post |
Move post |
Delete this post |
Delete this post and replies |
Change post date |
Print post |
Permalink |
Raw mail |
![]() ![]() ![]() ![]() ![]() ![]() ![]() |
19 posts
|
In reply to this post by abelsromero
Many thanks, @abelsromero.
I put asciidoctorj-pdf-1.5.0-alpha.6.jar into lib and changed the classpath in the bat-file. That does not work: Exception in thread "main" org.jruby.exceptions.LoadError: (ConflictError) Unable to activate asciidoctor-pdf-1.5.0.alpha.6, because asciidoctor-2.0.10 conflicts with asciidoctor (~> 1.5.0) at RUBY.raise_if_conflicts(uri:classloader:/META-INF/jruby.home/lib/ruby/stdlib/rubygems/specification.rb:2332) at RUBY.activate(uri:classloader:/META-INF/jruby.home/lib/ruby/stdlib/rubygems/specification.rb:1441) at RUBY.try_activate(uri:classloader:/META-INF/jruby.home/lib/ruby/stdlib/rubygems.rb:224) at RUBY.require(uri:classloader:/META-INF/jruby.home/lib/ruby/stdlib/rubygems/core_ext/kernel_require.rb:123) at RUBY.<main>(<script>:1) That would not happen by using a build-tool? Using a build-tool is difficult for me due to firewalls and proxies. That's why I avoid that as long as possible. Conrad |
Loading... |
Reply to author |
Edit post |
Move post |
Delete this post |
Delete this post and replies |
Change post date |
Print post |
Permalink |
Raw mail |
![]() ![]() ![]() ![]() ![]() ![]() ![]() |
242 posts
|
Note I mentioned version `v1.5.0-rc.2`.
At this point I wonder how did you install? Obviously the versions are not correct but I canot see any binary distribution in https://github.com/asciidoctor/asciidoctorj/releases. |
Loading... |
Reply to author |
Edit post |
Move post |
Delete this post |
Delete this post and replies |
Change post date |
Print post |
Permalink |
Raw mail |
![]() ![]() ![]() ![]() ![]() ![]() ![]() |
19 posts
|
I did not install the libraries. I unpacked the zip-file and run:
C:\Program_Portable\asciidoctorj\bin\asciidoctorj.bat -b pdf mydoc.adoc |
Loading... |
Reply to author |
Edit post |
Move post |
Delete this post |
Delete this post and replies |
Change post date |
Print post |
Permalink |
Raw mail |
![]() ![]() ![]() ![]() ![]() ![]() ![]() |
19 posts
|
In reply to this post by abelsromero
I also have asccidoctor installed. I installed it by Gem. Is it possible, that AsciidoctorJ ("installed" as zip) loads libraries from asccidoctor ?
|
Loading... |
Reply to author |
Edit post |
Move post |
Delete this post |
Delete this post and replies |
Change post date |
Print post |
Permalink |
Raw mail |
![]() ![]() ![]() ![]() ![]() ![]() ![]() |
Administrator
2681 posts
|
No, that should not happen. But I strongly advise you to use either Asciidoctor (Ruby) or AsciidoctorJ, not both at the same time. That's only going to lead to confusion. Best, -Dan On Tue, Jan 21, 2020 at 11:44 PM Conrad [via Asciidoctor :: Discussion] <[hidden email]> wrote: I also have asccidoctor installed. I installed it by Gem. Is it possible, that AsciidoctorJ ("installed" as zip) loads libraries from asccidoctor ? -- Dan Allen | @mojavelinux | https://twitter.com/mojavelinux |
Loading... |
Reply to author |
Edit post |
Move post |
Delete this post |
Delete this post and replies |
Change post date |
Print post |
Permalink |
Raw mail |
![]() ![]() ![]() ![]() ![]() ![]() ![]() |
19 posts
|
Many thanks.
I have a further question: if I use AsciiDoctorJ, I do not have to install anything. This is also very end-user-friendly. Is this also possible for Asciidoctor? I can not expect from endusers to install and run gem. |
Free forum by Nabble | Edit this page |