Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(asciidoctor): handle metadata #191

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

nicorikken
Copy link
Contributor

Adds metadata handling to the asciidoctor task. The asciidoctor task will now:

  1. read asciidoctor attributes and add them as metadata
  2. expose metadata to the asciidoctor process as attributes

Both processes are executed independently from each other.

Adds metadata handling to the asciidoctor task. The asciidoctor task will now:
1. read asciidoctor attributes and add them as metadata
2. expose metadata to the asciidoctor process as attributes

Both processes are executed independently from each other.
@nicorikken
Copy link
Contributor Author

As promised (#100), a new Asciidoctor pull request, for handling metadata.

Some notes for review:

  • I added s protective function to prevent the asciidoc attributes from messing with the Perun framework (protect-meta). Am I missing some important keywords here?
  • I wasn't sure what metadata features I was to enable to the task options. Now you can opt for the asciidoctor* task instead of the asciidoctor task in order to leave out the yaml frontmatter parsing. But regardless the document attributes are exposed to Perun, and the Perun metadata is exposed to the asciidoctor conversion. There is a multitude of options here, so please shine your light on what makes sense.
  • This does not include any tests. I did do some tests on my local system though. Ideally I would make some small unit-tests in a separate file, but I wasn't able to add a separate file to the testing process. Perhaps I have to looker further into the workings of Boot.

@nicorikken
Copy link
Contributor Author

As mentioned I'm also working on getting asciidoctor-diagram to function. I'm aiming for the inline svg solution (asciidoctor/asciidoctor#1301) as a start, not having to deal with the Boot file handing. Somehow the JRuby container cannot access the binaries on my system for the actual image generation, so that'll take some more time. Similarly perhaps syntax highlighting will become a feature.

@allentiak allentiak self-requested a review February 28, 2019 05:02
Copy link
Contributor

@allentiak allentiak left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi, @nicorikken

Thanks for your hard work! Maybe this PR has never been merged because it lacks tests?
You may find useful links in #228.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants