Git Product home page Git Product logo

pandown's Introduction

Deprecation Warning

Abandon All Hope, Ye Who Enter Here

Proud as I was of Pandown when I put it together, at this point I can't really recommend you build your workflow around it. Not only is it old---I made the first commit in 2012, when Sublime Text was at major version 2---it's chock full of amateurish design problems---I was just picking up Python at the time, and wouldn't even start developing software professionally for another couple of years. Which is less about humility or perfectionism than about than about concern for the stability of your writing process.

Pandoc has seen a nontrivial amount of evolution over the past seven years, and Pandown isn't equipped to support it---you can't specify multiple filers through Pandown, for example, or multiple bibliography files. And although Pandown is more flexible than other Sublime Markdown packages were at the time, it still thinks about Pandoc in a fairly brittle way. Pandoc is very powerful, and Pandown's efforts to expose and manage its power are clumsy at best. Glitches and hacks that look small now are going to grow exponentially as Pandoc gets more evolved and packs in more power. And since I'm not a Sublime user anymore and there's no community momentum to channel towards support, eventually Pandown is going to stop functioning.

By comparison, John MacFarlane is by all evidence way smarter than I am---in general for starters, but in particular about how to usefully extend Pandoc. Ditto Jon Skinner with Sublime. Their work is going to be around much, much longer than Pandown. So it might be worth pouring your time into getting familiar with them, rather than my clumsy interface between them. On the dev and customization side, Pandoc's filters are very much the way of the future; on the integration side, Sublime's custom build systems (q.v. https://www.sublimetext.com/docs/3/build_systems.html and http://docs.sublimetext.info/en/latest/reference/build_systems/basics.html) should be easy enough to adapt to your particular workflow.

This is pretty much the path I wound up taking myself, first with Atom's build package and then VS Code's tasks. Wrapping a general-purpose build tool around my specific workflow was far easier and far more robust than trying to build and maintain a semi-general/semi-specific wrapper around Pandoc.

Godspeed, d


Pandown for Sublime Text 2 and 3

Introduction

This package is designed as a complete, versatile, and highly Subliminal Sublime Text 2 and Sublime Text 3 build wrapper for Pandoc version 1.10 or higher. Written by Daniel Shannon and inspired by jclement's Pandoc (Markdown) plugin, Pandown is intended to be simple and understandable out of the box but highly customizable behind the scenes. All Pandoc options are configurable, and all input and output formats are theoretically supported, with the Markdown reader implemented most completely and some support for the HTML reader.

Installation

Since this is just a build script, you'll need to download and install Pandoc version 1.10 or higher before it'll be of any use to you. The preferred installation method is through Sublime Package Control, but, you can also install it with the "Clone in Mac" and "Download ZIP" buttons above. Clone or copy it to your Packages folder and you'll be cooking with gas. You can also use the command line. The commands looks something like this:

cd <Sublime Packages Directory>
git clone git://github.com/phyllisstein/Pandown.git

Usage

A Markdown build system, which Pandoc extends in a number of interesting ways, is included with the package; open a Markdown file, set your build system to "Automatic" or "Pandown Markdown," and run the build command to generate, by default, an HTML file. Open the Command Palette and search for "Pandown" to see the other options available. Notably, if you have a LaTeX package installed, Pandoc can easily convert your Markdown into a lovely PDF; however, most of of the possible outputs have been pre-configured. A similar build system, though with fewer possible writers, is available for HTML.

The package also includes a special build command, accessible through the Command Palette: "Pandown: Build to Window". This mimics the behavior of most of the other Pandoc wrappers extant, in case you're married to it, and attempts to open a new, unsaved buffer with the results of a Pandoc build.

This is, of course, not very much fun: you wouldn't be using Sublime if you didn't want your workflow customized to the hilt, and you wouldn't be using Markdown if you wanted to see the frankly ugly page generated by default. Enter configuration and templates.

Configuration

You'll find menu items for Pandown's configuration files under "Preferences→Package Settings→Pandown". The Default package settings file is heavily and informatively commented, making it an excellent place to start. Make what changes you'd like in the User settings, which override the defaults, and they'll be reflected on your next build.

However, because so many of the arguments passed to Pandoc will change from project to project, Pandown features a second way to configure Pandoc. Clicking "Preferences→Package Settings→Pandown→Settings -- Project" or choosing "Pandown: Project Settings" in the Command Palette will place a file called pandoc-config.json in your current project folder. Setting the values for the pandoc_arguments dictionary there will override the settings in your sublime-settings files (though some values, notably lists and dictionaries, will be merged). If a config file does not exist in the same folder as the file you're building, Pandown will check the folders above it until it reaches a main project folder---that is, config files apply to the folder they're placed in and all its subfolders.

And this feature is extra-configurable: once you're familiar enough with the Pandoc options you care about to not need the complete set in each new project, you can place a pandoc-config.json file in your Packages/User folder and it, rather than the default file, will be copied. You can always delete it to restore the original behavior.

Only arguments to Pandoc and settings for Pandoc's Markdown extensions will be recognized in per-project configuration files.

Templates

The basic template from which Pandoc generates its HTML is just that: basic. And not very attractive. Without much trouble, you can do better on your own. For a non-designer and non-coder type, the stylesheets included with Brett Terpstra's wonderful Marked app are probably worth taking a look at; run an empty Markdown file through Marked and save it as HTML to get something that can become a lovely template file. (Brett has kindly made uncompressed versions of his CSS available here.)

Even more kindly, Brett has given the go-ahead for one of those templates to be distributed with this package. Consult the files in Packages/Pandown/Samples for a quickstart guide to building custom template files. The guide consists of a sample Markdown file, a sample template, a sample Pandoc configuration JSON, and the output HTML file generated from all those. Once you've played around with these files, you can use them for your own projects, too.

Critic Markup

Pandown includes basic for the Critic Markup syntax. By switching the "preprocess_critic" setting to true and adding the variable "critic": true to your Pandoc variables, you can compare changes and annotations against your original text in the constructed HTML file. Some JavaScript and HTML is added to the file that's built in that case, but it can be removed by deleting the critic key from your Pandoc variables. This is something of a quick-and-dirty implementation that will hopefully be developed somewhat more in the future.

Build Systems

In theory, the build command syntax supports all of Pandoc's possible from and to formats. In practice, I am but one man and haven't written and tested sublime-build settings for each and every one of them. Markdown is completely configured from the get-go, but if you wish to use another input language you'll need to write a sublime-build file. At minimum, it must contain the following:

  • The package's target. Include the line "target": "pandown_build".
  • Information about the language being built. Set pandoc_from to one of the input languages listed in the documentation.
  • Information about the default output. Set pandoc_to to a dictionary whose first item is one "to" languages listed in the documentation and whose second item is the file extension to output.

If the output file is not a type that Sublime can open, setting prevent_viewing to true will keep the script from trying to open it, even if the user's settings would normally cause it to do so.

Help and Support

If you have any difficulties with or suggestions for Pandown, please don't hesitate to get in touch. You can use the GitHub "Issues" interface, or send an e-mail to Daniel at d at daniel dot sh.

Thanks and Credits

The bare bones of the code were originally a modification of Pandoc (Markdown); though not much of what was there has survived, I'm grateful for the springboard. Almost all of the process-management code is from the Defaults/exec.py module. The package includes Gerald Storer's minify_json module, which is distributed under the MIT license and is obtainable here. Thanks to Gerald for working around Python's (and Douglas Crockford's) obdurate refusal to allow comments in JSON. I'm grateful to the Critic Markup project for allowing me to integrate their work into this package. Github user jareciog deserves a special high-five for catching a catastrophic bug under ST2. Brett Terpstra's generous permission to include his CSS with this package is appreciated above all.

pandown's People

Contributors

dflock avatar jcausey-astate avatar lionandoil avatar phyllisstein avatar randy3k avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

pandown's Issues

error running Pandown 3/26/13

Running up-to-date Pandown as of 3/26/13, and Pandoc 1.11.1. Win 7, ST 2, build 2217.

When running any Pandown command, receive an error "Pandown requires Pandoc". The console shows the following:

[Pandown: Exception: environment can only contain strings]
error: Pandown requires Pandoc

Looks like I'm getting an error here

def checkPandoc(self, env):
    cmd = ['pandoc', '--version']
    try:
        output = subprocess.check_call(cmd, env=env)
    except Exception as e:
        err("Exception: " + str(e))
        return False

pandoc-crossref not working

I have an issue using pandoc-crossref (http://lierdakil.github.io/pandoc-crossref/) as a filter. It can be added using "filter": "pandoc-crossref" or "filter": ["pandoc-crossref"] in the pandoc-config.json. However, there seems to be some preprocessing that escapes some of the crossref syntax. A simple example would be using an image in Markdown with crossref-specific options:

![](some_image.png){#fig:image width=10%}

which includes the image but escapes the curly braces, so crossref cannot interpret them any more as parameters. This is visible when doing latex output, where the output is as follows:

\includegraphics{some_image.png}\{\#fig:image width=10\%\}

I suspect something with citations to get in the way, because the documentation warns about the order of applying citeproc and crossref (first crossref, then citeproc). I do not understand the pandown codebase yet, otherwise I would open a pull request.

TypeError: Can't convert 'bool' object to str implicitly on Windows

When trying to build a file with Pandown (regardless of the output file format), I'm getting the following errors in the console:

Traceback (most recent call last):
  File "C:\Program Files\Sublime Text 3\sublime_plugin.py", line 533, in run_
    return self.run(**args)
  File "pandownBuildCommand in C:\Users\deni\AppData\Roaming\Sublime Text 3\Installed Packages\Pandown.sublime-package", line 97, in run
  File "pandownBuildCommand in C:\Users\deni\AppData\Roaming\Sublime Text 3\Installed Packages\Pandown.sublime-package", line 365, in buildPandocCmd
TypeError: Can't convert 'bool' object to str implicitly

My configuration:
Windows 8.1 Polish version
Sublime Text 3 build 3083

regards,
Darek

Pandown freezes Sublime

I recently update to Pandoc 1.10.1 and now anytime I try to build a document in Sublime with Pandown it cause Sublime to freeze up and must be forced closed.

Ubuntu 12.04
Sublime 2.0.1
Pandoc 1.10.1 installed through cabal
Pandown installed through Package Control

Add support for --toc-depth

There doesn't currently seem to be a way of setting --toc-depth as one of the command_line arguments -- would it be possible to add this?

James

Pandown is not working with pandoc version<2.0

After the last update, Pandown is not working with pandoc version<2.0. Maybe readme.md should be updated with this fact (it still talks about version >=1.10.

Pandoc update solves the problem on MacOSX. However, project config files should be updated removing "normalization", "smart" and "parse-raw" entries.

On Windows, however, the problem persists even after updating pandoc and even removing old project config files. The log displays the following message:

--parse-raw/-R has been removed. Use +raw_html or +raw_tex extension.

--smart/-S has been removed.  Use +smart or -smart extension instead.
For example: pandoc -f markdown+smart -t markdown-smart.
--normalize has been removed.  Normalization is now automatic.
Try pandoc --help for more information.

Pandown freezes sublime

Ubuntu 12.04.3
Sublime Text 2 Build 2221
Pandoc 1.12.1 installed through cabal
Pandown installed through Package Control

Relative File Paths

Thanks for the great plugin! I am having trouble specifying relative paths in the pandoc-config.json file. Specifically, I would like to use "/path/to/file/" for csl and bibliography files. I was having a difficult time getting it to accept a relative reference to a template file, but I finally got that to work when I realized I had to specify "template.latex" and not just "template" as pandoc takes in the command line. I am not a programer, but in digging through the code, it appears that the relative reference works in template because it passes through walkIncludes, which performs os.path.expanduser on it. However, it appears csl and bibliography options are passed straight through so they end up as "--csl=/path/to/file" which pandoc doesn't like.

I can overcome this by placing the .csl and .bib files in the working directory, but I prefer to keep the build files separated from the .md files.

Any help you can provide would be appreciated. Thanks so much!

Incompatibility with current Package Control on ST3?

I installed Pandown with Package Control[1]. It places a Pandown.sublime-package in /Installed Packages. But reading your pandownTouchProjectConfigCommand.py, you expect os.path.join(sublime.packages_path(), 'Pandown') is an existing directory, where sublime.packages_path() is data-path/Packages. If I understand correctly, it was the policy of ST2 to expand packages there but it has changed with ST3 which prefers to keep the packages as archives in "Installed Packages". So basically, as it stands, I don't see how your code can work with ST3 and Package Control. Users shall install Pandown by hand in data-path/Packages for it to work correctly. I have no idea how to fix the package to work around that problem but at least, meanwhile, you should update the documentation to clarify that point.

Am I missing something?

[1] I installed Package Control by cloning its git repo and checking out the python3 branch: head is May 7, 158717034335b075d45fc6f13dcf2bdbdc5edf8c.

Building from multiple files

Hi,

this for now is too complex for me, is it possible to configure build to run on multiple files in the project? For example if I'm writing book with multiple chapters in separate files ch1.md, ch2.md, ...

Thanks for all the work,
Nikola

Issue with ATX headers

When I set the preference to force ATX headers to 'true' and then build in markdown the build process seems to clip all the headers off so that there are no ATX headers at all. The text of the header is still there, so that if I wanted to see ##H2 all I get post-build is H2. Is this a bug?

Reveal.js not available

Hi,
Thank you for this nice job.
Could it be possible to add to the available transformations the Markdown to Reveal.js one.
Thanks.
Emmanuel.

Beamer slides and templates

I regularly generate beamer slides from markdown for teaching, and I like to use a specific pandoc template with several key:value pairs. But I don't want to use this template for markdown docs in the project folder all the time, just for when I generate slides. Is there a way to make templates specific to particular build systems in Pandown? Apologies if this is already detailed in the README and I've just missed it.

Latest commit breaks ST2 under windows

As noted in commit comment, this fix broke operation for me with ST2 under Windows. I would get this error:

[Pandown: Exception: [Error 2] The system cannot find the file specified]
error: Pandown requires Pandoc

Reverting this fixed my issue.

Is it possible to configure a previewer in the build system?

Hi, pandown is awesome. Thanks.

I am currently using Pandown mainly for generating md -> pdf via xelatex and it works smoothly. The only thing that is missing in my workflow is an automated preview of the result. Is there a chance to call a previewer (Adobe or Browser) from within the build process? Thanks

suspected conflict with bibliography metadata and sublime-settings

When using citations in a pandown-md doc, the citations and bibliography are successfully generated when I point the pandown.sublime-settings to a .bib file thus:

"bibliography": "bibliography.bib"

But I don't get success when I comment-out that line and replace it with metadata at the front of my md file:


---
title: some doc
author: Who
date: 1 Jan 2009
bibliography: bibliography.bib

...

It seems I am forced to use the pandown.sublime-settings to specify the bib file. Interestingly, the .csl file can be specified either in the settings file or in the metadata, and both work.

tim

Bibtex citations does not work

Hi,

I have tried to get citations work with pandown in ST2 but it does not work. I have a configuration file: pandoc-config.json int the same directory than the source file:
{
"pandoc_arguments":
{
//////////////////////////////////////////////////////////////////////
// Arguments are explained in Pandoc's documentation: //
// http://johnmacfarlane.net/pandoc/README.html . //
// The contents of this file will be merged with the package's //
// Pandown.sublime-settings file, the user's Pandown.sublime-settings/
// file, and local project settings, with what's specified here //
// taking precedence. For more information about how to use this //
// file, please see the Pandown README. //
//////////////////////////////////////////////////////////////////////
"markdown_extensions":
{
/////////////////////////
// MARKDOWN EXTENSIONS //
/////////////////////////
// A backslash followed by a newline is also a line break.
"escaped_line_breaks": true,

        // Require a blank line before a header.
        "blank_before_header": true,

        // Headers can be assigned attributes using this syntax at the end of
        // the line containing the header text:
        // {#identifier .class .class key=value key=value}
        "header_attributes": true,

        // A header without specified attributes will automatically be assigned
        // a unique identifier based on the header text.
        "auto_identifiers": true,

        // Pandoc assumes header references have been defined for each header.
        "implicit_header_references": true,

        // Require a blank line before block quotes. In nested blockquotes,
        // require:
        // > Quotation
        // >
        // > > Quotation within quotation.
        "blank_before_blockquote": true,

        // Fence code blocks off with tildes or backticks.
        "fenced_code_blocks": true,

        // Start lines with pipe characters to and the division into lines and
        // leading whitespace will be preserved. Useful for setting verse and
        // addresses.
        "line_blocks": true,

        // Pandoc allows fancier numbering using uppercase letters, lowercase
        // letters and Roman numerals. List markers may be enclosed in parentheses
        // or followed by a single right-parenthesis or period, then two spaces.
        "fancy_lists": true,

        // Pandoc will pay attention to the starting number for each list.
        "startnum": true,

        // Pandoc supports definition lists; see documentation here for the
        // correct syntax: http://johnmacfarlane.net/pandoc/README.html#definition-lists
        "definition_lists": true,

        // The list marker (@) can be used to sequentially number examples in
        // a way that persists throughout the document.
        "example_lists": true,

        // Pandoc supports four kinds of tables, the syntax for which is given at:
        // http://johnmacfarlane.net/pandoc/README.html#tables.
        "simple_tables": true,
        "multiline_tables": true,
        "grid_tables": true,
        "pipe_tables": true,

        // A table caption is a paragraph beginning with the string "Table:" or a
        // colon alone. It may be placed at the beginning or end of a table.
        "table_captions": true,

        // Pandoc allows the inclusion of a title block that will not appear in
        // the body of the document:
        // % Title
        // % Author(s) (separated by semicolons)
        // % Date
        "pandoc_title_block": true,

        // A backslash may be used to escape any Markdown symbol.
        "all_symbols_escapable": true,

        // Using underscores within a word for emphasis is disabled by
        // default. Use * instead.
        "intraword_underscores": false,

        // To strike letters in your text, surround them with ~~two tildes~~.
        "strikeout": true,

        // Superscripts may be written by surrounding text with ^ characters,
        // subscripts by surrounding text with ~ characters. Escape spaces within
        // scripts using \ .
        "superscript": true,
        "subscript": true,

        // Add attribtues, including syntax highlighting, to inline code.
        "inline_code_attributes": true,

        // Text between two $ characters will be rendered as LaTeX math.
        "tex_math_dollars": true,

        // The default behavior in Markdown allows you to insert raw HTML
        // anywhere in a document.
        "raw_html": true,

        // By default, Pandoc interprets Markdown in blocks of HTML as Markdown.
        // This deviates from Markdown.pl's default behavior.
        "markdown_in_html_blocks": true,

        // Pandoc allows raw TeX to be passed in addition to raw HTML.
        "raw_tex": true,

        // If set to `true`, Pandoc will use \newcommand and \renewcommand
        // definitions in all LaTeX math blocks.
        "latex_macros": true,

        // An image occurring by itself in a paragraph will be rendered as a
        // figure with a caption: ![This is the caption](path/to/image.jpg)
        "implicit_figures": true,

        // Pandoc will parse footnotes in the syntax listed here:
        // http://johnmacfarlane.net/pandoc/README.html#footnotes
        "footnotes": true,
        "inline_notes": true,

        // Use the syntax given here for citations:
        // http://johnmacfarlane.net/pandoc/README.html#citations
        "citations": true,

        // All newlines within a paragraph will be interpreted as linebreaks
        // rather than spaces.
        "hard_line_breaks": false,

        // Anything between \( and \) will be interpreted as TeX inline math,
        // and anything between \[ and \] as TeX display math.
        "tex_math_single_backslash": false,

        // Same as above, but escaped with two backslashes.
        "tex_math_double_backslash": false,

        // Markdown is only parsed within block-level tags if `markdown=1` is
        // set in their attributes.
        "markdown_attribute": false,

        // Enables a MultiMarkdown-style title block:
        // Title:    My Title
        // Author:   Arthur Author
        // Date:     January 1, 2013
        // Comment:  This is a mmd title block, and it even includes
        //           a field spanning multiple lines.
        "mmd_title_block": false,

        // Skip PHP Markdown Extra abbreviation keys instead of parsing them
        // as paragraphs if set to `true`.
        "abbreviations": false,

        // Makes all absolute URLs into links, even when not enclosed in <...>.
        "autolink_bare_uris": false,

        // Parse (but ignore, at the moment) MMD-style key--value attribtues
        // in image and link references.
        "link_attributes": false,

        // Parses MMD-style header identifiers (in square brackets between header
        // text and closing ATX #s.
        "mmd_header_identifiers": false
    },




    "command_arguments":
    {
        ////////////////////////////
        // COMMAND-LINE ARGUMENTS //
        ////////////////////////////
        // Modify this setting to tell Pandoc to look for any of the following
        // in the specified directory rather than ~/.pandoc or Pandoc's default
        // directory tree. Note that this is not an all-purpose includes
        // directory---Pandoc will only look for these files and folders.
        //      data_dir/
        //          reference.odt
        //          reference.docx
        //          default.csl
        //          epub.css
        //          slidy/
        //          slideous/
        //          s5/
        //          templates/
        // Anything placed under templates and will be found by the "template"
        // setting; otherwise, to set an include directory, use the "includes_paths"
        // option above.
        "data-dir": "",

        // "Parse untranslatable HTML codes and LaTeX environments as
        // raw HTML or LaTeX, instead of ignoring them."
        "parse-raw": true,

        // Straight quotes into curly quotes, --- to em-dash, -- to en-dash,
        // ... to ellipsis, nonbreaking spaces after certain abbreviations.
        "smart": true,

        // - before a numeral to en-dash, -- to em-dash
        "old-dashes": false,

        // "Speficy the base level for headers"
        // Specify a number or "false" to disable.
        "base-header-level": false,

        // Apply code classes to all indented code blocks. N.B.:
        // does not apply to fenced code, which must still be
        // configured inline.
        // MUST BE DEFINED AS A LIST, EVEN IF EMPTY. This is correct:
        //      "indented-code-classes": [],
        // and so is this:
        //      "indented-code-classes": [ "numberLines" ],
        // but this is not:
        //      "indented-code-classes": "numberLines"
        "indented-code-classes":
        [
        ],

        // When image paths or URLs have no extension, this one
        // will be used.
        "default-image-extension": "",

        // Merge adjacent elements, remove repeated spaces, etc.
        "normalize": true,

        // Set the number of spaces per tab. Should be set to
        // "false" (for default behavior) or a number.
        "tab-stop": false,

        // Generate "an appropriate header and footer"
        "standalone": true,

        // Use a template file other than the default to
        // generate output. Pandoc will look for a template in the
        // working directory, then data_dir/templates/, then its
        // built-in directory tree.
        // See Pandoc's README for information about templates:
        // http://johnmacfarlane.net/pandoc/README.html#templates
        "template": "",

        // Supply a dict of keys and values to be passed to
        // the template file. Values may be lists
        // if your template includes loops; see this plugin's README.
        "variables":
        {
        },

        // By default, text is wrapped for the output format.
        "no-wrap": false,

        // If wrapping text, wrap to "columns" columns.
        // Specify a number or "false" to disable.
        "columns": false,

        // Generate and include a table of contents.
        "table-of-contents": false,

        // The number of section levels to include in the table of contents.
        // Specify a number or "false" for default (3).
        "toc-depth": false,

        // Disable syntax highlighting globally.
        "no-highlight": false,

        // Style to use for syntax highlighting.
        // Valid highlight_style values:
        // "pygments" (default), "kate", "monochrome",
        // "espresso", "zenburn", "haddock", "tango"
        "highlight-style": "pygments",


        // Supply lists of files---NOT single file names---to include verbatim in the output.
        // This is correct:
        //          "include_in_header": [ "myfile" ]
        // and this is not:
        //          "include_in_header": "myfile"
        // Default templates support multiple includes.
        // Insert just before </head>
        "include-in-header": [],
        // Insert just after <body>
        "include-before-body": [],
        // Insert includes just before </body>
        "include-after-body": [],

        // Convert includes to 'data:' URIs so that the
        // output can be viewed offline.
        "self-contained": false,

        // Use <q> tags for quotes in HTML5 output
        "html-q-tags": false,

        // In HTML output ONLY, restrict to ASCII characters
        // with numerical HTML entities.
        "ascii": false,

        // When outputting Markdown, use reference-style links (e.g. [go here!][1])
        // rather than inline (e.g. [go here!](http://place.the) ).
        "reference-links": false,

        // Force use of ATX-style headers ("# H1", "## H2", etc.) in output.
        // The default is to use a combination, with setext-style headers:
        // H1
        // ===
        //
        // for H1 and H2, then ATX.
        "atx-headers": false,

        // Top-level headers become TeX/Docbook chapters.
        "chapters": false,

        // Generate section numbers.
        "number-sections": false,

        // Sections in HTML output can be offset by a fixed number.
        // The first number is added to the output for top-level
        // headings, the second number to second-level headings,
        // etc. Must be specified as a list.
        "number-offset":
        [
        ],

        // "Do not convert quotation marks, apostrophes, and dashes to the TeX ligatures"
        "no-tex-ligatures": false,

        // Use listings package for TeX code
        "listings": false,

        // In slideshow output, display list items one slide at a time.
        "incremental": false,

        // Header level at which to break slides. Above breaks sections, below
        // creates subheads. Normally set based on context of document.
        // See: http://johnmacfarlane.net/pandoc/README.html#structuring-the-slide-show
        // Set to a number or "false" to disable.
        "slide-level": false,

        // Enclose sections in <div> or <section> tags, attach "id" attributes based on
        // the section name.
        "section-divs": false,

        // Conceal mailto: links from robots.
        // Acceptable values: "none", "javascript", "references"
        "email-obfuscation": "references",

        // "Specify a prefix to be added to all automatically generated identifiers
        // in HTML output. This is useful for preventing duplicate identifiers when
        // generating fragments to be included in other pages."
        "id-prefix": "",

        // Insert a string before the header title tag but not the body title
        "title-prefix": "",

        // Link to any number of CSS stylesheets
        // without triggering the standalone include features.
        "css":
        [
            "github.css"
        ],

        // "Use the specified file as a style reference in producing a [desired] file.
        // For best results, the reference [file] should be a modified version of
        // a [desired] file produced using pandoc."
        "reference-odt": "",
        "reference-docx": "",

        // "Use the specified CSS file to style the EPUB. If no stylesheet is specified,
        // pandoc will look for a file epub.css in the user data directory (see --data-dir).
        // If it is not found there, sensible defaults will be used."
        "epub-stylesheet": "",

        // Set cover to a specified image.
        "epub-coverimage": "",

        // Link to an XML file containing EPUB metadata in Dublin Core Elements format.
        // See http://dublincore.org/documents/dces/
        "epub-metadata": "",

        // Use the stylesheet specified to embed fonts. Should contain a series of
        // @font-face elements and CSS describing where they're to be used.
        "epub-embed-font": "",

        // Appropriate values: "pdflatex" (default), "xelatex", "lulalatex"
        "latex-engine": "",

        // Specify bibliography database to be used in resolving citations. The database
        // type will be determined from the extension of FILE, which may be .mods (MODS format),
        // .bib (BibTeX/BibLaTeX format), .ris (RIS format), .enl (EndNote format), .xml (EndNote XML format),
        // .wos (ISI format), .medline (MEDLINE format), .copac (Copac format), or .json (citeproc JSON).
        // If you want to use multiple bibliographies, just use this option repeatedly.
        "bibliography": "paper_rings_multiblob/multiblobbed_rings.bib",

        // Link to a CSL (http://citationstyles.org) file for formatting citations.
        "csl": "american-physics-society.csl",

        // "Specify a file containing abbreviations for journal titles and other
        // bibliographic fields (indicated by setting form="short" in the CSL node
        // for the field). The format is described at
        // http://citationstylist.org/2011/10/19/abbreviations-for-zotero-test-release/"
        "citation-abbreviations": "",

        // Use natbib for LaTeX citations.
        "natbib": false,

        // Use BibLaTeX for LaTeX citations.
        "biblatex": true,


        // Place TeX math between <eq> tags in HTML output.
        "gladtex": false,

        // Each of the following can be false, true, or a URL string.
        // Setting to a URL string implies true.
        // Use http://math.etsu.edu/LaTeXMathML/ to format TeX math. If no URL
        // is specified, Pandoc will insert the code for you.
        "latexmathml": false,
        // Convert TeX math to MathML and include a JavaScript to display.
        "mathml": false,
        // Use http://www.math.union.edu/~dpvc/jsmath/ for TeX math. URL must point
        // to its load script, which will not be automatically added by Pandoc.
        "jsmath": false,
        // Use http://www.mathjax.org/ for TeX math. URL must point to MathJax.jds
        // load script. If no URL is provided, Pandoc script will add one.
        "mathjax": true,
        // Render TeX math with mimetex (http://www.forkosh.com/mimetex.html). If no
        // URL is supplied, /cgi-bin/mimetex.cgi is assumed.
        "mimetex": false,
        // Render TeX formulas using an external script that converts TeX formulas
        // to images. The formula will be concatenated with the URL provided.
        // If URL is not specified, the Google Chart API will be used.
        "webtex": false
    }
}

}

As you can see I have activated biblatex and set the bibtex file (paper_rings_multiblob/multiblobbed_rings.bib) and style (american-physics-society.csl), but seems the command is not right parse. I try on the command line this command:

$ pandoc intro.md --biblio paper_rings_multiblob/multiblobbed_rings.bib --csl american-physics-society.csl -o test.html

and it works quite well, so I think it is a problem of the command construction.

Could you help me?

Thanks in advance.

Filters

Unless I've missed it, there's no way to use a Pandoc filter with Pandown, like having --filter=foo.py on the command line. I would quite like to be able to.

Setting install_path doesn't work on Linux

I'm on Ubuntu 13.04. I have both older version of Pandoc in /usr/local/bin, and a newer version in ~/.cabal/bin. I'd like Pandown to use the newer version. According to the settings file, I should be able to set the variable install_path to ~/.cabal/bin, but doing seems to have no effect. Pandown still calls the version in /usr/local/bin.

James

What is the format for "pandoc_arguments"

Hi

I would like to add the arguments that I use when I invoke Pandoc in the Terminal to the pandoc-config.json file for my project, but I'm not sure how to format them. Here is what the start of the file looks like:

{
    "pandoc_arguments": 
    {
        "-o ~/Dropbox/publications/JJKC/Rig.pdf"
        "--bibliography ~/Dropbox/Notes/nnstanp2grepbtf.bib"
        "--csl ~/Dropbox/Notes/modern-humanities-research-association.csl"
        "--latex-engine=/usr/texbin/xelatex"
        "-V geometry:margin=1in"
        "-V mainfont='Minion Pro'"
        //////////////////////////////////////////////////////////////////////
        // Arguments are explained in Pandoc's documentation:               //

I have Build System set to Pandown Markdown. But when I hit Build I get this error:

Pandown: Error constructing Pandoc command.

These arguments work fine in the Terminal. I guess I've not formatted the arguments correctly, but any pointers as to what's going wrong would be helpful (perhaps the json file should have some examples of how to format arguments in the comments?)

How to change the output type?

I know I have successfully changed the output format in the past to 'mediawiki' unfortunately, I can't remember how I did it and the documentation is a bit obtuse to me.

Could we for posterity explain how one would change the output of Pandown from html to mediawiki?

Thanks, for any help

"Console" is opened everytime I run pandown

Whenever I run pandown, a little "console" (it's not called that, but I don't know the name…) is displayed, even when no output in that window is generated. I would like pandown to not open up this console pane, if it has nothing to show. Is that possible?

Windows-specific settings for Pandown

Is there any way to have a different .sublime-settings file for Windows and Mac?

I tried renaming the settings files to Pandown (Windows).sublime-settings, Pandown (OSX).sublime-settings, but this didn't seem to work.

Thanks!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.