Merge remote-tracking branch 'upstream/gh-pages' into gh-pages
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 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513
diff --git a/bower.json b/bower.json
index 16a07f0..17c6956 100644
--- a/bower.json
+++ b/bower.json
@@ -8,6 +8,10 @@
"authors": "Lea Verou",
"description": "Lightweight, robust, elegant syntax highlighting. A spin-off project from Dabblet.",
"license": "MIT",
+ "repository": {
+ "type": "git",
+ "url": "https://github.com/PrismJS/prism.git"
+ },
"ignore": [
"**/.*",
"img",
diff --git a/components.js b/components.js
index 997960c..919b3c1 100644
--- a/components.js
+++ b/components.js
@@ -84,6 +84,10 @@ var components = {
"require": "clike",
"owner": "zeitgeist87"
},
+ "brainfuck": {
+ "title": "Brainfuck",
+ "owner": "Golmote"
+ },
"c": {
"title": "C",
"require": "clike",
@@ -202,6 +206,10 @@ var components = {
"title": "LOLCODE",
"owner": "Golmote"
},
+ "makefile": {
+ "title": "Makefile",
+ "owner": "Golmote"
+ },
"markdown": {
"title": "Markdown",
"require": "markup",
diff --git a/components/prism-brainfuck.js b/components/prism-brainfuck.js
new file mode 100644
index 0000000..604d122
--- /dev/null
+++ b/components/prism-brainfuck.js
@@ -0,0 +1,20 @@
+Prism.languages.brainfuck = {
+ 'pointer': {
+ pattern: /<|>/,
+ alias: 'keyword'
+ },
+ 'increment': {
+ pattern: /\+/,
+ alias: 'inserted'
+ },
+ 'decrement': {
+ pattern: /-/,
+ alias: 'deleted'
+ },
+ 'branching': {
+ pattern: /\[|\]/,
+ alias: 'important'
+ },
+ 'operator': /[.,]/,
+ 'comment': /\S+/
+};
\ No newline at end of file
diff --git a/components/prism-brainfuck.min.js b/components/prism-brainfuck.min.js
new file mode 100644
index 0000000..ed9707e
--- /dev/null
+++ b/components/prism-brainfuck.min.js
@@ -0,0 +1 @@
+Prism.languages.brainfuck={pointer:{pattern:/<|>/,alias:"keyword"},increment:{pattern:/\+/,alias:"inserted"},decrement:{pattern:/-/,alias:"deleted"},branching:{pattern:/\[|\]/,alias:"important"},operator:/[.,]/,comment:/\S+/};
\ No newline at end of file
diff --git a/components/prism-clike.js b/components/prism-clike.js
index 3d9f88e..7a5ba2e 100644
--- a/components/prism-clike.js
+++ b/components/prism-clike.js
@@ -9,7 +9,7 @@ Prism.languages.clike = {
lookbehind: true
}
],
- 'string': /("|')(\\[\s\S]|(?!\1)[^\\])*\1/,
+ 'string': /("|')(\\[\s\S]|(?!\1)[^\\\r\n])*\1/,
'class-name': {
pattern: /((?:(?:class|interface|extends|implements|trait|instanceof|new)\s+)|(?:catch\s+\())[a-z0-9_\.\\]+/i,
lookbehind: true,
diff --git a/components/prism-clike.min.js b/components/prism-clike.min.js
index 1ea8bb3..32ad31c 100644
--- a/components/prism-clike.min.js
+++ b/components/prism-clike.min.js
@@ -1 +1 @@
-Prism.languages.clike={comment:[{pattern:/(^|[^\\])\/\*[\w\W]*?\*\//,lookbehind:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0}],string:/("|')(\\[\s\S]|(?!\1)[^\\])*\1/,"class-name":{pattern:/((?:(?:class|interface|extends|implements|trait|instanceof|new)\s+)|(?:catch\s+\())[a-z0-9_\.\\]+/i,lookbehind:!0,inside:{punctuation:/(\.|\\)/}},keyword:/\b(if|else|while|do|for|return|in|instanceof|function|new|try|throw|catch|finally|null|break|continue)\b/,"boolean":/\b(true|false)\b/,"function":{pattern:/[a-z0-9_]+\(/i,inside:{punctuation:/\(/}},number:/\b-?(0x[\dA-Fa-f]+|\d*\.?\d+([Ee]-?\d+)?)\b/,operator:/[-+]{1,2}|!|<=?|>=?|={1,3}|&{1,2}|\|?\||\?|\*|\/|~|\^|%/,ignore:/&(lt|gt|amp);/i,punctuation:/[{}[\];(),.:]/};
\ No newline at end of file
+Prism.languages.clike={comment:[{pattern:/(^|[^\\])\/\*[\w\W]*?\*\//,lookbehind:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0}],string:/("|')(\\[\s\S]|(?!\1)[^\\\r\n])*\1/,"class-name":{pattern:/((?:(?:class|interface|extends|implements|trait|instanceof|new)\s+)|(?:catch\s+\())[a-z0-9_\.\\]+/i,lookbehind:!0,inside:{punctuation:/(\.|\\)/}},keyword:/\b(if|else|while|do|for|return|in|instanceof|function|new|try|throw|catch|finally|null|break|continue)\b/,"boolean":/\b(true|false)\b/,"function":{pattern:/[a-z0-9_]+\(/i,inside:{punctuation:/\(/}},number:/\b-?(0x[\dA-Fa-f]+|\d*\.?\d+([Ee]-?\d+)?)\b/,operator:/[-+]{1,2}|!|<=?|>=?|={1,3}|&{1,2}|\|?\||\?|\*|\/|~|\^|%/,ignore:/&(lt|gt|amp);/i,punctuation:/[{}[\];(),.:]/};
\ No newline at end of file
diff --git a/components/prism-javascript.js b/components/prism-javascript.js
index f2b4054..d4f1025 100644
--- a/components/prism-javascript.js
+++ b/components/prism-javascript.js
@@ -1,5 +1,5 @@
Prism.languages.javascript = Prism.languages.extend('clike', {
- 'keyword': /\b(as|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|false|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|true|try|typeof|var|void|while|with|yield)\b/,
+ 'keyword': /\b(as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|false|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|true|try|typeof|var|void|while|with|yield)\b/,
'number': /\b-?(0x[\dA-Fa-f]+|0b[01]+|0o[0-7]+|\d*\.?\d+([Ee][+-]?\d+)?|NaN|Infinity)\b/,
'function': /(?!\d)[a-z0-9_$]+(?=\()/i
});
diff --git a/components/prism-javascript.min.js b/components/prism-javascript.min.js
index 3bbd703..a3a4a00 100644
--- a/components/prism-javascript.min.js
+++ b/components/prism-javascript.min.js
@@ -1 +1 @@
-Prism.languages.javascript=Prism.languages.extend("clike",{keyword:/\b(as|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|false|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|true|try|typeof|var|void|while|with|yield)\b/,number:/\b-?(0x[\dA-Fa-f]+|0b[01]+|0o[0-7]+|\d*\.?\d+([Ee][+-]?\d+)?|NaN|Infinity)\b/,"function":/(?!\d)[a-z0-9_$]+(?=\()/i}),Prism.languages.insertBefore("javascript","keyword",{regex:{pattern:/(^|[^/])\/(?!\/)(\[.+?]|\\.|[^/\\\r\n])+\/[gimyu]{0,5}(?=\s*($|[\r\n,.;})]))/,lookbehind:!0}}),Prism.languages.insertBefore("javascript","class-name",{"template-string":{pattern:/`(?:\\`|\\?[^`])*`/,inside:{interpolation:{pattern:/\$\{[^}]+\}/,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},rest:Prism.languages.javascript}},string:/[\s\S]+/}}}),Prism.languages.markup&&Prism.languages.insertBefore("markup","tag",{script:{pattern:/<script[\w\W]*?>[\w\W]*?<\/script>/i,inside:{tag:{pattern:/<script[\w\W]*?>|<\/script>/i,inside:Prism.languages.markup.tag.inside},rest:Prism.languages.javascript},alias:"language-javascript"}});
\ No newline at end of file
+Prism.languages.javascript=Prism.languages.extend("clike",{keyword:/\b(as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|false|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|true|try|typeof|var|void|while|with|yield)\b/,number:/\b-?(0x[\dA-Fa-f]+|0b[01]+|0o[0-7]+|\d*\.?\d+([Ee][+-]?\d+)?|NaN|Infinity)\b/,"function":/(?!\d)[a-z0-9_$]+(?=\()/i}),Prism.languages.insertBefore("javascript","keyword",{regex:{pattern:/(^|[^/])\/(?!\/)(\[.+?]|\\.|[^/\\\r\n])+\/[gimyu]{0,5}(?=\s*($|[\r\n,.;})]))/,lookbehind:!0}}),Prism.languages.insertBefore("javascript","class-name",{"template-string":{pattern:/`(?:\\`|\\?[^`])*`/,inside:{interpolation:{pattern:/\$\{[^}]+\}/,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},rest:Prism.languages.javascript}},string:/[\s\S]+/}}}),Prism.languages.markup&&Prism.languages.insertBefore("markup","tag",{script:{pattern:/<script[\w\W]*?>[\w\W]*?<\/script>/i,inside:{tag:{pattern:/<script[\w\W]*?>|<\/script>/i,inside:Prism.languages.markup.tag.inside},rest:Prism.languages.javascript},alias:"language-javascript"}});
\ No newline at end of file
diff --git a/components/prism-keyman.min.js b/components/prism-keyman.min.js
new file mode 100644
index 0000000..3978bd2
--- /dev/null
+++ b/components/prism-keyman.min.js
@@ -0,0 +1 @@
+Prism.languages.keyman={comment:/\bc\s.*/i,"function":/\[\s*((CTRL|SHIFT|ALT|LCTRL|RCTRL|LALT|RALT|CAPS|NCAPS)\s+)*([TKU]_[a-z0-9_?]+|".+?"|'.+?')\s*\]/i,string:/("|')((?!\1).)*\1/,keyword:/\b(any|beep|call|context|deadkey|dk|if|index|notany|nul|outs|return|reset|save|set|store|use)\b/i,atrule:/\b(ansi|begin|unicode|group|using keys|match|nomatch)\b/i,bold:[/&(baselayout|bitmap|capsononly|capsalwaysoff|shiftfreescaps|copyright|ethnologuecode|hotkey|includecodes|keyboardversion|kmw_embedcss|kmw_embdjs|kmw_helpfile|kmw_helptext|kmw_rtl|language|layer|layoutfile|message|mnemoniclayout|name|oldcharposmatching|platform|targets|version|visualkeyboard|windowslanguages)\b/i,/\b(bitmap|bitmaps|caps on only|caps always off|shift frees caps|copyright|hotkey|language|layout|message|name|version)\b/i],number:/\b(U\+[\dA-F]+|d\d+|x[\da-f]+|\d+)\b/i,operator:/[+>\\,()]/,tag:/\$(keyman|kmfl|weaver|keymanweb|keymanonly):/i};
\ No newline at end of file
diff --git a/components/prism-makefile.js b/components/prism-makefile.js
new file mode 100644
index 0000000..a678fab
--- /dev/null
+++ b/components/prism-makefile.js
@@ -0,0 +1,31 @@
+Prism.languages.makefile = {
+ 'comment': {
+ pattern: /(^|[^\\])#(?:\\[\s\S]|.)*/,
+ lookbehind: true
+ },
+ 'string': /(["'])(?:\\[\s\S]|(?!\1)[^\\\r\n])*\1/,
+
+ // Built-in target names
+ 'builtin': /\.[A-Z][^:#=\s]+(?=\s*:(?!=))/,
+
+ // Targets
+ 'symbol': {
+ pattern: /^[^:=\r\n]+(?=\s*:(?!=))/m,
+ inside: {
+ 'variable': /\$+(?:[^(){}:#=\s]+|(?=[({]))/
+ }
+ },
+ 'variable': /\$+(?:[^(){}:#=\s]+|\([@*%<^+?][DF]\)|(?=[({]))/,
+
+ 'keyword': [
+ // Directives
+ /\b(?:define|else|endef|endif|export|ifn?def|ifn?eq|-?include|override|private|sinclude|undefine|unexport|vpath)\b/,
+ // Functions
+ {
+ pattern: /(\()(?:addsuffix|abspath|and|basename|call|dir|error|eval|file|filter(?:-out)?|findstring|firstword|flavor|foreach|guile|if|info|join|lastword|load|notdir|or|origin|patsubst|realpath|shell|sort|strip|subst|suffix|value|warning|wildcard|word(?:s|list)?)(?=[ \t])/,
+ lookbehind: true
+ }
+ ],
+ 'operator': /(?:::|[?:+!])?=|[|@]/,
+ 'punctuation': /[:;(){}]/
+};
\ No newline at end of file
diff --git a/components/prism-makefile.min.js b/components/prism-makefile.min.js
new file mode 100644
index 0000000..85d6f42
--- /dev/null
+++ b/components/prism-makefile.min.js
@@ -0,0 +1 @@
+Prism.languages.makefile={comment:{pattern:/(^|[^\\])#(?:\\[\s\S]|.)*/,lookbehind:!0},string:/(["'])(?:\\[\s\S]|(?!\1)[^\\\r\n])*\1/,builtin:/\.[A-Z][^:#=\s]+(?=\s*:(?!=))/,symbol:{pattern:/^[^:=\r\n]+(?=\s*:(?!=))/m,inside:{variable:/\$+(?:[^(){}:#=\s]+|(?=[({]))/}},variable:/\$+(?:[^(){}:#=\s]+|\([@*%<^+?][DF]\)|(?=[({]))/,keyword:[/\b(?:define|else|endef|endif|export|ifn?def|ifn?eq|-?include|override|private|sinclude|undefine|unexport|vpath)\b/,{pattern:/(\()(?:addsuffix|abspath|and|basename|call|dir|error|eval|file|filter(?:-out)?|findstring|firstword|flavor|foreach|guile|if|info|join|lastword|load|notdir|or|origin|patsubst|realpath|shell|sort|strip|subst|suffix|value|warning|wildcard|word(?:s|list)?)(?=[ \t])/,lookbehind:!0}],operator:/(?:::|[?:+!])?=|[|@]/,punctuation:/[:;(){}]/};
\ No newline at end of file
diff --git a/examples/prism-brainfuck.html b/examples/prism-brainfuck.html
new file mode 100644
index 0000000..e4cf9fe
--- /dev/null
+++ b/examples/prism-brainfuck.html
@@ -0,0 +1,40 @@
+<h1>Brainfuck</h1>
+<p>To use this language, use the class "language-brainfuck".</p>
+
+<h2>Full example</h2>
+<pre><code>+++++ +++ Set Cell #0 to 8
+[
+ >++++ Add 4 to Cell #1; this will always set Cell #1 to 4
+ [ as the cell will be cleared by the loop
+ >++ Add 2 to Cell #2
+ >+++ Add 3 to Cell #3
+ >+++ Add 3 to Cell #4
+ >+ Add 1 to Cell #5
+ <<<<- Decrement the loop counter in Cell #1
+ ] Loop till Cell #1 is zero; number of iterations is 4
+ >+ Add 1 to Cell #2
+ >+ Add 1 to Cell #3
+ >- Subtract 1 from Cell #4
+ >>+ Add 1 to Cell #6
+ [<] Move back to the first zero cell you find; this will
+ be Cell #1 which was cleared by the previous loop
+ <- Decrement the loop Counter in Cell #0
+] Loop till Cell #0 is zero; number of iterations is 8
+
+The result of this is:
+Cell No : 0 1 2 3 4 5 6
+Contents: 0 0 72 104 88 32 8
+Pointer : ^
+
+>>. Cell #2 has value 72 which is 'H'
+>---. Subtract 3 from Cell #3 to get 101 which is 'e'
++++++++..+++. Likewise for 'llo' from Cell #3
+>>. Cell #5 is 32 for the space
+<-. Subtract 1 from Cell #4 for 87 to give a 'W'
+<. Cell #3 was set to 'o' from the end of 'Hello'
++++.------.--------. Cell #3 for 'rl' and 'd'
+>>+. Add 1 to Cell #5 gives us an exclamation point
+>++. And finally a newline from Cell #6</code></pre>
+
+<h2>One-line example</h2>
+<pre><code>++++++++[>++++[>++>+++>+++>+<<<<-]>+>+>->>+[<]<-]>>.>---.+++++++..+++.>>.<-.<.+++.------.--------.>>+.>++.</code></pre>
diff --git a/examples/prism-makefile.html b/examples/prism-makefile.html
new file mode 100644
index 0000000..738c9a9
--- /dev/null
+++ b/examples/prism-makefile.html
@@ -0,0 +1,266 @@
+<h1>Makefile</h1>
+<p>To use this language, use the class "language-makefile".</p>
+
+<h2>Comments</h2>
+<pre><code># This is a comment
+include foo # This is another comment</code></pre>
+
+<h2>Targets</h2>
+<pre><code>kbd.o command.o files.o : command.h
+display.o insert.o search.o files.o : buffer.h
+
+.PHONY: clean
+clean:
+ rm *.o temp</code></pre>
+
+<h2>Variables</h2>
+<pre><code>objects = main.o kbd.o command.o display.o \
+ insert.o search.o files.o utils.o
+
+edit : $(objects)
+ cc -o edit $(objects)
+
+$(objects) : defs.h
+
+%oo: $$< $$^ $$+ $$*
+
+foo : bar/lose
+ cd $(@D) && gobble $(@F) > ../$@</code></pre>
+
+<h2>Strings</h2>
+<pre><code>STR = 'A string!'
+
+HELLO = 'hello \
+world'
+
+HELLO2 = "hello \
+world"</code></pre>
+
+<h2>Directives</h2>
+<pre><code>include foo *.mk $(bar)
+
+vpath %.c foo
+
+override define two-lines =
+foo
+$(bar)
+endef
+
+ifeq ($(CC),gcc)
+ libs=$(libs_for_gcc)
+else
+ libs=$(normal_libs)
+endif</code></pre>
+
+<h2>Functions</h2>
+<pre><code>whoami := $(shell whoami)
+host-type := $(shell arch)
+
+y = $(subst 1,2,$(x))
+
+dirs := a b c d
+files := $(foreach dir,$(dirs),$(wildcard $(dir)/*))
+
+reverse = $(2) $(1)
+foo = $(call reverse,a,b)
+
+$(foreach prog,$(PROGRAMS),$(eval $(call PROGRAM_template,$(prog))))</code></pre>
+
+<h2>Complete example</h2>
+<pre><code>#!/usr/bin/make -f
+# Generated automatically from Makefile.in by configure.
+# Un*x Makefile for GNU tar program.
+# Copyright (C) 1991 Free Software Foundation, Inc.
+
+# This program is free software; you can redistribute
+# it and/or modify it under the terms of the GNU
+# General Public License …
+…
+…
+
+SHELL = /bin/sh
+
+#### Start of system configuration section. ####
+
+srcdir = .
+
+# If you use gcc, you should either run the
+# fixincludes script that comes with it or else use
+# gcc with the -traditional option. Otherwise ioctl
+# calls will be compiled incorrectly on some systems.
+CC = gcc -O
+YACC = bison -y
+INSTALL = /usr/local/bin/install -c
+INSTALLDATA = /usr/local/bin/install -c -m 644
+
+# Things you might add to DEFS:
+# -DSTDC_HEADERS If you have ANSI C headers and
+# libraries.
+# -DPOSIX If you have POSIX.1 headers and
+# libraries.
+# -DBSD42 If you have sys/dir.h (unless
+# you use -DPOSIX), sys/file.h,
+# and st_blocks in `struct stat'.
+# -DUSG If you have System V/ANSI C
+# string and memory functions
+# and headers, sys/sysmacros.h,
+# fcntl.h, getcwd, no valloc,
+# and ndir.h (unless
+# you use -DDIRENT).
+# -DNO_MEMORY_H If USG or STDC_HEADERS but do not
+# include memory.h.
+# -DDIRENT If USG and you have dirent.h
+# instead of ndir.h.
+# -DSIGTYPE=int If your signal handlers
+# return int, not void.
+# -DNO_MTIO If you lack sys/mtio.h
+# (magtape ioctls).
+# -DNO_REMOTE If you do not have a remote shell
+# or rexec.
+# -DUSE_REXEC To use rexec for remote tape
+# operations instead of
+# forking rsh or remsh.
+# -DVPRINTF_MISSING If you lack vprintf function
+# (but have _doprnt).
+# -DDOPRNT_MISSING If you lack _doprnt function.
+# Also need to define
+# -DVPRINTF_MISSING.
+# -DFTIME_MISSING If you lack ftime system call.
+# -DSTRSTR_MISSING If you lack strstr function.
+# -DVALLOC_MISSING If you lack valloc function.
+# -DMKDIR_MISSING If you lack mkdir and
+# rmdir system calls.
+# -DRENAME_MISSING If you lack rename system call.
+# -DFTRUNCATE_MISSING If you lack ftruncate
+# system call.
+# -DV7 On Version 7 Unix (not
+# tested in a long time).
+# -DEMUL_OPEN3 If you lack a 3-argument version
+# of open, and want to emulate it
+# with system calls you do have.
+# -DNO_OPEN3 If you lack the 3-argument open
+# and want to disable the tar -k
+# option instead of emulating open.
+# -DXENIX If you have sys/inode.h
+# and need it 94 to be included.
+
+DEFS = -DSIGTYPE=int -DDIRENT -DSTRSTR_MISSING \
+ -DVPRINTF_MISSING -DBSD42
+# Set this to rtapelib.o unless you defined NO_REMOTE,
+# in which case make it empty.
+RTAPELIB = rtapelib.o
+LIBS =
+DEF_AR_FILE = /dev/rmt8
+DEFBLOCKING = 20
+
+CDEBUG = -g
+CFLAGS = $(CDEBUG) -I. -I$(srcdir) $(DEFS) \
+ -DDEF_AR_FILE=\"$(DEF_AR_FILE)\" \
+ -DDEFBLOCKING=$(DEFBLOCKING)
+LDFLAGS = -g
+
+prefix = /usr/local
+# Prefix for each installed program,
+# normally empty or `g'.
+binprefix =
+
+# The directory to install tar in.
+bindir = $(prefix)/bin
+
+# The directory to install the info files in.
+infodir = $(prefix)/info
+
+#### End of system configuration section. ####
+
+SRCS_C = tar.c create.c extract.c buffer.c \
+ getoldopt.c update.c gnu.c mangle.c \
+ version.c list.c names.c diffarch.c \
+ port.c wildmat.c getopt.c getopt1.c \
+ regex.c
+SRCS_Y = getdate.y
+SRCS = $(SRCS_C) $(SRCS_Y)
+OBJS = $(SRCS_C:.c=.o) $(SRCS_Y:.y=.o) $(RTAPELIB)
+
+AUX = README COPYING ChangeLog Makefile.in \
+ makefile.pc configure configure.in \
+ tar.texinfo tar.info* texinfo.tex \
+ tar.h port.h open3.h getopt.h regex.h \
+ rmt.h rmt.c rtapelib.c alloca.c \
+ msd_dir.h msd_dir.c tcexparg.c \
+ level-0 level-1 backup-specs testpad.c
+
+.PHONY: all
+all: tar rmt tar.info
+
+tar: $(OBJS)
+ $(CC) $(LDFLAGS) -o $@ $(OBJS) $(LIBS)
+
+rmt: rmt.c
+ $(CC) $(CFLAGS) $(LDFLAGS) -o $@ rmt.c
+
+tar.info: tar.texinfo
+ makeinfo tar.texinfo
+
+.PHONY: install
+install: all
+ $(INSTALL) tar $(bindir)/$(binprefix)tar
+ -test ! -f rmt || $(INSTALL) rmt /etc/rmt
+ $(INSTALLDATA) $(srcdir)/tar.info* $(infodir)
+
+$(OBJS): tar.h port.h testpad.h
+regex.o buffer.o tar.o: regex.h
+# getdate.y has 8 shift/reduce conflicts.
+
+testpad.h: testpad
+ ./testpad
+
+testpad: testpad.o
+ $(CC) -o $@ testpad.o
+
+TAGS: $(SRCS)
+ etags $(SRCS)
+
+.PHONY: clean
+clean:
+ rm -f *.o tar rmt testpad testpad.h core
+
+.PHONY: distclean
+distclean: clean
+ rm -f TAGS Makefile config.status
+
+.PHONY: realclean
+realclean: distclean
+ rm -f tar.info*
+
+.PHONY: shar
+shar: $(SRCS) $(AUX)
+ shar $(SRCS) $(AUX) | compress \
+ > tar-`sed -e '/version_string/!d' \
+ -e 's/[^0-9.]*\([0-9.]*\).*/\1/' \
+ -e q
+ version.c`.shar.Z
+
+.PHONY: dist
+dist: $(SRCS) $(AUX)
+ echo tar-`sed \
+ -e '/version_string/!d' \
+ -e 's/[^0-9.]*\([0-9.]*\).*/\1/' \
+ -e q
+ version.c` > .fname
+ -rm -rf `cat .fname`
+ mkdir `cat .fname`
+ ln $(SRCS) $(AUX) `cat .fname`
+ tar chZf `cat .fname`.tar.Z `cat .fname`
+ -rm -rf `cat .fname` .fname
+
+tar.zoo: $(SRCS) $(AUX)
+ -rm -rf tmp.dir
+ -mkdir tmp.dir
+ -rm tar.zoo
+ for X in $(SRCS) $(AUX) ; do \
+ echo $$X ; \
+ sed 's/$$/^M/' $$X \
+ > tmp.dir/$$X ; done
+ cd tmp.dir ; zoo aM ../tar.zoo *
+ -rm -rf tmp.dir
+</code></pre>
\ No newline at end of file
diff --git a/prism.js b/prism.js
index fb0aeca..81a2f0b 100644
--- a/prism.js
+++ b/prism.js
@@ -548,7 +548,7 @@ Prism.languages.clike = {
lookbehind: true
}
],
- 'string': /("|')(\\[\s\S]|(?!\1)[^\\])*\1/,
+ 'string': /("|')(\\[\s\S]|(?!\1)[^\\\r\n])*\1/,
'class-name': {
pattern: /((?:(?:class|interface|extends|implements|trait|instanceof|new)\s+)|(?:catch\s+\())[a-z0-9_\.\\]+/i,
lookbehind: true,
@@ -576,7 +576,7 @@ Prism.languages.clike = {
********************************************** */
Prism.languages.javascript = Prism.languages.extend('clike', {
- 'keyword': /\b(as|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|false|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|true|try|typeof|var|void|while|with|yield)\b/,
+ 'keyword': /\b(as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|false|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|true|try|typeof|var|void|while|with|yield)\b/,
'number': /\b-?(0x[\dA-Fa-f]+|0b[01]+|0o[0-7]+|\d*\.?\d+([Ee][+-]?\d+)?|NaN|Infinity)\b/,
'function': /(?!\d)[a-z0-9_$]+(?=\()/i
});