Format and Print (with Marked 2 app)
- Write in Markdown and use Marked 2 to style output files (pdf, docx, or html).
- Choose your citation style file (csl)
- Use a css template to style the texts (special attention to references)
I use Marked 2 app (sorry, Mac only) to convert Markdown files and format the output files according to my needs. Long story short, Marked 2 converts a Markdown file into HTML document file, which in turn gets formatted according to a chosen CSS template.
CSS is a language that describes the style of an HTML document. CSS describes how HTML elements should be displayed.
Choose the Right Style
Also, I have created additional templates for academic writing.
You can download these CSS templates here:
- Chicago Academic.css: based on The Chicago Manual of Style
- AMJ Academic.css: based on the [Academy of Management Journal Style Guide for Authors] (http://aom.org/publications/amj/styleguide/). The library at the University of Queensland also provides a useful guide to AMJ referencing style.
- Academic CV.css
- Academic Review.css: based on Academy of Management’s Reviewer Guidelines, particularly the Sample Review by Macro Editor. I also use this for reading summary/notes.
Check out the codes of Chicago Academic.css, which is based on The Chicago Manual of Style. There is a section for formatting output of pandoc-citeproc. In my case, I use hanging indent, which is also used by APA style. Feel free to adjust the style according to your needs.
Print and Share
As many academic researchers usually read papers in PDF format and write with Microsoft Word. To share my writing, I then convert my writing into PDF or DOCX format.
Print to PDF
When you are ready, you can export your files in HTML format out of the Marked 2 app. Then you can print the HTML with your browser app.
Print to DOCX
Similarly, you can open the HTML files with Microsoft Word or other word processors. Then, you can save the HTML file in the DOCX format.
However, the page margins will likely be changed to the default setting for new documents. For example, I set the default margins of 1 inch for all new documents created in Microsoft Word.
Citation and References
TL;DR: Marked 2 App -> Preferences -> Advanced Set Path to:
/usr/local/bin/pandoc Set Args to:
-f markdown+smart -t html5 --filter=/usr/local/bin/pandoc-citeproc --bibliography ~/Zotero/Library.bib --csl ~/Documents/Zotero/Pandoc/CSL/amj.csl
Cite-while-you-write (CWYW) is the important step in academic writing. A good setup can make writing with Markdown and formatting with Marked 2 app much more rewarding.
The following posts have been essential for me to set up my CWYW workflow.
- davepwsmith - Academic writing with Scrivener, Zotero, Pandoc and Marked 2
- davepwsmith - Academic writing: Scrivener, Zotero, Pandoc, Marked 2
- Ralph Kabo - My workflow for transforming academic Markdown into beautiful Word documents
Ralph Kabo has developed DocDown, a native macOS app, to convert markdown files into Word documents. DocDown can use an existing Word document as the output template. It is a great solution for anyone looking to convert Markdown into Word documents on a regular basis.
Cite-while-you-write (CWYW) Solution 1: ZotHero via Alfred
Generate “References/Bibliography” with Marked 2 app
- Zotero with BetterBibTex
- Pandoc and pandoc-citeproc
- Citation Style Language (CSL) file for the reference style of your choice. Preview and download at the Zotero Style Repository.
Marked 2 needs to be configured so that the “BibTex citekey” in the texts can be recognized. Also, this will create the corresponding references/bibliography section for your paper/manuscript.
To setup Marked 2 for processing the citations in your writing, you then navigate to the “Advanced” tab in “Preferences” and fill out the following:
- Check “Enable Custom Processor”
- Find the folder location of Pandoc on your machine (usually something like /usr/local/bin/pandoc) and make sure you have also installed pandoc-citeproc
- Paste the folder location in “Path”
- Find the path of Zotero library export (BibTex format)
- Find the path of the referencing style file (CSL format)
- Put the following in the “Args”:
-f markdown+smart -t html5 --filter=/usr/local/bin/pandoc-citeproc --bibliography [Zotero Library location from Step 4] --csl [CSL file location from step 5]
- On my machine, it looks like this:
-f markdown+smart -t html5 --filter=/usr/local/bin/pandoc-citeproc --bibliography /Users/xulelin/Documents/Zotero/Library.bib --csl /Users/xulelin/Documents/Zotero/Pandoc/CSL/amj.csl
Issues and Limitations
Export to Word documents with Marked 2
Marked 2 app seems to have issues with exporting files into Word documents. The formats defined by CSL files can be lost.
Solution 1: Export to HTML files and then open HTML file with Word. Then you can save to Word documents.
Solution 2: Use DocDown developed by Ralph Kabo. DocDown automates the conversion from Markdown to Word documents.