forked from tbfisher/sublimetext-Pandoc
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Pandoc.sublime-settings
167 lines (152 loc) · 5.24 KB
/
Pandoc.sublime-settings
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
{
// There are 2 possible top level settings keys, "user" and "default". If you
// use "default" in your user settings file, the default settings will be
// overwritten, but if you use "user" your settings will be merged into the
// default settings.
"default": {
// path to the pandoc binary. Default locations per platform:
// - mac
// "pandoc-path": "/usr/local/bin/pandoc",
// - windows
// "pandoc-path": "C:/Users/[username]/AppData/Local/Pandoc/pandoc.exe",
"pandoc-path": null,
// transformations
"transformations": {
// label of transformation, to appear in sublime quick panel. This should
// be a name related to the format of the output.
"Markdown (Pandoc)": {
// Opens output in new buffer (instead of replacing input in same buffer)
"new-buffer": 1,
// maps sublime scope to input format. If the input matches against the
// given scope, this transformation becomes available, and the input
// format is used as the pandoc --from option.
// @see http://docs.sublimetext.info/en/latest/extensibility/syntaxdefs.html#scopes
// @see score_selector() http://www.sublimetext.com/docs/3/api_reference.html
// @see http://johnmacfarlane.net/pandoc/README.html#options
"scope": {
"text.html": "html"
},
// sublime syntax file of output format, will set output to this syntax
"syntax_file": "Packages/Markdown/Markdown.tmLanguage",
// additional arguments passed to pandoc
// - --from is automatically set, see "scope" above
// - --to=FORMAT or one of its aliases is required
// @see http://johnmacfarlane.net/pandoc/README.html#options
"pandoc-arguments": [
"--to=markdown",
"--wrap=none",
"--atx-headers"
]
},
"HTML 5": {
"new-buffer": 1,
"scope": {
"text.html.markdown": "markdown"
},
"syntax_file": "Packages/HTML/HTML.tmLanguage",
"pandoc-arguments": [
"--to=html5",
"--no-highlight"
]
},
// note these are examples of output formats that should not be opened in a
// sublime text buffer. See "pandoc-format-file" below
// @see http://johnmacfarlane.net/pandoc/README.html#creating-a-pdf
"PDF": {
"scope": {
"text.html": "html",
"text.html.markdown": "markdown"
},
"pandoc-arguments": [
"-t", "pdf"
// use --latex-engine=engine where engine is
// pdflatex|lualatex|xelatex. This may need to be specified with a
// full path, e.g. on a mac with BasicTeX
// "--latex-engine=/usr/texbin/pdflatex"
// or on Windows with MiKTeX
// "--latex-engine=C:/Program Files (x86)/MiKTeX 2.9/miktex/bin/pdflatex.exe"
// if -o or --output missing, will write to a temporary file
// "--output=~/Downloads/output.pdf"
]
},
"Microsoft Word": {
"scope": {
"text.html": "html",
"text.html.markdown": "markdown"
},
"pandoc-arguments": [
"-t", "docx"
// if -o or --output missing, will write to a temporary file
// "--output=~/Downloads/output.pdf"
]
},
"PDF TOC (Narrow margins)": {
"scope": {
"text.html": "html",
"text.html.markdown": "markdown",
},
"pandoc-arguments": [
"-V", "geometry:margin=1.25in",
"-s", "--toc", "--number-sections", "--parse-raw",
"-t", "pdf",
],
},
"PDF TOC": {
"scope": {
"text.html": "html",
"text.html.markdown": "markdown",
},
"pandoc-arguments": [
"-s", "--toc", "--number-sections", "--parse-raw",
"-t", "pdf",
],
},
"HTML TOC": {
"new-buffer": 1,
"scope": {
"text.html.markdown": "markdown"
},
"syntax_file": "Packages/HTML/HTML.tmLanguage",
"pandoc-arguments": [
"--to=html5",
"--no-highlight",
"-s", "--toc"
]
},
"Beamer Slides (PDF)": {
"scope": {
"text.html": "html",
"text.html.markdown": "markdown",
},
// Use the "out-ext" parameter to define a custom output file extension. Commonly used for pdf.
"out-ext": "pdf",
"pandoc-arguments": [
"-t", "beamer",
"--latex-engine=C:/Program Files (x86)/MiKTeX 2.9/miktex/bin/pdflatex.exe"
]
},
"Beamer Slides (LaTeX)": {
"scope": {
"text.html": "html",
"text.html.markdown": "markdown",
},
"pandoc-arguments": [
"-t", "beamer",
]
},
"s5 Slides": {
"scope": {
"text.html": "html",
"text.html.markdown": "markdown",
},
"pandoc-arguments": [
"-t", "slidy", "-s", "--self-contained",
]
},
},
// these should not need to be customized
// output formats that are written to file, using -o parameter. These we do
// not output to a sublime text buffer.
"pandoc-format-file": ["docx", "epub", "pdf", "odt", "beamer"]
}
}