asciidoctor / asciidoctor-kroki

Asciidoctor.js extension to convert diagrams to images using Kroki!
https://kroki.io/
MIT License
146 stars 47 forks source link

[Question] Shall kroki-server-url work when setting it externally? #149

Closed mariotoffia closed 3 years ago

mariotoffia commented 3 years ago

Hi, I'm using vs code and ascidoctor plugin with the kroki-server-url set in the settings and that works just fine!

{
  "asciidoc.use_kroki": true,
  "asciidoc.preview.attributes": {
    "kroki-server-url": "http://localhost:8000"
  }
}

I can see from the local server logs that it invokes the server locally. But when I want to use it in a Make file it seems not to accept the attribute kroki-server-url.

I'm doing the following:

@cd _design; node_modules/asciidoctor/bin/asciidoctor \
    -r asciidoctor-kroki \
    -r asciidoctor-highlight.js \
    -a revnumber="`git describe --tags`" \
    -a revdate="`git log -1 --format=%cd`" \
    -a revremark="`git log -1 --pretty=%B`" \
        -a kroki-server-url="http://localhost:8000" \
    go-core.adoc \
    -o ../_dist/_output/docs/go-core.html;cd -

Am I doing something wrong?

Cheers, Mario

mariotoffia commented 3 years ago

Hmm... need to investigate more before asking - I'm not sure that log and render correlates... caching?

ggrossetie commented 3 years ago

For reference, I can confirm that using -a kroki-server-url="http://localhost:8000" should work, if it's not please reopen.