diff options
author | Andreas Stöckel <astoecke@techfak.uni-bielefeld.de> | 2015-03-22 01:14:35 +0100 |
---|---|---|
committer | Andreas Stöckel <astoecke@techfak.uni-bielefeld.de> | 2015-03-22 01:14:35 +0100 |
commit | 93119091893c2f2bf396785e6bd7dcbb9b4f207d (patch) | |
tree | 408e37ec0bf4ebb1e5427f37b1e12344f70eae9c /script/prism_bash.js | |
parent | f6fc9fa292e8da56fe7078f9ac5bdfefa55abe94 (diff) |
* Implement code highlighting using Prism
* Automatically build ousia.js
Diffstat (limited to 'script/prism_bash.js')
-rw-r--r-- | script/prism_bash.js | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/script/prism_bash.js b/script/prism_bash.js new file mode 100644 index 0000000..24d5025 --- /dev/null +++ b/script/prism_bash.js @@ -0,0 +1,21 @@ +// @license magnet:?xt=urn:btih:5305d91886084f776adcf57509a648432709a7c7&dn=x11.txt +/* + * Ousía Website JS + * + * (c) Andreas Stöckel, 2015 + * + * This work is licensed under the X11 (MIT) license. + * http://www.opensource.org/licenses/mit-license.php + */ + +(function () { +"use strict"; +Prism.languages.bash = { + 'comment': /#.*$/, + 'string': /("|')(\\\n|\\?.)*?\1/, + 'url': /http:\/\/[^\s]*/, + 'keyword': /(^| )(cd|mkdir|git|echo|clone|sudo|yum|apt-get|cmake|make|install)( |$)/ +}; +})(); + +// @license-end |