forked from revolunet/sublimetext-markdown-preview
-
-
Notifications
You must be signed in to change notification settings - Fork 52
/
MarkdownPreview.sublime-settings
382 lines (315 loc) · 13.6 KB
/
MarkdownPreview.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
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
/*
Markdown Preview default settings
*/
{
/*
Sets the default opener for HTML files.
default - Use the system default HTML viewer
other - Set a full path to any executable. ex: /Applications/Google Chrome Canary.app or /Applications/Firefox.app
*/
"browser": "default",
/*
Sets the parser used for building Markdown to HTML.
NOTE: The parser setting is not meant for the preview commands.
The previews have separate commands for each Markdown parser.
Warning regarding the GitHub API: if you have a ST2 Linux build, Python is not built with SSL so it may not work.
default - The current default parser is python-markdown parser.
markdown - Use the built-in python-markdown parser.
github - Use the GitHub API to convert Markdown, so you can use GitHub Flavored Markdown, see https://help.github.com/articles/github-flavored-markdown/
gitlab - Use the GitLab API to convert Markdown, so you can use GitLab Flavored Markdown, see https://docs.gitlab.com/ee/user/markdown.html
*/
"parser": "markdown",
/*
Overrides how HTML files are built.
By default, Markdown Preview builds the HTML in the source directory.
It expects the file to exist on disk, pops up the build output
panel etc.
To override this behavior, you can choose between the following:
build - The default build behavior.
browser - Preview the file in your browser.
clipboard - Copy the HTML output to the clipboard.
sublime - Export the HTML to a Sublime tab.
save - Run the normal save command that outputs to the source directory.
This will also prompt for "save as" if the file does not exit on disk.
All the build options use the default parser defined above in "parser".
*/
"build_action": "build",
/*
Inject Pygment styles into the HTML.
You may want to enable this if Pygments is being used.
*/
"pygments_inject_css": true,
/*
Name of the Pygments style to inject.
Available styles are those provided by Pygments plus "github" and "github2014".
*/
"pygments_style": "github",
/*
Class to prepend to Pygments CSS styles.
Make sure this setting matches whatever class(es) you've specified
in the extension that controls Pygments highlighting. CodeHilite's
default is "codehilite". Pymdownx's default is "highlight".
Update this setting to match the highlighter you are using.
*/
"pygments_css_class": "highlight",
/*
Markdown extension configuration.
To specify a function in this JSON configuration, create an object
with the key "!!python/name" and set it to the import path to
the function "module.submodule.etc.function".
*/
"markdown_extensions": [
// Python Markdown Extra with SuperFences.
// You can't include "extra" and "superfences"
// as "fenced_code" cannot be included with "superfences",
// so we include the pieces separately.
"markdown.extensions.footnotes",
"markdown.extensions.attr_list",
"markdown.extensions.def_list",
"markdown.extensions.tables",
"markdown.extensions.abbr",
"markdown.extensions.md_in_html",
"pymdownx.betterem",
// Extra's Markdown parsing in raw HTML cannot be
// included by itself, but "pymdownx" exposes it, so we can.
// More default Python Markdown extensions
{
"markdown.extensions.toc":
{
"permalink": "\ue157"
}
},
"markdown.extensions.meta",
"markdown.extensions.sane_lists",
"markdown.extensions.smarty",
"markdown.extensions.wikilinks",
"markdown.extensions.admonition",
// PyMdown extensions that help give a GitHub-ish feel
{
"pymdownx.superfences": { // Nested fences and UML support
"custom_fences": [
{
"name": "flow",
"class": "uml-flowchart",
"format": {"!!python/name": "pymdownx.superfences.fence_code_format"}
},
{
"name": "sequence",
"class": "uml-sequence-diagram",
"format": {"!!python/name": "pymdownx.superfences.fence_code_format"}
},
{
"name": "mermaid",
"class": "mermaid",
"format": {"!!python/name": "pymdownx.superfences.fence_code_format"}
}
]
}
},
{
"pymdownx.magiclink": { // Auto linkify URLs and email addresses
"repo_url_shortener": true,
"repo_url_shorthand": true
}
},
"pymdownx.tasklist", // Task lists
{
"pymdownx.tilde": { // Provide ~~delete~~
"subscript": false
}
},
{
"pymdownx.emoji": { // Provide GitHub's emoji
"emoji_index": {"!!python/name": "pymdownx.emoji.gemoji"},
"emoji_generator": {"!!python/name": "pymdownx.emoji.to_png"},
"alt": "short",
"options": {
"attributes": {
"align": "absmiddle",
"height": "20px",
"width": "20px"
},
"image_path": "https://github.githubassets.com/images/icons/emoji/unicode/",
"non_standard_image_path": "https://github.githubassets.com/images/icons/emoji/"
}
}
}
],
/*
Enabled parser(s) for the parser "select parser" command.
Available parsers: markdown, github, gitlab
When the list contains more than one parser, Sublime will prompt
you to pick one of them via the quick panel. Otherwise, the sole
parser provided is run automatically.
*/
"enabled_parsers": ["markdown", "github", "gitlab"],
/*
Custom external Markdown parsers.
"markdown_binary_map" contains key-value pairs.
The key is the name of the parser and what is used in
"enabled_parsers" to turn on the access to the parser.
The value is an array containing the path to the binary
and all the parameters that are desired.
MultiMarkDown is provided as an example below. Its path may differ
on your system.
*/
"markdown_binary_map": {
"multimarkdown": ["/usr/local/bin/multimarkdown"]
},
/*
Default mode for GitHub's Markdown parser:
markdown (documents) or gfm (comments)
see http://developer.github.com/v3/markdown/#render-an-arbitrary-markdown-document
*/
"github_mode": "markdown",
/*
Default mode for the GitLab's Markdown parser:
markdown (documents) or gfm (comments)
see https://docs.gitlab.com/ee/api/markdown.html#render-an-arbitrary-markdown-document
*/
"gitlab_mode": "gfm",
/*
Enables a post process to inject header IDs to ensure hrefs to headers work.
*/
"github_inject_header_ids": false,
/*
Use a personal access token to parse GitHub Flavored Markdown with
the GitHub API. For info on token creation, see this page:
https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/creating-a-personal-access-token
Warning: the secret must not be shared with anyone; for security
reasons, it is recommended you use minimal scopes (i.e. do not
check any boxes for additional scopes).
*/
// "github_oauth_token": "secret",
/*
Use a personal access token to parse GitLab Flavored Markdown with
the GitLab API. For info on token creation, see this page:
https://docs.gitlab.com/ee/user/profile/personal_access_tokens.html
Warning: the secret must not be shared with anyone; for security
reasons, it is recommended you use minimal scopes.
*/
// "gitlab_personal_token": "secret",
/*
Sets the default CSS file to embed in the HTML.
default - Use the built-in CSS or GitHub/GitLab CSS, depending on parser config (markdown.css, github.css or gitlab.css).
other - Set an absolute path or URL to any CSS file.
Should be an array, but will take a single string to support legacy convention.
*/
"css": {
"markdown": ["default"],
"github": ["default"],
"gitlab": ["default"]
},
/*
Allow CSS overrides.
true - Any file with matching a .markdown_filetype extension with .css will be loaded as an override.
false - Matching files ignored
*/
"allow_css_overrides": true,
/*
Specify an HTML template file with which to render your Markdown.
Available placeholders in the HTML template:
{{ HEAD }} - gets replaced with generated stylesheets and JavaScript enabled above
{{ BODY }} - gets replaced with HTML converted from Markdown
Remove "default" from "css" setting to avoid injecting the default CSS
if desired. Refer to 'customized-template-sample.html' as a showcase.
*/
"html_template": "",
/*
Provide any JavaScript files to be embedded in the HTML.
Setting consists of an array of URLs or filepaths to JavaScript files.
Absolute filepaths will be loaded into the script tag, URLs will be
set via the `src` attribute.
All files are embedded in the order in which they appear in the array.
default - Use the built-in JavaScript or GitHub/GitLab JavaScript, depending on parser config.
other - Set an absolute path or URL to any JavaScript file.
Should be an array, but will take a single string to stay consistent with "css".
*/
"js": {
"markdown": ["default"],
"github": ["default"],
"gitlab": ["default"]
},
/*
Sets syntax highlighting theme for blocks of code.
One of "white" (default), "dark", "solarized-dark", "solarized-light", and "monokai".
*/
"gitlab_highlight_theme": "white",
/*
Enable auto-reload on save.
Will not work if the GitHub parser or GitLab parser are used
without a valid access token.
*/
"enable_autoreload": true,
/*
Sets the supported filetypes for auto-reload on save.
*/
"markdown_filetypes": [".md", ".markdown", ".mdown"],
/*
Sets a custom temporary folder for MarkdownPreview-generated HTML
files.
This is useful if you're using LiveReload and don't want to use
the OS default. The directory will be created if it doesn't exist yet.
Relative paths are supported and are checked against `os.path.isabs`,
see docs: http://docs.python.org/3/library/os.path.html#os.path.isabs
Environment variables and user "~" placeholder are supported.
see docs: https://docs.python.org/3/library/os.path.html#os.path.expanduser
see docs: https://docs.python.org/3/library/os.path.html#os.path.expandvars
Examples: /tmp/custom_folder (Linux/macOS - absolute path)
C:/TEMP/MYNOTES
C:\\TEMP\\MYNOTES (Windows - absolute path, forward slash or escaped backslash)
build (All OS - relative path, current dir)
../build (Linux/macOS - relative path, in parent dir)
..\\build (Windows - relative path, in parent dir)
*/
"path_tempfile": "",
/*
Sets HTML output to a simple form:
- No head
- No body tags
- ids, classes, and style are stripped out
- Just bare minimum HTML tags and attributes
- extension modifications included
*/
"html_simple": false,
/*
Sets how image paths are handled.
Setting is a string value: (absolute | relative | base64 | none)
absolute: converts relative local paths to absolute
relative: converts relative local paths to a path relative to the
HTML output
base64: coverts the local file to base64 and embeds it in the HTML
none: does nothing
*/
"image_path_conversion": "absolute",
/*
Sets how file paths are handled.
Setting is a string value: (absolute | relative | none)
absolute: converts relative local paths to absolute
relative: converts relative local paths to a path relative to the
HTML output
none: does nothing
*/
"file_path_conversions": "absolute",
/*
Sets how MultiMarkDown critic marks are handled.
Setting is a string value: (accept | reject | none)
accept: Accepts the proposed inserts and deletions (comments etc. are discarded)
reject: Rejects the proposed inserts and deletions (comments etc. are discarded)
none: does nothing
Critic marks only affect the "github" and "markdown" parser.
*/
"strip_critic_marks": "none",
/*
Strips the YAML front matter header and converts title to a heading.
*/
"strip_yaml_front_matter": false,
/*
Sets visibility of the build output panel when building with CMD+B.
*/
"show_panel_on_build": true,
/*
Sets if CSS is included when outputting HTML.
*/
"include_head": ["build", "browser", "sublime", "clipboard", "save"]
}