Asciidoctor-diagram on Windows

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
11 messages Options
Reply | Threaded
Open this post in threaded view
|

Asciidoctor-diagram on Windows

Nanook
Hi folks,
I've been struggling to get asciidoctor-diagram to work for a couple of days now and have made pretty much no progress. I am trying to get the plantuml, blockdiag and ditaa rendering implemented. I have the asciidoctor and asciidoctor-diagram gems installed, but running asciidoctor -r asciidoctor-diagram test.adoc  results in no output and no diagnostics. Including --trace produces nothing, it is as if the command is hanging up somewhere but I can't find out where. Cancelling the command simply asks me if I want to terminate the batch job. I am completely stuck... My minimal knowledge of ruby is of course of little help... Any assistance would be immensely appreciated! Here the sample I am trying to run:


= diagram  tst

== header

[ditaa, "dita_file", "svg"]
....
                   +-------------+
                   | Asciidoctor |-------+
                   |   diagram   |       |
                   +-------------+       | PNG out
                       ^                 |
                       | ditaa in        |
                       |                 v
 +--------+   +--------+----+    /---------------\
 |        | --+ Asciidoctor +--> |               |
 |  Text  |   +-------------+    |   Beautiful   |
 |Document|   |   !magic!   |    |    Output     |
 |     {d}|   |             |    |               |
 +---+----+   +-------------+    \---------------/
     :                                   ^
     |          Lots of work             |
     +-----------------------------------+
....

[[main-classes]]
.The PlantUML block extension class
[plantuml, sample-plantuml-diagram, alt="Class diagram", width=135, height=118]
----
class BlockProcessor
class PlantUmlBlock
BlockProcessor <|-- PlantUmlBlock
----

Source code:

[source, java]
----
class Test {

}
----
Reply | Threaded
Open this post in threaded view
|

Re: Asciidoctor-diagram on Windows

Nanook
I've tried doing it via a ruby script, but the same thing happens, i.e. nothing...

#!/usr/bin/env ruby

require 'asciidoctor'
require 'asciidoctor/cli/options'
require 'asciidoctor/cli/invoker'

require 'asciidoctor-diagram'

Asciidoctor.convert_file 'test2.adoc'
Reply | Threaded
Open this post in threaded view
|

Re: Asciidoctor-diagram on Windows

habamax
In reply to this post by Nanook
I am on windows 10.

Your file results in:




The same is for HTML.

But I also have plantuml installed and have it on my path. (plantuml includes ditaa)
Reply | Threaded
Open this post in threaded view
|

Re: Asciidoctor-diagram on Windows

habamax
In reply to this post by Nanook
Well, now I understand you :)

Check https://github.com/asciidoctor/asciidoctor-diagram/issues/254

Basically for windows asciidoctor-diagram is probably a second class citizen as main dev have no windows and does not test against it. That is life :).

What you can do is to install version that works for windows: 1.5.19:

gem uninstall asciidoctor-diagram
gem install asciidoctor-diagram -v 1.5.19

Hope this issue would be resolved.
Reply | Threaded
Open this post in threaded view
|

Re: Asciidoctor-diagram on Windows

mojavelinux
Administrator
> Basically for windows asciidoctor-diagram is probably a second class citizen as main dev have no windows and does not test it against it.

That's really untrue and unfair. The Asciidoctor developers across the board have always treated Windows with just as much concern as other platforms, even if most of the developers don't use Windows as a primary desktop. Furthermore, the claim that asciidoctor-diagram is not tested on Windows is undoubtably false. asciidoctor-diagram is tested on Windows on every commit using AppVeyor CI. See https://github.com/asciidoctor/asciidoctor-diagram/blob/master/appveyor.yml

Let's focus on constructive suggestions, not conjecture.

Best,

-Dan

On Tue, Jan 7, 2020 at 12:08 PM habamax [via Asciidoctor :: Discussion] <[hidden email]> wrote:
Well, now I understand you :)

Check https://github.com/asciidoctor/asciidoctor-diagram/issues/254

Basically for windows asciidoctor-diagram is probably a second class citizen as main dev have no windows and does not test it against it. That is life :).

What you can do is to install version that works for windows: 1.5.19:

gem uninstall asciidoctor-diagram
gem install asciidoctor-diagram -v 1.5.19

Hope this issue would be resolved.


If you reply to this email, your message will be added to the discussion below:
https://discuss.asciidoctor.org/Asciidoctor-diagram-on-Windows-tp7443p7475.html
To start a new topic under Asciidoctor :: Discussion, email [hidden email]
To unsubscribe from Asciidoctor :: Discussion, click here.
NAML


--
Dan Allen | @mojavelinux | https://twitter.com/mojavelinux
Reply | Threaded
Open this post in threaded view
|

Re: Asciidoctor-diagram on Windows

habamax
> Let's focus on constructive suggestions, not conjecture..

Really sorry, I didn't mean to harm and insult here.

I've spent last 6 hours debugging this issue trying to find out the root cause... Plus this is the second time for me when asciidoctor-diagram dev tells me that he has no windows to check the issue. Thus my conclusion that probably asciidoctor-diagram is not tested against windows.

Again, sorry, didn't mean to sound offensive.
Reply | Threaded
Open this post in threaded view
|

Re: Asciidoctor-diagram on Windows

habamax
+ I have just run the `bundle exec rspec` for asciidoctor-diagram.

It hanged...



Reply | Threaded
Open this post in threaded view
|

Re: Asciidoctor-diagram on Windows

mojavelinux
Administrator
In reply to this post by habamax
> Plus this is the second time for me when asciidoctor-diagram dev tells me that he has no windows to check the issue. Thus my conclusion that probably asciidoctor-diagram is not tested against windows.

I read the comment and Pepijn only said he didn't have time at that moment. Suffice to say, Asciidoctor Diagram is tested continuously on Windows. I provided a suggestion on that issue about how you could help him make the best use of time.

...and let's keep in mind this is all a volunteer project, so let's respect the time of the developers. If a developer says he/she doesn't have time to check the issue, then that's the constraint. Not the platform. Thanks for understanding!

Best,

-Dan

On Tue, Jan 7, 2020 at 12:29 PM habamax [via Asciidoctor :: Discussion] <[hidden email]> wrote:
> Let's focus on constructive suggestions, not conjecture..

Really sorry, I didn't mean to harm and insult here.

I've spent last 6 hours debugging this issue trying to find out the root cause... Plus this is the second time for me when asciidoctor-diagram dev tells me that he has no windows to check the issue. Thus my conclusion that probably asciidoctor-diagram is not tested against windows.

Again, sorry, didn't mean to sound offensive.


If you reply to this email, your message will be added to the discussion below:
https://discuss.asciidoctor.org/Asciidoctor-diagram-on-Windows-tp7443p7477.html
To start a new topic under Asciidoctor :: Discussion, email [hidden email]
To unsubscribe from Asciidoctor :: Discussion, click here.
NAML


--
Dan Allen | @mojavelinux | https://twitter.com/mojavelinux
Reply | Threaded
Open this post in threaded view
|

Re: Asciidoctor-diagram on Windows

habamax
In reply to this post by Nanook
The issue has been fixed with v 2.0.1 of asciidoctor-diagram.

Update your gem and it should work for you!

Thank you Pepijn for a fix!
Reply | Threaded
Open this post in threaded view
|

Re: Asciidoctor-diagram on Windows

mojavelinux
Administrator
Incredible!

-Dan

On Wed, Jan 8, 2020 at 4:17 AM habamax [via Asciidoctor :: Discussion] <[hidden email]> wrote:
The issue has been fixed with v 2.0.1 of asciidoctor-diagram.

Update your gem and it should work for you!

Thank you Pepijn for a fix!


If you reply to this email, your message will be added to the discussion below:
https://discuss.asciidoctor.org/Asciidoctor-diagram-on-Windows-tp7443p7480.html
To start a new topic under Asciidoctor :: Discussion, email [hidden email]
To unsubscribe from Asciidoctor :: Discussion, click here.
NAML


--
Dan Allen | @mojavelinux | https://twitter.com/mojavelinux
Reply | Threaded
Open this post in threaded view
|

Re: Asciidoctor-diagram on Windows

pwillard
You know what?  It doesn't work on Windows.  (It used to...)
 
It just encloses the DITAA in a default code block