Skip to content

Commit 1b69406

Browse files
authored
USAGE: howto set citation style using pandoc defaults
merges manubot/rootstock#338 closes manubot/rootstock#334
1 parent 2c28689 commit 1b69406

File tree

1 file changed

+15
-3
lines changed

1 file changed

+15
-3
lines changed

USAGE.md

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -272,9 +272,21 @@ Modifying the manuscript formatting requires modifying the CSS in the file [`bui
272272
Common formatting changes, such as [font size](https://github.com/manubot/rootstock/issues/239) and [double spacing](https://github.com/manubot/rootstock/issues/244), can be found by searching the [Rootstock issues](https://github.com/manubot/rootstock/issues).
273273
Open a [new issue](https://github.com/manubot/rootstock/issues/new) if you have a new formatting question.
274274

275-
Changing the citation style or which interactive HTML plugins are loaded requires editing the build script [`build/build.sh`](build/build.sh).
276-
The citation style is determined by the Citation Style Language file specified by `CSL_PATH`.
277-
It can be changed to use other existing styles as [described here](https://github.com/manubot/rootstock/issues/242#issuecomment-507688339).
275+
Changing the citation style or which interactive HTML plugins are loaded requires editing the options specified by Pandoc defaults files in [`build/pandoc-defaults`](build/pandoc-defaults).
276+
The citation style is determined by the Citation Style Language file specified in [`common.yaml`](build/pandoc-defaults/common.yaml):
277+
278+
```yaml
279+
metadata:
280+
csl: build/assets/style.csl
281+
```
282+
283+
The value for `metadata.csl` can be a URL, allowing access to thousands of existing styles hosted by [Zotero](https://www.zotero.org/styles) or the [CSL GitHub](https://github.com/citation-style-language/styles).
284+
For example, the following options replace the Manubot citation style with the _PeerJ_ style:
285+
286+
```yaml
287+
metadata:
288+
csl: https://github.com/citation-style-language/styles/raw/906cd6d43d0c136190ecfbb12f6af0ca794e3c5b/peerj.csl
289+
```
278290

279291
## Spellchecking
280292

0 commit comments

Comments
 (0)