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

Allow generic Pandoc options with :args #535

Merged
merged 2 commits into from Mar 7, 2015

Conversation

denisdefreyne
Copy link
Member

Potential fix for #526.

It is now possible to call Pandoc like this:

filter :pandoc, args: [:s, {:f => :markdown, :to => :html}, 'no-wrap', :toc]

I don’t think this breaks backwards compatibility, even though the filter’s method signature has changed, because it was never possible to call the filter in a different way.

CC @ghiknt

@denisdefreyne
Copy link
Member Author

CC @nanoc/contributors — would like a +1

@ghiknt
Copy link

ghiknt commented Mar 7, 2015

Gladly. I have manually patched against 3.7.5 using your diff and it works great. Where do I +1?

@denisdefreyne
Copy link
Member Author

Leaving a comment that says :+1: works!

I just realised that the documentation isn’t up-to-date. Will fix now.

@ghiknt
Copy link

ghiknt commented Mar 7, 2015

👍

@denisdefreyne
Copy link
Member Author

The documentation is now updated. I’ve marked the :args approach as recommended, since it’s the most flexible and matches closely the way one would invoke Pandoc from the command line.

Are you OK with the documentation?

@denisdefreyne
Copy link
Member Author

screen shot 2015-03-07 at 16 34 16

@ghiknt
Copy link

ghiknt commented Mar 7, 2015

Looks good to me. My test/use case is:

opts = [{:to => :html5,
        'base-header-level' => 2,
        :filter => 'pandoc-citeproc',
        'data-dir' => 'content/about/bibliography/',
        :bibliography => 'content/about/bibliography/whk.name.bib',
        :csl => 'content/about/bibliography/chicago-annotated-bibliography.csl'
       }, 'section-divs']
filter :pandoc, :args => opts  

Which I would have been able to develop from the new docs.

denisdefreyne added a commit that referenced this pull request Mar 7, 2015
Allow generic Pandoc options with :args
@denisdefreyne denisdefreyne merged commit a06c5f6 into release-3.7.x Mar 7, 2015
@denisdefreyne denisdefreyne deleted the generic-pandoc-options branch March 7, 2015 15:46
@denisdefreyne denisdefreyne added this to the 3.7.6 milestone Apr 19, 2015
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.

None yet

2 participants