Merge pull request #76 from rnicholus/syntax-highlighting

Better syntax highlighting & switch to redcarpet parser
This commit is contained in:
Barry Clark 2015-01-11 15:27:26 -05:00
commit 8e77d1436b
2 changed files with 80 additions and 157 deletions

View file

@ -49,7 +49,7 @@ baseurl: ""
# !! You don't need to change any of the configuration flags below !! # !! You don't need to change any of the configuration flags below !!
# #
markdown: kramdown markdown: redcarpet
highlighter: pygments highlighter: pygments
permalink: /:title/ permalink: /:title/

View file

@ -1,161 +1,84 @@
/***********************/ .highlight {
/* SYNTAX HIGHLIGHTING */ background-color: #efefef;
/***********************/ padding: 7px 7px 7px 10px;
border: 1px solid #ddd;
.highlight { -moz-box-shadow: 3px 3px rgba(0,0,0,0.1);
background-color: $darkerGray; -webkit-box-shadow: 3px 3px rgba(0,0,0,0.1);
padding: 5px 10px; box-shadow: 3px 3px rgba(0,0,0,0.1);
margin: 20px 0; margin: 20px 0 20px 0;
overflow: scroll;
} }
.highlight pre {
/* overflow: scroll; Prefer no word wrap? Uncomment this line and comment out the 2 lines below. */
word-break: break-all;
word-wrap: break-word;
}
code { code {
font-family: 'Courier', monospace; font-family:'Bitstream Vera Sans Mono','Courier', monospace;
font-size: 14px;
color: #999
} }
// Solarized Light Pygments .highlight .c { color: #586E75 } /* Comment */
// Thanks https://gist.github.com/edwardhotchkiss/2005058 .highlight .err { color: #93A1A1 } /* Error */
/* Comment */ .highlight .g { color: #93A1A1 } /* Generic */
.highlight .c, .highlight .c1 { color: #586E75 } .highlight .k { color: #859900 } /* Keyword */
/* Error */ .highlight .l { color: #93A1A1 } /* Literal */
.highlight .err { color: #93A1A1 } .highlight .n { color: #93A1A1 } /* Name */
/* Generic */ .highlight .o { color: #859900 } /* Operator */
.highlight .g { color: #93A1A1 } .highlight .x { color: #CB4B16 } /* Other */
/* Keyword */ .highlight .p { color: #93A1A1 } /* Punctuation */
.highlight .k { color: #859900 } .highlight .cm { color: #586E75 } /* Comment.Multiline */
/* Literal */ .highlight .cp { color: #859900 } /* Comment.Preproc */
.highlight .l { color: #93A1A1 } .highlight .c1 { color: #586E75 } /* Comment.Single */
/* Name */ .highlight .cs { color: #859900 } /* Comment.Special */
.highlight .n { color: #93A1A1 } .highlight .gd { color: #2AA198 } /* Generic.Deleted */
/* Operator */ .highlight .ge { color: #93A1A1; font-style: italic } /* Generic.Emph */
.highlight .o { color: #859900 } .highlight .gr { color: #DC322F } /* Generic.Error */
/* Other */ .highlight .gh { color: #CB4B16 } /* Generic.Heading */
.highlight .x { color: #CB4B16 } .highlight .gi { color: #859900 } /* Generic.Inserted */
/* Punctuation */ .highlight .go { color: #93A1A1 } /* Generic.Output */
.highlight .p { color: #93A1A1 } .highlight .gp { color: #93A1A1 } /* Generic.Prompt */
/* Comment.Multiline */ .highlight .gs { color: #93A1A1; font-weight: bold } /* Generic.Strong */
.highlight .cm { color: #586E75 } .highlight .gu { color: #CB4B16 } /* Generic.Subheading */
/* Comment.Preproc */ .highlight .gt { color: #93A1A1 } /* Generic.Traceback */
.highlight .cp { color: #859900 } .highlight .kc { color: #CB4B16 } /* Keyword.Constant */
/* Comment.Single */ .highlight .kd { color: #268BD2 } /* Keyword.Declaration */
.highlight .c1 { color: #586E75 } .highlight .kn { color: #859900 } /* Keyword.Namespace */
/* Comment.Special */ .highlight .kp { color: #859900 } /* Keyword.Pseudo */
.highlight .cs { color: #859900 } .highlight .kr { color: #268BD2 } /* Keyword.Reserved */
/* Generic.Deleted */ .highlight .kt { color: #DC322F } /* Keyword.Type */
.highlight .gd { color: #2AA198 } .highlight .ld { color: #93A1A1 } /* Literal.Date */
/* Generic.Emph */ .highlight .m { color: #2AA198 } /* Literal.Number */
.highlight .ge { color: #93A1A1; font-style: italic } .highlight .s { color: #2AA198 } /* Literal.String */
/* Generic.Error */ .highlight .na { color: #93A1A1 } /* Name.Attribute */
.highlight .gr { color: #DC322F } .highlight .nb { color: #B58900 } /* Name.Builtin */
/* Generic.Heading */ .highlight .nc { color: #268BD2 } /* Name.Class */
.highlight .gh { color: #CB4B16 } .highlight .no { color: #CB4B16 } /* Name.Constant */
/* Generic.Inserted */ .highlight .nd { color: #268BD2 } /* Name.Decorator */
.highlight .gi { color: #859900 } .highlight .ni { color: #CB4B16 } /* Name.Entity */
/* Generic.Output */ .highlight .ne { color: #CB4B16 } /* Name.Exception */
.highlight .go { color: #93A1A1 } .highlight .nf { color: #268BD2 } /* Name.Function */
/* Generic.Prompt */ .highlight .nl { color: #93A1A1 } /* Name.Label */
.highlight .gp { color: #93A1A1 } .highlight .nn { color: #93A1A1 } /* Name.Namespace */
/* Generic.Strong */ .highlight .nx { color: #555 } /* Name.Other */
.highlight .gs { color: #93A1A1; font-weight: bold } .highlight .py { color: #93A1A1 } /* Name.Property */
/* Generic.Subheading */ .highlight .nt { color: #268BD2 } /* Name.Tag */
.highlight .gu { color: #CB4B16 } .highlight .nv { color: #268BD2 } /* Name.Variable */
/* Generic.Traceback */ .highlight .ow { color: #859900 } /* Operator.Word */
.highlight .gt { color: #93A1A1 } .highlight .w { color: #93A1A1 } /* Text.Whitespace */
/* Keyword.Constant */ .highlight .mf { color: #2AA198 } /* Literal.Number.Float */
.highlight .kc { color: #CB4B16 } .highlight .mh { color: #2AA198 } /* Literal.Number.Hex */
/* Keyword.Declaration */ .highlight .mi { color: #2AA198 } /* Literal.Number.Integer */
.highlight .kd { color: #268BD2 } .highlight .mo { color: #2AA198 } /* Literal.Number.Oct */
/* Keyword.Namespace */ .highlight .sb { color: #586E75 } /* Literal.String.Backtick */
.highlight .kn { color: #859900 } .highlight .sc { color: #2AA198 } /* Literal.String.Char */
/* Keyword.Pseudo */ .highlight .sd { color: #93A1A1 } /* Literal.String.Doc */
.highlight .kp { color: #859900 } .highlight .s2 { color: #2AA198 } /* Literal.String.Double */
/* Keyword.Reserved */ .highlight .se { color: #CB4B16 } /* Literal.String.Escape */
.highlight .kr { color: #268BD2 } .highlight .sh { color: #93A1A1 } /* Literal.String.Heredoc */
/* Keyword.Type */ .highlight .si { color: #2AA198 } /* Literal.String.Interpol */
.highlight .kt { color: #DC322F } .highlight .sx { color: #2AA198 } /* Literal.String.Other */
/* Literal.Date */ .highlight .sr { color: #DC322F } /* Literal.String.Regex */
.highlight .ld { color: #93A1A1 } .highlight .s1 { color: #2AA198 } /* Literal.String.Single */
/* Literal.Number */ .highlight .ss { color: #2AA198 } /* Literal.String.Symbol */
.highlight .m { color: #2AA198 } .highlight .bp { color: #268BD2 } /* Name.Builtin.Pseudo */
/* Literal.String */ .highlight .vc { color: #268BD2 } /* Name.Variable.Class */
.highlight .s { color: #2AA198 } .highlight .vg { color: #268BD2 } /* Name.Variable.Global */
/* Name.Attribute */ .highlight .vi { color: #268BD2 } /* Name.Variable.Instance */
.highlight .na { color: #93A1A1 } .highlight .il { color: #2AA198 } /* Literal.Number.Integer.Long */
/* Name.Builtin */
.highlight .nb { color: #B58900 }
/* Name.Class */
.highlight .nc { color: #268BD2 }
/* Name.Constant */
.highlight .no { color: #CB4B16 }
/* Name.Decorator */
.highlight .nd { color: #268BD2 }
/* Name.Entity */
.highlight .ni { color: #CB4B16 }
/* Name.Exception */
.highlight .ne { color: #CB4B16 }
/* Name.Function */
.highlight .nf { color: #268BD2 }
/* Name.Label */
.highlight .nl { color: #93A1A1 }
/* Name.Namespace */
.highlight .nn { color: #93A1A1 }
/* Name.Other */
.highlight .nx { color: #555 }
/* Name.Property */
.highlight .py { color: #93A1A1 }
/* Name.Tag */
.highlight .nt { color: #268BD2 }
/* Name.Variable */
.highlight .nv { color: #268BD2 }
/* Operator.Word */
.highlight .ow { color: #859900 }
/* Text.Whitespace */
.highlight .w { color: #93A1A1 }
/* Literal.Number.Float */
.highlight .mf { color: #2AA198 }
/* Literal.Number.Hex */
.highlight .mh { color: #2AA198 }
/* Literal.Number.Integer */
.highlight .mi { color: #2AA198 }
/* Literal.Number.Oct */
.highlight .mo { color: #2AA198 }
/* Literal.String.Backtick */
.highlight .sb { color: #586E75 }
/* Literal.String.Char */
.highlight .sc { color: #2AA198 }
/* Literal.String.Doc */
.highlight .sd { color: #93A1A1 }
/* Literal.String.Double */
.highlight .s2 { color: #2AA198 }
/* Literal.String.Escape */
.highlight .se { color: #CB4B16 }
/* Literal.String.Heredoc */
.highlight .sh { color: #93A1A1 }
/* Literal.String.Interpol */
.highlight .si { color: #2AA198 }
/* Literal.String.Other */
.highlight .sx { color: #2AA198 }
/* Literal.String.Regex */
.highlight .sr { color: #DC322F }
/* Literal.String.Single */
.highlight .s1 { color: #2AA198 }
/* Literal.String.Symbol */
.highlight .ss { color: #2AA198 }
/* Name.Builtin.Pseudo */
.highlight .bp { color: #268BD2 }
/* Name.Variable.Class */
.highlight .vc { color: #268BD2 }
/* Name.Variable.Global */
.highlight .vg { color: #268BD2 }
/* Name.Variable.Instance */
.highlight .vi { color: #268BD2 }
/* Literal.Number.Integer.Long */
.highlight .il { color: #2AA198 }