{"action":"opened","issue":{"url":"https://api.github.com/repos/rstudio/rmarkdown/issues/1440","repository_url":"https://api.github.com/repos/rstudio/rmarkdown","labels_url":"https://api.github.com/repos/rstudio/rmarkdown/issues/1440/labels{/name}","comments_url":"https://api.github.com/repos/rstudio/rmarkdown/issues/1440/comments","events_url":"https://api.github.com/repos/rstudio/rmarkdown/issues/1440/events","html_url":"https://github.com/rstudio/rmarkdown/issues/1440","id":356933816,"node_id":"MDU6SXNzdWUzNTY5MzM4MTY=","number":1440,"title":"Remove quotes around metadata fields in pandoc args","user":{"login":"bearloga","id":1807519,"node_id":"MDQ6VXNlcjE4MDc1MTk=","avatar_url":"https://avatars1.githubusercontent.com/u/1807519?v=4","gravatar_id":"","url":"https://api.github.com/users/bearloga","html_url":"https://github.com/bearloga","followers_url":"https://api.github.com/users/bearloga/followers","following_url":"https://api.github.com/users/bearloga/following{/other_user}","gists_url":"https://api.github.com/users/bearloga/gists{/gist_id}","starred_url":"https://api.github.com/users/bearloga/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bearloga/subscriptions","organizations_url":"https://api.github.com/users/bearloga/orgs","repos_url":"https://api.github.com/users/bearloga/repos","events_url":"https://api.github.com/users/bearloga/events{/privacy}","received_events_url":"https://api.github.com/users/bearloga/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-09-04T18:53:37Z","updated_at":"2018-09-04T18:53:37Z","closed_at":null,"author_association":"CONTRIBUTOR","body":"If providing a metadata field to `pandoc_args`, the resulting command includes quotation marks which I'm *pretty sure* is what's making pandoc ignore it.\r\n\r\nSpecifically, I'm trying to make `nocite: '@*'` a default for my template so the end-user doesn't have to include it in their YAML in every single Rmd document (bearloga/wmf-product-analytics-report#1) and according to jgm/pandoc#4872 the way to do this is with:\r\n\r\n`pandoc -M nocite='@*'`\r\n\r\nand according to #409 maybe `pandoc --metadata=nocite:'@*'` could also be a way to do that.\r\n\r\nBut when I add `\"-M nocite='@*'\"` to `pandoc_args` or to `config$pandoc$args` e.g.:\r\n\r\n```\r\nconfig$pandoc$args <- c(pre_pandoc, wmfpar_args, \"-M nocite='@*'\")\r\n```\r\n\r\nthe pandoc call ends up looking like:\r\n\r\n```\r\n/usr/local/bin/pandoc +RTS -K512m -RTS skeleton.utf8.md\r\n  --to latex\r\n  --from markdown+autolink_bare_uris+ascii_identifiers+tex_math_single_backslash\r\n  --output skeleton.tex\r\n  --template …/library/memor/rmarkdown/templates/memor/resources/memor.tex\r\n  --highlight-style tango\r\n  --pdf-engine xelatex\r\n  --bibliography /var/…/wmfpar_rpkgs_c7f7211ee1bb.bib\r\n  --filter /usr/local/bin/pandoc-citeproc\r\n  --csl …/library/wmfpar/rmarkdown/templates/wmfpar/resources/apa.csl\r\n  --variable footer_on_first_page=yes\r\n  --variable fontsize=12pt\r\n  --variable geometry=margin=1in --variable subparagraph\r\n  --variable \"mainfont=Source Serif Pro\"\r\n  --include-in-header …/library/wmfpar/rmarkdown/templates/wmfpar/resources/preamble.tex\r\n  \"-M nocite='@*'\"\r\n```\r\n\r\n(newlines added for readability)\r\n\r\nEither rmarkdown is lacking support for metadata fields as args or I'm doing something wrong. Either way, please help :)"}}
{"actor":{"display_login":"bearloga"}}