Compare commits
No commits in common. "source" and "master" have entirely different histories.
|
@ -1,22 +0,0 @@
|
|||
; This file is for unifying the coding style for different editors and IDEs.
|
||||
; More information at http://EditorConfig.org
|
||||
|
||||
root = true
|
||||
|
||||
; Use 2 spaces for indentation in all Ruby files
|
||||
|
||||
[*.rb]
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
|
||||
[Rakefile]
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
|
||||
[Gemfile*]
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
|
||||
[config.ru]
|
||||
indent_style = space
|
||||
indent_size = 2
|
|
@ -1 +0,0 @@
|
|||
* text=auto
|
|
@ -1,13 +0,0 @@
|
|||
.bundle
|
||||
.DS_Store
|
||||
.sass-cache
|
||||
.gist-cache
|
||||
.pygments-cache
|
||||
_deploy
|
||||
public
|
||||
sass.old
|
||||
source.old
|
||||
source/_stash
|
||||
source/stylesheets/screen.css
|
||||
vendor
|
||||
node_modules
|
5
.powrc
|
@ -1,5 +0,0 @@
|
|||
if [ -f "$rvm_path/scripts/rvm" ] && [ -f ".rvmrc" ] ; then
|
||||
source "$rvm_path/scripts/rvm"
|
||||
source ".rvmrc"
|
||||
fi
|
||||
|
|
@ -1 +0,0 @@
|
|||
1.9.3-p194
|
|
@ -1,3 +0,0 @@
|
|||
plugins
|
||||
sass
|
||||
source
|
|
@ -1,44 +0,0 @@
|
|||
; This file is for unifying the coding style for different editors and IDEs.
|
||||
; More information at http://EditorConfig.org
|
||||
|
||||
|
||||
; Use 2 spaces for indentation in SCSS, JavaScript, HTML, and XML
|
||||
|
||||
[*.scss]
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
|
||||
[*.js]
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
|
||||
[*.html]
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
|
||||
[*.xml]
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
|
||||
|
||||
; Use 4 spaces for indentation in Markdown files
|
||||
|
||||
[*.md]
|
||||
indent_style = space
|
||||
indent_size = 4
|
||||
|
||||
[*.markdown]
|
||||
indent_style = space
|
||||
indent_size = 4
|
||||
|
||||
|
||||
; Override default indentation for some library files
|
||||
|
||||
[jwplayer/glow/glow.xml]
|
||||
indent_style = tab
|
||||
|
||||
[libs/jXHR.js]
|
||||
indent_style = tab
|
||||
|
||||
[libs/swfobject-dynamic.js]
|
||||
indent_style = tab
|
|
@ -1,5 +0,0 @@
|
|||
@import "base/utilities";
|
||||
@import "base/solarized";
|
||||
@import "base/theme";
|
||||
@import "base/typography";
|
||||
@import "base/layout";
|
|
@ -1,8 +0,0 @@
|
|||
@import "partials/header";
|
||||
@import "partials/navigation";
|
||||
@import "partials/blog";
|
||||
@import "partials/sharing";
|
||||
@import "partials/syntax";
|
||||
@import "partials/archive";
|
||||
@import "partials/sidebar";
|
||||
@import "partials/footer";
|
|
@ -1,192 +0,0 @@
|
|||
$max-width: 1200px !default;
|
||||
|
||||
// Padding used for layout margins
|
||||
$pad-min: 18px !default;
|
||||
$pad-narrow: 25px !default;
|
||||
$pad-medium: 35px !default;
|
||||
$pad-wide: 55px !default;
|
||||
|
||||
// Sidebar widths used in media queries
|
||||
$sidebar-width-medium: 240px !default;
|
||||
$sidebar-pad-medium: 15px !default;
|
||||
$sidebar-pad-wide: 20px !default;
|
||||
$sidebar-width-wide: 300px !default;
|
||||
|
||||
$indented-lists: false !default;
|
||||
|
||||
$header-font-size: 1em !default;
|
||||
$header-padding-top: 1.5em !default;
|
||||
$header-padding-bottom: 1.5em !default;
|
||||
|
||||
.group { @include pie-clearfix; }
|
||||
|
||||
@mixin collapse-sidebar {
|
||||
float: none;
|
||||
width: auto;
|
||||
clear: left;
|
||||
margin: 0;
|
||||
padding: 0 $pad-medium 1px;
|
||||
background-color: lighten($sidebar-bg, 2);
|
||||
border-top: 1px solid lighten($sidebar-border, 4);
|
||||
section {
|
||||
&.odd, &.even { float: left; width: 48%; }
|
||||
&.odd { margin-left: 0; }
|
||||
&.even { margin-left: 4%; }
|
||||
}
|
||||
&.thirds section {
|
||||
width: 30%;
|
||||
margin-left: 5%;
|
||||
&.first {
|
||||
margin-left: 0;
|
||||
clear: both;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
body {
|
||||
-webkit-text-size-adjust: none;
|
||||
max-width: $max-width;
|
||||
position: relative;
|
||||
margin: 0 auto;
|
||||
> header, > nav, > footer, #content > article, #content > div > article, #content > div > section {
|
||||
@extend .group;
|
||||
padding-left: $pad-min;
|
||||
padding-right: $pad-min;
|
||||
@media only screen and (min-width: 480px) {
|
||||
padding-left: $pad-narrow;
|
||||
padding-right: $pad-narrow;
|
||||
}
|
||||
@media only screen and (min-width: 768px) {
|
||||
padding-left: $pad-medium;
|
||||
padding-right: $pad-medium;
|
||||
}
|
||||
@media only screen and (min-width: 992px) {
|
||||
padding-left: $pad-wide;
|
||||
padding-right: $pad-wide;
|
||||
}
|
||||
}
|
||||
div.pagination {
|
||||
@extend .group;
|
||||
margin-left: $pad-min;
|
||||
margin-right: $pad-min;
|
||||
@media only screen and (min-width: 480px) {
|
||||
margin-left: $pad-narrow;
|
||||
margin-right: $pad-narrow;
|
||||
}
|
||||
@media only screen and (min-width: 768px) {
|
||||
margin-left: $pad-medium;
|
||||
margin-right: $pad-medium;
|
||||
}
|
||||
@media only screen and (min-width: 992px) {
|
||||
margin-left: $pad-wide;
|
||||
margin-right: $pad-wide;
|
||||
}
|
||||
}
|
||||
> header {
|
||||
font-size: $header-font-size;
|
||||
padding-top: $header-padding-top;
|
||||
padding-bottom: $header-padding-bottom;
|
||||
}
|
||||
}
|
||||
|
||||
#content {
|
||||
overflow: hidden;
|
||||
> div, > article { width: 100%; }
|
||||
}
|
||||
|
||||
aside.sidebar {
|
||||
float: none;
|
||||
padding: 0 $pad-min 1px;
|
||||
background-color: lighten($sidebar-bg, 2);
|
||||
border-top: 1px solid $sidebar-border;
|
||||
@extend .group;
|
||||
}
|
||||
|
||||
.flex-content { max-width: 100%; height: auto; }
|
||||
|
||||
.basic-alignment {
|
||||
&.left { float: left; margin-right: 1.5em; }
|
||||
&.right { float: right; margin-left: 1.5em; }
|
||||
&.center { display:block; margin: 0 auto 1.5em; }
|
||||
&.left, &.right { margin-bottom: .8em; }
|
||||
}
|
||||
|
||||
.toggle-sidebar { &, .no-sidebar & { display: none; }}
|
||||
|
||||
body.sidebar-footer {
|
||||
@media only screen and (min-width: 750px) {
|
||||
aside.sidebar{ @include collapse-sidebar; }
|
||||
}
|
||||
#content { margin-right: 0px; }
|
||||
.toggle-sidebar { display: none; }
|
||||
}
|
||||
|
||||
@media only screen and (min-width: 550px) {
|
||||
body > header { font-size: $header-font-size; }
|
||||
}
|
||||
@media only screen and (min-width: 750px) {
|
||||
aside.sidebar { @include collapse-sidebar; }
|
||||
}
|
||||
#main, #content, .sidebar {
|
||||
@extend .group;
|
||||
}
|
||||
@media only screen and (min-width: 768px) {
|
||||
body { -webkit-text-size-adjust: auto; }
|
||||
body > header { font-size: $header-font-size * 1.2; }
|
||||
#main {
|
||||
padding: 0;
|
||||
margin: 0 auto;
|
||||
}
|
||||
#content {
|
||||
overflow: visible;
|
||||
margin-right: $sidebar-width-medium;
|
||||
position: relative;
|
||||
.no-sidebar & { margin-right: 0; border-right: 0; }
|
||||
.collapse-sidebar & { margin-right: 20px; }
|
||||
> div, > article {
|
||||
padding-top: $pad-medium/2;
|
||||
padding-bottom: $pad-medium/2;
|
||||
float: left;
|
||||
}
|
||||
}
|
||||
aside.sidebar {
|
||||
width: $sidebar-width-medium - $sidebar-pad-medium*2;
|
||||
padding: 0 $sidebar-pad-medium $sidebar-pad-medium;
|
||||
background: none;
|
||||
clear: none;
|
||||
float: left;
|
||||
margin: 0 -100% 0 0;
|
||||
section {
|
||||
width: auto; margin-left: 0;
|
||||
&.odd, &.even { float: none; width: auto; margin-left: 0; }
|
||||
}
|
||||
.collapse-sidebar & {
|
||||
@include collapse-sidebar;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@media only screen and (min-width: 992px) {
|
||||
body > header { font-size: $header-font-size * 1.3; }
|
||||
#content { margin-right: $sidebar-width-wide; }
|
||||
#content {
|
||||
> div, > article {
|
||||
padding-top: $pad-wide/2;
|
||||
padding-bottom: $pad-wide/2;
|
||||
}
|
||||
}
|
||||
aside.sidebar {
|
||||
width: $sidebar-width-wide - $sidebar-pad-wide*2;
|
||||
padding: 1.2em $sidebar-pad-wide $sidebar-pad-wide;
|
||||
.collapse-sidebar & {
|
||||
padding: { left: $pad-wide; right: $pad-wide; }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@if $indented-lists == false {
|
||||
@media only screen and (min-width: 768px) {
|
||||
ul, ol { margin-left: 0; }
|
||||
}
|
||||
}
|
||||
|
|
@ -1,46 +0,0 @@
|
|||
$base03: #002b36 !default; //darkest blue
|
||||
$base02: #073642 !default; //dark blue
|
||||
$base01: #586e75 !default; //darkest gray
|
||||
$base00: #657b83 !default; //dark gray
|
||||
$base0: #839496 !default; //medium gray
|
||||
$base1: #93a1a1 !default; //medium light gray
|
||||
$base2: #eee8d5 !default; //cream
|
||||
$base3: #fdf6e3 !default; //white
|
||||
$solar-yellow: #b58900 !default;
|
||||
$solar-orange: #cb4b16 !default;
|
||||
$solar-red: #dc322f !default;
|
||||
$solar-magenta: #d33682 !default;
|
||||
$solar-violet: #6c71c4 !default;
|
||||
$solar-blue: #268bd2 !default;
|
||||
$solar-cyan: #2aa198 !default;
|
||||
$solar-green: #859900 !default;
|
||||
|
||||
$solarized: dark !default;
|
||||
|
||||
@if $solarized == light {
|
||||
|
||||
$_base03: $base03;
|
||||
$_base02: $base02;
|
||||
$_base01: $base01;
|
||||
$_base00: $base00;
|
||||
$_base0: $base0;
|
||||
$_base1: $base1;
|
||||
$_base2: $base2;
|
||||
$_base3: $base3;
|
||||
|
||||
$base03: $_base3;
|
||||
$base02: $_base2;
|
||||
$base01: $_base1;
|
||||
$base00: $_base0;
|
||||
$base0: $_base00;
|
||||
$base1: $_base01;
|
||||
$base2: $_base02;
|
||||
$base3: $_base03;
|
||||
}
|
||||
|
||||
/* non highlighted code colors */
|
||||
$pre-bg: $base03 !default;
|
||||
$pre-border: darken($base02, 5) !default;
|
||||
$pre-color: $base1 !default;
|
||||
|
||||
|
|
@ -1,86 +0,0 @@
|
|||
$noise-bg: image-url('noise.png') top left !default;
|
||||
$img-border: inline-image('dotted-border.png');
|
||||
|
||||
// Main Link Colors
|
||||
$link-color: lighten(#165b94, 3) !default;
|
||||
$link-color-hover: adjust-color($link-color, $lightness: 10, $saturation: 25) !default;
|
||||
$link-color-visited: adjust-color($link-color, $hue: 80, $lightness: -4) !default;
|
||||
$link-color-active: adjust-color($link-color-hover, $lightness: -15) !default;
|
||||
|
||||
// Main Section Colors
|
||||
$main-bg: #f8f8f8 !default;
|
||||
$page-bg: #252525 !default;
|
||||
$article-border: #eeeeee !default;
|
||||
|
||||
$header-bg: #333 !default;
|
||||
$header-border: lighten($header-bg, 15) !default;
|
||||
$title-color: #f2f2f2 !default;
|
||||
$subtitle-color: #aaa !default;
|
||||
|
||||
$text-color: #222 !default;
|
||||
$text-color-light: #aaa !default;
|
||||
$type-border: #ddd !default;
|
||||
|
||||
/* Navigation */
|
||||
$nav-bg: #ccc !default;
|
||||
$nav-bg-front: image-url('noise.png') !default;
|
||||
$nav-bg-back: linear-gradient(lighten($nav-bg, 8), $nav-bg, darken($nav-bg, 11)) !default;
|
||||
$nav-color: darken($nav-bg, 38) !default;
|
||||
$nav-color-hover: darken($nav-color, 25) !default;
|
||||
$nav-placeholder: desaturate(darken($nav-bg, 10), 15) !default;
|
||||
$nav-border: darken($nav-bg, 10) !default;
|
||||
$nav-border-top: lighten($nav-bg, 15) !default;
|
||||
$nav-border-bottom: darken($nav-bg, 25) !default;
|
||||
$nav-border-left: darken($nav-bg, 11) !default;
|
||||
$nav-border-right: lighten($nav-bg, 7) !default;
|
||||
|
||||
/* Sidebar colors */
|
||||
$sidebar-bg: #f2f2f2 !default;
|
||||
$sidebar-link-color: $link-color !default;
|
||||
$sidebar-link-color-hover: $link-color-hover !default;
|
||||
$sidebar-link-color-active: $link-color-active !default;
|
||||
$sidebar-color: change-color(mix($text-color, $sidebar-bg, 80), $hue: hue($sidebar-bg), $saturation: saturation($sidebar-bg)/2) !default;
|
||||
$sidebar-border: desaturate(darken($sidebar-bg, 7), 10) !default;
|
||||
$sidebar-border-hover: darken($sidebar-bg, 7) !default;
|
||||
$sidebar-link-color-subdued: lighten($sidebar-color, 20) !default;
|
||||
$sidebar-link-color-subdued-hover: $sidebar-link-color-hover !default;
|
||||
$twitter-status-link: lighten($sidebar-link-color-subdued, 15) !default;
|
||||
|
||||
$footer-color: #888 !default;
|
||||
$footer-bg: #ccc !default;
|
||||
$footer-bg-front: image-url('noise.png') !default;
|
||||
$footer-bg-back: linear-gradient(lighten($footer-bg, 8), $footer-bg, darken($footer-bg, 11)) !default;
|
||||
$footer-color: darken($footer-bg, 38) !default;
|
||||
$footer-color-hover: darken($footer-color, 10) !default;
|
||||
$footer-border-top: lighten($footer-bg, 15) !default;
|
||||
$footer-border-bottom: darken($footer-bg, 15) !default;
|
||||
$footer-link-color: darken($footer-bg, 38) !default;
|
||||
$footer-link-color-hover: darken($footer-color, 25) !default;
|
||||
$page-border-bottom: darken($footer-bg, 5) !default;
|
||||
|
||||
|
||||
/* Core theme application */
|
||||
|
||||
a {
|
||||
@include link-colors($link-color, $hover: $link-color-hover, $focus: $link-color-hover, $visited: $link-color-visited, $active: $link-color-active);
|
||||
}
|
||||
aside.sidebar a {
|
||||
@include link-colors($sidebar-link-color, $hover: $sidebar-link-color-hover, $focus: $sidebar-link-color-hover, $active: $sidebar-link-color-active);
|
||||
}
|
||||
a {
|
||||
@include transition(color .3s);
|
||||
}
|
||||
|
||||
html {
|
||||
background: $page-bg image-url('line-tile.png') top left;
|
||||
}
|
||||
body {
|
||||
> div {
|
||||
background: $sidebar-bg $noise-bg;
|
||||
border-bottom: 1px solid $page-border-bottom;
|
||||
> div {
|
||||
background: $main-bg $noise-bg;
|
||||
border-right: 1px solid $sidebar-border;
|
||||
}
|
||||
}
|
||||
}
|
|
@ -1,162 +0,0 @@
|
|||
$blockquote: $type-border !default;
|
||||
$sans: "PT Sans", "Helvetica Neue", Arial, sans-serif !default;
|
||||
$serif: "PT Serif", Georgia, Times, "Times New Roman", serif !default;
|
||||
$mono: Menlo, Monaco, "Andale Mono", "lucida console", "Courier New", monospace !default;
|
||||
$heading-font-family: "PT Serif", "Georgia", "Helvetica Neue", Arial, sans-serif !default;
|
||||
$header-title-font-family: $heading-font-family !default;
|
||||
$header-subtitle-font-family: $heading-font-family !default;
|
||||
|
||||
// Fonts
|
||||
.heading {
|
||||
font-family: $heading-font-family;
|
||||
}
|
||||
.sans { font-family: $sans; }
|
||||
.serif { font-family: $serif; }
|
||||
.mono { font-family: $mono; }
|
||||
|
||||
body > header h1 {
|
||||
font-size: 2.2em;
|
||||
@extend .heading;
|
||||
font-family: $header-title-font-family;
|
||||
font-weight: normal;
|
||||
line-height: 1.2em;
|
||||
margin-bottom: 0.6667em;
|
||||
}
|
||||
body > header h2 {
|
||||
font-family: $header-subtitle-font-family;
|
||||
}
|
||||
|
||||
body {
|
||||
line-height: 1.5em;
|
||||
color: $text-color;
|
||||
@extend .serif;
|
||||
}
|
||||
h1 {
|
||||
font-size: 2.2em;
|
||||
line-height: 1.2em;
|
||||
}
|
||||
|
||||
@media only screen and (min-width: 992px) {
|
||||
body { font-size: 1.15em; }
|
||||
h1 { font-size: 2.6em; line-height: 1.2em; }
|
||||
}
|
||||
|
||||
#{headings()}{
|
||||
@extend .heading;
|
||||
text-rendering: optimizelegibility;
|
||||
margin-bottom: 1em;
|
||||
font-weight: bold;
|
||||
}
|
||||
h2, section h1 {
|
||||
font-size: 1.5em;
|
||||
}
|
||||
h3, section h2, section section h1 {
|
||||
font-size: 1.3em;
|
||||
}
|
||||
h4, section h3, section section h2, section section section h1 {
|
||||
font-size: 1em;
|
||||
}
|
||||
h5, section h4, section section h3 {
|
||||
font-size: .9em;
|
||||
}
|
||||
h6, section h5, section section h4, section section section h3 {
|
||||
font-size: .8em;
|
||||
}
|
||||
p, blockquote, ul, ol { margin-bottom: 1.5em; }
|
||||
|
||||
ul { list-style-type: disc;
|
||||
ul { list-style-type: circle; margin-bottom: 0px;
|
||||
ul { list-style-type: square; margin-bottom: 0px; }}}
|
||||
|
||||
ol { list-style-type: decimal;
|
||||
ol { list-style-type: lower-alpha; margin-bottom: 0px;
|
||||
ol { list-style-type: lower-roman; margin-bottom: 0px; }}}
|
||||
|
||||
ul, ol { &, ul, ol { margin-left: 1.3em; }}
|
||||
ul, ol { ul, ol { margin-bottom: 0em; }}
|
||||
|
||||
strong { font-weight: bold; }
|
||||
|
||||
em { font-style: italic; }
|
||||
|
||||
sup, sub { font-size: 0.8em; position: relative; display: inline-block; }
|
||||
sup { top: -.5em; }
|
||||
sub { bottom: -.5em; }
|
||||
|
||||
q { font-style: italic;
|
||||
&:before { content: "\201C"; }
|
||||
&:after { content: "\201D"; }
|
||||
}
|
||||
|
||||
em, dfn { font-style: italic; }
|
||||
|
||||
strong, dfn { font-weight: bold; }
|
||||
|
||||
del, s { text-decoration: line-through; }
|
||||
|
||||
abbr, acronym { border-bottom: 1px dotted; cursor: help; }
|
||||
|
||||
pre, code, tt { @extend .mono; }
|
||||
|
||||
sub, sup { line-height: 0; }
|
||||
|
||||
hr { margin-bottom: 0.2em; }
|
||||
|
||||
small { font-size: .8em; }
|
||||
|
||||
big { font-size: 1.2em; }
|
||||
|
||||
blockquote {
|
||||
$bq-margin: 1.2em;
|
||||
font-style: italic;
|
||||
position: relative;
|
||||
font-size: 1.2em;
|
||||
line-height: 1.5em;
|
||||
padding-left: 1em;
|
||||
border-left: 4px solid rgba($text-color-light, .5);
|
||||
cite {
|
||||
font-style: italic;
|
||||
a { color: $text-color-light !important; word-wrap: break-word; }
|
||||
&:before { content: '\2014'; padding:{right: .3em; left: .3em;} color: $text-color-light; }
|
||||
}
|
||||
@media only screen and (min-width: 992px) {
|
||||
padding-left: 1.5em;
|
||||
border-left-width: 4px;
|
||||
}
|
||||
}
|
||||
|
||||
.pullquote-right:before,
|
||||
.pullquote-left:before {
|
||||
/* Reset metrics. */
|
||||
padding: 0;
|
||||
border: none;
|
||||
|
||||
/* Content */
|
||||
content: attr(data-pullquote);
|
||||
|
||||
/* Pull out to the right, modular scale based margins. */
|
||||
float: right;
|
||||
width: 45%;
|
||||
margin: .5em 0 1em 1.5em;
|
||||
|
||||
/* Baseline correction */
|
||||
position: relative;
|
||||
top: 7px;
|
||||
font-size: 1.4em;
|
||||
line-height: 1.45em;
|
||||
}
|
||||
|
||||
.pullquote-left:before {
|
||||
/* Make left pullquotes align properly. */
|
||||
float: left;
|
||||
margin: .5em 1.5em 1em 0;
|
||||
}
|
||||
|
||||
/* @extend this to force long lines of continuous text to wrap */
|
||||
.force-wrap {
|
||||
white-space: -moz-pre-wrap;
|
||||
white-space: -pre-wrap;
|
||||
white-space: -o-pre-wrap;
|
||||
white-space: pre-wrap;
|
||||
word-wrap: break-word;
|
||||
}
|
|
@ -1,28 +0,0 @@
|
|||
@mixin mask-image($img, $repeat: no-repeat){
|
||||
@include experimental(mask-image, image-url($img), -webkit, -moz, -o, -ms);
|
||||
@include experimental(mask-repeat, $repeat, -webkit, -moz, -o, -ms);
|
||||
width: image-width($img);
|
||||
height: image-height($img);
|
||||
}
|
||||
|
||||
@mixin shadow-box($border: #fff .5em solid, $shadow: rgba(#000, .15) 0 1px 4px, $border-radius: .3em) {
|
||||
@include border-radius($border-radius);
|
||||
@include box-shadow($shadow);
|
||||
@include box-sizing(border-box);
|
||||
border: $border;
|
||||
}
|
||||
|
||||
@mixin selection($bg, $color: inherit, $text-shadow: none){
|
||||
* {
|
||||
&::-moz-selection { background: $bg; color: $color; text-shadow: $text-shadow; }
|
||||
&::-webkit-selection { background: $bg; color: $color; text-shadow: $text-shadow; }
|
||||
&::selection { background: $bg; color: $color; text-shadow: $text-shadow; }
|
||||
}
|
||||
}
|
||||
|
||||
@function text-color($color, $dark: dark, $light: light){
|
||||
$text-color: ( (red($color)*299) + (green($color)*587) + (blue($color)*114) ) / 1000;
|
||||
$text-color: if($text-color >= 150, $dark, $light);
|
||||
@return $text-color;
|
||||
}
|
||||
|
|
@ -1,43 +0,0 @@
|
|||
// Here you can easily change your sites's color scheme.
|
||||
// To give it a try, uncomment some of the lines below rebuild your blog, and see how it works.
|
||||
// If you need a handy color picker try http://hslpicker.com
|
||||
|
||||
//$header-bg: #263347;
|
||||
//$subtitle-color: lighten($header-bg, 58);
|
||||
//$nav-bg: desaturate(lighten(#8fc17a, 18), 5);
|
||||
//$nav-bg-front: image-url('noise.png');
|
||||
//$nav-bg-back: linear-gradient(lighten($nav-bg, 8), $nav-bg, darken($nav-bg, 11));
|
||||
//$sidebar-bg: desaturate(#eceff5, 8);
|
||||
//$sidebar-link-color: saturate(#526f9a, 10);
|
||||
//$sidebar-link-color-hover: darken(#7ab662, 9);
|
||||
//$footer-bg: #ccc !default;
|
||||
//$footer-bg-front: image-url('noise.png');
|
||||
//$footer-bg-back: linear-gradient(lighten($footer-bg, 8), $footer-bg, darken($footer-bg, 11));
|
||||
|
||||
|
||||
/* To use the light Solarized highlighting theme uncomment the following line */
|
||||
//$solarized: light;
|
||||
|
||||
/* If you want to tweak the Solarized colors you can do that here */
|
||||
//$base03: #002b36; //darkest blue
|
||||
//$base02: #073642; //dark blue
|
||||
//$base01: #586e75; //darkest gray
|
||||
//$base00: #657b83; //dark gray
|
||||
//$base0: #839496; //medium gray
|
||||
//$base1: #93a1a1; //medium light gray
|
||||
//$base2: #eee8d5; //cream
|
||||
//$base3: #fdf6e3; //white
|
||||
//$solar-yellow: #b58900;
|
||||
//$solar-orange: #cb4b16;
|
||||
//$solar-red: #dc322f;
|
||||
//$solar-magenta: #d33682;
|
||||
//$solar-violet: #6c71c4;
|
||||
//$solar-blue: #268bd2;
|
||||
//$solar-cyan: #2aa198;
|
||||
//$solar-green: #859900;
|
||||
|
||||
|
||||
/* Non highlighted code colors */
|
||||
//$pre-bg: $base03;
|
||||
//$pre-border: darken($base02, 5);
|
||||
//$pre-color: $base1;
|
|
@ -1,10 +0,0 @@
|
|||
// Here you can easily change font faces which are used in your site.
|
||||
// To give it a try, uncomment some of the lines below rebuild your blog, and see how it works. your sites's.
|
||||
// If you love to use Web Fonts, you also need to add some lines to source/_includes/custom/head.html
|
||||
|
||||
//$sans: "Optima", sans-serif;
|
||||
//$serif: "Baskerville", serif;
|
||||
//$mono: "Courier", monospace;
|
||||
//$heading-font-family: "Verdana", sans-serif;
|
||||
//$header-title-font-family: "Futura", sans-serif;
|
||||
//$header-subtitle-font-family: "Futura", sans-serif;
|
|
@ -1,21 +0,0 @@
|
|||
// Here you can easily change your sites's layout.
|
||||
// To give it a try, uncomment some of the lines below, make changes, rebuild your blog, and see how it works.
|
||||
|
||||
//$header-font-size: 1em;
|
||||
//$header-padding-top: 1.5em;
|
||||
//$header-padding-bottom: 1.5em;
|
||||
|
||||
//$max-width: 1350px;
|
||||
//$indented-lists: true;
|
||||
|
||||
// Padding used for layout margins
|
||||
//$pad-min: 18px;
|
||||
//$pad-narrow: 25px;
|
||||
//$pad-medium: 35px;
|
||||
//$pad-wide: 55px;
|
||||
|
||||
// Sidebar widths used in media queries
|
||||
//$sidebar-width-medium: 240px;
|
||||
//$sidebar-pad-medium: 15px;
|
||||
//$sidebar-pad-wide: 20px;
|
||||
//$sidebar-width-wide: 300px;
|
|
@ -1,2 +0,0 @@
|
|||
// This File is imported last, and will override other styles in the cascade
|
||||
// Add styles here to make changes without digging in too much
|
|
@ -1,72 +0,0 @@
|
|||
#archive {
|
||||
#content > div { &, > article { padding-top: 0; } }
|
||||
}
|
||||
#blog-archives {
|
||||
article {
|
||||
padding: 1em 0 1em;
|
||||
position: relative;
|
||||
background: $img-border bottom left repeat-x;
|
||||
&:last-child {
|
||||
background: none;
|
||||
}
|
||||
footer { padding: 0; margin: 0;}
|
||||
}
|
||||
h1 { color: $text-color; margin-bottom: .3em; }
|
||||
h2 { display: none; }
|
||||
h1 {
|
||||
font-size: 1.5em;
|
||||
a {
|
||||
@include hover-link;
|
||||
color: inherit;
|
||||
&:hover { color: $link-color-hover; }
|
||||
font-weight: normal;
|
||||
display: inline-block;
|
||||
}
|
||||
}
|
||||
a.category, time {
|
||||
@extend .sans;
|
||||
color: $text-color-light;
|
||||
}
|
||||
color: $text-color-light;
|
||||
.entry-content { display: none; }
|
||||
time {
|
||||
font-size: .9em;
|
||||
line-height: 1.2em;
|
||||
.month, .day { display: inline-block; }
|
||||
.month { text-transform: uppercase; }
|
||||
}
|
||||
p { margin-bottom: 1em; }
|
||||
&, .entry-content { a { @include link-colors(inherit, $link-color-hover); }}
|
||||
a:hover { color: $link-color-hover; }
|
||||
@media only screen and (min-width: 550px) {
|
||||
article { margin-left: 5em; }
|
||||
h2 {
|
||||
margin-bottom: .3em;
|
||||
font-weight: normal;
|
||||
display: inline-block;
|
||||
position: relative; top: -1px;
|
||||
float: left;
|
||||
&:first-child { padding-top: .75em; }
|
||||
}
|
||||
time {
|
||||
position: absolute;
|
||||
text-align: right;
|
||||
left: 0em;
|
||||
top: 1.8em;
|
||||
}
|
||||
.year { display: none; }
|
||||
article {
|
||||
padding:{left: 4.5em; bottom: .7em;}
|
||||
}
|
||||
a.category {
|
||||
line-height: 1.1em;
|
||||
}
|
||||
}
|
||||
}
|
||||
#content > .category {
|
||||
article {
|
||||
margin-left: 0;
|
||||
padding-left: 6.8em;
|
||||
}
|
||||
.year { display: inline; }
|
||||
}
|
|
@ -1,141 +0,0 @@
|
|||
article {
|
||||
padding-top: 1em;
|
||||
a { @extend .force-wrap; }
|
||||
header {
|
||||
position: relative;
|
||||
padding-top: 2em;
|
||||
padding-bottom: 1em;
|
||||
margin-bottom: 1em;
|
||||
background: $img-border bottom left repeat-x;
|
||||
h1 {
|
||||
margin: 0;
|
||||
a { text-decoration: none;
|
||||
&:hover { text-decoration: underline; } }
|
||||
}
|
||||
p {
|
||||
font-size: .9em;
|
||||
color: $text-color-light;
|
||||
margin: 0;
|
||||
&.meta {
|
||||
@extend .sans;
|
||||
text-transform: uppercase;
|
||||
position: absolute; top: 0;
|
||||
}
|
||||
}
|
||||
@media only screen and (min-width: 768px) {
|
||||
margin-bottom: 1.5em;
|
||||
padding-bottom: 1em;
|
||||
background: $img-border bottom left repeat-x;
|
||||
}
|
||||
}
|
||||
h2 {
|
||||
padding-top: 0.8em;
|
||||
background: $img-border top left repeat-x;
|
||||
}
|
||||
.entry-content & h2:first-child, header + h2 { padding-top: 0; }
|
||||
h2:first-child, header + h2 { background: none; }
|
||||
.feature {
|
||||
padding-top: .5em;
|
||||
margin-bottom: 1em;
|
||||
padding-bottom: 1em;
|
||||
background: $img-border bottom left repeat-x;
|
||||
font-size: 2.0em; font-style: italic;
|
||||
line-height: 1.3em;
|
||||
}
|
||||
img, video, .flash-video {
|
||||
@extend .flex-content;
|
||||
@extend .basic-alignment;
|
||||
@include shadow-box;
|
||||
}
|
||||
video, .flash-video { margin: 0 auto 1.5em; }
|
||||
video { display: block; width: 100%; }
|
||||
.flash-video {
|
||||
> div {
|
||||
position: relative;
|
||||
display: block;
|
||||
padding-bottom: 56.25%;
|
||||
padding-top: 1px;
|
||||
height: 0;
|
||||
overflow: hidden;
|
||||
iframe, object, embed {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
}
|
||||
> footer {
|
||||
padding-bottom: 2.5em;
|
||||
margin-top: 2em;
|
||||
@extend .sans;
|
||||
p.meta {
|
||||
margin-bottom: .8em;
|
||||
font-size: .85em;
|
||||
clear: both;
|
||||
overflow: hidden;
|
||||
}
|
||||
.byline + time:before, time +time:before, .comments:before, .byline ~ .categories:before {
|
||||
@extend .separator;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
article + article {
|
||||
.blog-index & {
|
||||
background: $img-border top left repeat-x;
|
||||
}
|
||||
}
|
||||
#content .blog-index {
|
||||
padding: { top: 0; bottom: 0; }
|
||||
article { padding-top: 2em; }
|
||||
article header { background: none; padding-bottom: 0; }
|
||||
article h1 {
|
||||
font-size: 2.2em;
|
||||
a { color: inherit; &:hover { color: $link-color-hover; } }
|
||||
}
|
||||
a[rel=full-article] {
|
||||
background: darken($main-bg, 5);
|
||||
display: inline-block;
|
||||
padding: .4em .8em;
|
||||
margin-right: .5em;
|
||||
text-decoration: none;
|
||||
color: mix($text-color, $text-color-light);
|
||||
@extend .serif;
|
||||
@include transition(background-color .5s);
|
||||
&:hover {
|
||||
background: $link-color-hover;
|
||||
text-shadow: none;
|
||||
color: $main-bg;
|
||||
}
|
||||
}
|
||||
footer {
|
||||
@extend .sans;
|
||||
margin-top: 1em;
|
||||
}
|
||||
}
|
||||
|
||||
.separator {
|
||||
content: "\2022 ";
|
||||
padding: 0 .4em 0 .2em;
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
#content div.pagination {
|
||||
text-align: center;
|
||||
font-size: .95em;
|
||||
position: relative;
|
||||
background: $img-border top left repeat-x;
|
||||
padding: {top: 1.5em; bottom: 1.5em;}
|
||||
a {
|
||||
text-decoration: none;
|
||||
color: $text-color-light;
|
||||
&.prev { position: absolute; left: 0; }
|
||||
&.next { position: absolute; right: 0; }
|
||||
&:hover { color: $link-color-hover; }
|
||||
&[href*=archive] {
|
||||
&:before, &:after { content: '\2014'; padding: 0 .3em; }
|
||||
}
|
||||
}
|
||||
}
|
|
@ -1,19 +0,0 @@
|
|||
body > footer {
|
||||
@extend .sans;
|
||||
font-size: .8em;
|
||||
color: $footer-color;
|
||||
text-shadow: lighten($footer-bg, 5) 0 1px;
|
||||
background-color: $footer-bg;
|
||||
@include background($footer-bg-front, $footer-bg-back);
|
||||
border-top: 1px solid $footer-border-top;
|
||||
position: relative;
|
||||
padding-top: 1em;
|
||||
padding-bottom: 1em;
|
||||
margin-bottom: 3em;
|
||||
@include border-bottom-radius(.4em);
|
||||
z-index: 1;
|
||||
a {
|
||||
@include link-colors($footer-link-color, $footer-link-color-hover, $visited: $footer-link-color);
|
||||
}
|
||||
p:last-child { margin-bottom: 0; }
|
||||
}
|
|
@ -1,18 +0,0 @@
|
|||
body > header {
|
||||
background: $header-bg;
|
||||
h1 {
|
||||
display: inline-block;
|
||||
margin: 0;
|
||||
a, a:visited, a:hover {
|
||||
color: $title_color;
|
||||
text-decoration: none;
|
||||
}
|
||||
}
|
||||
h2 {
|
||||
margin: .2em 0 0;
|
||||
@extend .sans;
|
||||
font-size: 1em;
|
||||
color: $subtitle-color;
|
||||
font-weight: normal;
|
||||
}
|
||||
}
|
|
@ -1,137 +0,0 @@
|
|||
body > nav {
|
||||
position: relative;
|
||||
background-color: $nav-bg;
|
||||
@include background($nav-bg-front, $nav-bg-back);
|
||||
border: {
|
||||
top: 1px solid $nav-border-top;
|
||||
bottom: 1px solid $nav-border-bottom; }
|
||||
padding-top: .35em;
|
||||
padding-bottom: .35em;
|
||||
form {
|
||||
@include background-clip(padding-box);
|
||||
margin: 0; padding: 0;
|
||||
.search {
|
||||
padding: .3em .5em 0;
|
||||
font-size: .85em;
|
||||
font-family: $sans;
|
||||
line-height: 1.1em;
|
||||
width: 95%;
|
||||
@include border-radius(.5em);
|
||||
@include background-clip(padding-box);
|
||||
@include box-shadow(lighten($nav-bg, 2) 0 1px);
|
||||
background-color: lighten($nav-bg, 15);
|
||||
border: 1px solid $nav-border;
|
||||
color: #888;
|
||||
&:focus {
|
||||
color: #444;
|
||||
border-color: #80b1df;
|
||||
@include box-shadow(#80b1df 0 0 4px, #80b1df 0 0 3px inset);
|
||||
background-color: #fff;
|
||||
outline: none;
|
||||
}
|
||||
}
|
||||
}
|
||||
fieldset[role=search]{ float: right; width: 48%; }
|
||||
fieldset.mobile-nav{ float: left; width: 48%;
|
||||
select{ width: 100%; font-size: .8em; border: 1px solid #888;}
|
||||
}
|
||||
ul { display: none; }
|
||||
@media only screen and (min-width: 550px) {
|
||||
font-size: .9em;
|
||||
ul {
|
||||
@include horizontal-list(0);
|
||||
float: left;
|
||||
display: block;
|
||||
padding-top: .15em;
|
||||
}
|
||||
ul.subscription {
|
||||
margin-left: .8em;
|
||||
float: right;
|
||||
li:last-child a { padding-right: 0; }
|
||||
}
|
||||
ul li {
|
||||
margin: 0;
|
||||
}
|
||||
a {
|
||||
@include link-colors($nav-color, $nav-color-hover, $visited: $nav-color);
|
||||
font-family: $sans;
|
||||
text-shadow: lighten($nav-bg, 12) 0 1px;
|
||||
float: left;
|
||||
text-decoration: none;
|
||||
font-size: 1.1em;
|
||||
padding: .1em 0;
|
||||
line-height: 1.5em;
|
||||
}
|
||||
li + li {
|
||||
border-left: 1px solid $nav-border-left;
|
||||
margin-left: .8em;
|
||||
a {
|
||||
padding-left: .8em;
|
||||
border-left: 1px solid $nav-border-right;
|
||||
}
|
||||
}
|
||||
form {
|
||||
float: right;
|
||||
text-align: left;
|
||||
padding-left: .8em;
|
||||
width: $sidebar-width-medium - $pad-medium*2 - $sidebar-pad-medium + 20px;
|
||||
.search {
|
||||
width: 93%;
|
||||
font-size: .95em;
|
||||
line-height: 1.2em;
|
||||
}
|
||||
}
|
||||
ul[data-subscription$=email] + form {
|
||||
width: $sidebar-width-medium - $pad-medium*2 - $sidebar-pad-medium - 58px;
|
||||
.search { width: 91%; }
|
||||
}
|
||||
fieldset.mobile-nav { display: none; }
|
||||
fieldset[role=search]{ width: 99%; }
|
||||
}
|
||||
@media only screen and (min-width: 992px) {
|
||||
form {
|
||||
width: $sidebar-width-wide - $pad-wide - $sidebar-pad-wide*2 + 10px;
|
||||
}
|
||||
ul[data-subscription$=email] + form {
|
||||
width: $sidebar-width-wide - $pad-wide - $sidebar-pad-wide*2 - 58px;
|
||||
}
|
||||
}
|
||||
}
|
||||
.no-placeholder {
|
||||
body > nav .search {
|
||||
background: lighten($nav-bg, 15) image-url('search.png') .3em .25em no-repeat;
|
||||
text-indent: 1.3em;
|
||||
}
|
||||
}
|
||||
@mixin mask-subscription-nav($feed: 'rss.png'){
|
||||
position: relative; top: 0px;
|
||||
text-indent: -999999em;
|
||||
background-color: $nav-border-right;
|
||||
border: 0;
|
||||
padding: 0;
|
||||
&,&:after { @include mask-image($feed); }
|
||||
&:after {
|
||||
content: "";
|
||||
position: absolute; top: -1px; left: 0;
|
||||
background-color: lighten($nav-color, 25);
|
||||
}
|
||||
&:hover:after { background-color: lighten($nav-color, 20); }
|
||||
}
|
||||
.maskImage {
|
||||
body > nav {
|
||||
@media only screen and (min-width: 550px) {
|
||||
ul[data-subscription$=email] + form {
|
||||
width: $sidebar-width-medium - $pad-medium*2 - $sidebar-pad-medium - 32px;
|
||||
}
|
||||
}
|
||||
@media only screen and (min-width: 992px) {
|
||||
ul[data-subscription$=email] + form {
|
||||
width: $sidebar-width-wide - $pad-wide - $sidebar-pad-wide*2 - 32px;
|
||||
}
|
||||
}
|
||||
}
|
||||
ul.subscription { position: relative; top: .2em; li, a { border: 0; padding: 0; }}
|
||||
a[rel=subscribe-rss]{ @include mask-subscription-nav('rss.png'); }
|
||||
a[rel=subscribe-email]{ @include mask-subscription-nav('email.png'); }
|
||||
}
|
||||
|
|
@ -1,8 +0,0 @@
|
|||
.sharing {
|
||||
p.meta + & {
|
||||
padding: { top: 1em; left: 0; }
|
||||
background: $img-border top left repeat-x;
|
||||
}
|
||||
}
|
||||
|
||||
#fb-root { display: none; }
|
|
@ -1,5 +0,0 @@
|
|||
@import "sidebar/base";
|
||||
@import "sidebar/twitter";
|
||||
@import "sidebar/googleplus";
|
||||
@import "sidebar/pinboard";
|
||||
@import "sidebar/delicious";
|
|
@ -1,261 +0,0 @@
|
|||
.highlight, html .gist .gist-file .gist-syntax .gist-highlight {
|
||||
table td.code { width: 100%; }
|
||||
border: 1px solid $pre-border !important;
|
||||
}
|
||||
.highlight .line-numbers, html .gist .gist-file .gist-syntax .highlight .line_numbers {
|
||||
text-align: right;
|
||||
font-size: 13px;
|
||||
line-height: 1.45em;
|
||||
@if $solarized == light {
|
||||
background: lighten($base03, 1) $noise-bg !important;
|
||||
border-right: 1px solid darken($base02, 2) !important;
|
||||
@include box-shadow(lighten($base03, 2) -1px 0 inset);
|
||||
text-shadow: lighten($base02, 2) 0 -1px;
|
||||
} @else {
|
||||
background: $base02 $noise-bg !important;
|
||||
border-right: 1px solid darken($base03, 2) !important;
|
||||
@include box-shadow(lighten($base02, 2) -1px 0 inset);
|
||||
text-shadow: darken($base02, 10) 0 -1px;
|
||||
}
|
||||
span { color: $base01 !important; }
|
||||
padding: .8em !important;
|
||||
@include border-radius(0);
|
||||
}
|
||||
|
||||
figure.code, .gist-file, pre {
|
||||
@include box-shadow(rgba(#000, .06) 0 0 10px);
|
||||
.highlight pre { @include box-shadow(none); }
|
||||
}
|
||||
|
||||
.gist .highlight, figure.code .highlight {
|
||||
@include selection(adjust-color($base03, $lightness: 23%, $saturation: -65%), $text-shadow: $base03 0 1px);
|
||||
}
|
||||
html .gist .gist-file {
|
||||
margin-bottom: 1.8em;
|
||||
position: relative;
|
||||
border: none;
|
||||
padding-top: image-height("code_bg.png") !important;
|
||||
.highlight {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
.gist-syntax {
|
||||
border-bottom: 0 !important;
|
||||
background: none !important;
|
||||
.gist-highlight {
|
||||
background: $base03 !important;
|
||||
}
|
||||
.highlight pre {
|
||||
@extend .pre-code;
|
||||
padding: 0;
|
||||
}
|
||||
}
|
||||
.gist-meta {
|
||||
padding: .6em 0.8em;
|
||||
border: 1px solid lighten($base02, 2) !important;
|
||||
color: $base01;
|
||||
font-size: .7em !important;
|
||||
@if $solarized == light {
|
||||
background: lighten($base03, 2) $noise-bg;
|
||||
border: 1px solid $pre-border !important;
|
||||
border-top: 1px solid lighten($base03, 2) !important;
|
||||
} @else {
|
||||
background: $base02 $noise-bg;
|
||||
}
|
||||
@extend .sans;
|
||||
line-height: 1.5em;
|
||||
a {
|
||||
color: mix($base1, $base01) !important;
|
||||
@include hover-link;
|
||||
&:hover { color: $base1 !important; }
|
||||
}
|
||||
a[href*='#file'] {
|
||||
position: absolute; top: 0; left:0; right:-10px;
|
||||
color: #474747 !important;
|
||||
@extend .code-title;
|
||||
&:hover { color: $link-color !important; }
|
||||
}
|
||||
a[href*=raw]{
|
||||
@extend .download-source;
|
||||
top: .4em;
|
||||
}
|
||||
}
|
||||
}
|
||||
pre {
|
||||
background: $pre-bg $noise-bg;
|
||||
@include border-radius(.4em);
|
||||
@extend .mono;
|
||||
border: 1px solid $pre-border;
|
||||
line-height: 1.45em;
|
||||
font-size: 13px;
|
||||
margin-bottom: 2.1em;
|
||||
padding: .8em 1em;
|
||||
color: $pre-color;
|
||||
overflow: auto;
|
||||
}
|
||||
h3.filename {
|
||||
@extend .code-title;
|
||||
+ pre { @include border-top-radius(0px); }
|
||||
}
|
||||
|
||||
p, li {
|
||||
code {
|
||||
@extend .mono;
|
||||
display: inline-block;
|
||||
white-space: no-wrap;
|
||||
background: #fff;
|
||||
font-size: .8em;
|
||||
line-height: 1.5em;
|
||||
color: #555;
|
||||
border: 1px solid #ddd;
|
||||
@include border-radius(.4em);
|
||||
padding: 0 .3em;
|
||||
margin: -1px 0;
|
||||
}
|
||||
pre code { font-size: 1em !important; background: none; border: none; }
|
||||
}
|
||||
|
||||
.pre-code {
|
||||
font-family: $mono !important;
|
||||
overflow: scroll;
|
||||
overflow-y: hidden;
|
||||
display: block;
|
||||
padding: .8em;
|
||||
overflow-x: auto;
|
||||
line-height: 1.45em;
|
||||
background: $base03 $noise-bg !important;
|
||||
color: $base1 !important;
|
||||
span { color: $base1 !important; }
|
||||
span { font-style: normal !important; font-weight: normal !important; }
|
||||
|
||||
.c { color: $base01 !important; font-style: italic !important; } /* Comment */
|
||||
.cm { color: $base01 !important; font-style: italic !important; } /* Comment.Multiline */
|
||||
.cp { color: $base01 !important; font-style: italic !important; } /* Comment.Preproc */
|
||||
.c1 { color: $base01 !important; font-style: italic !important; } /* Comment.Single */
|
||||
.cs { color: $base01 !important; font-weight: bold !important; font-style: italic !important; } /* Comment.Special */
|
||||
.err { color: $solar-red !important; background: none !important; } /* Error */
|
||||
.k { color: $solar-orange !important; } /* Keyword */
|
||||
.o { color: $base1 !important; font-weight: bold !important; } /* Operator */
|
||||
.p { color: $base1 !important; } /* Operator */
|
||||
.ow { color: $solar-cyan !important; font-weight: bold !important; } /* Operator.Word */
|
||||
.gd { color: $base1 !important; background-color: mix($solar-red, $base03, 25%) !important; display: inline-block; } /* Generic.Deleted */
|
||||
.gd .x { color: $base1 !important; background-color: mix($solar-red, $base03, 35%) !important; display: inline-block; } /* Generic.Deleted.Specific */
|
||||
.ge { color: $base1 !important; font-style: italic !important; } /* Generic.Emph */
|
||||
//.gr { color: #aa0000 } /* Generic.Error */
|
||||
.gh { color: $base01 !important; } /* Generic.Heading */
|
||||
.gi { color: $base1 !important; background-color: mix($solar-green, $base03, 20%) !important; display: inline-block; } /* Generic.Inserted */
|
||||
.gi .x { color: $base1 !important; background-color: mix($solar-green, $base03, 40%) !important; display: inline-block; } /* Generic.Inserted.Specific */
|
||||
//.go { color: #888888 } /* Generic.Output */
|
||||
//.gp { color: #555555 } /* Generic.Prompt */
|
||||
.gs { color: $base1 !important; font-weight: bold !important; } /* Generic.Strong */
|
||||
.gu { color: $solar-violet !important; } /* Generic.Subheading */
|
||||
//.gt { color: #aa0000 } /* Generic.Traceback */
|
||||
.kc { color: $solar-green !important; font-weight: bold !important; } /* Keyword.Constant */
|
||||
.kd { color: $solar-blue !important; } /* Keyword.Declaration */
|
||||
.kp { color: $solar-orange !important; font-weight: bold !important; } /* Keyword.Pseudo */
|
||||
.kr { color: $solar-magenta !important; font-weight: bold !important; } /* Keyword.Reserved */
|
||||
.kt { color: $solar-cyan !important; } /* Keyword.Type */
|
||||
.n { color: $solar-blue !important; }
|
||||
.na { color: $solar-blue !important; } /* Name.Attribute */
|
||||
.nb { color: $solar-green !important; } /* Name.Builtin */
|
||||
.nc { color: $solar-magenta !important;} /* Name.Class */
|
||||
.no { color: $solar-yellow !important; } /* Name.Constant */
|
||||
//.ni { color: #800080 } /* Name.Entity */
|
||||
.nl { color: $solar-green !important; }
|
||||
.ne { color: $solar-blue !important; font-weight: bold !important; } /* Name.Exception */
|
||||
.nf { color: $solar-blue !important; font-weight: bold !important; } /* Name.Function */
|
||||
.nn { color: $solar-yellow !important; } /* Name.Namespace */
|
||||
.nt { color: $solar-blue !important; font-weight: bold !important; } /* Name.Tag */
|
||||
.nx { color: $solar-yellow !Important; }
|
||||
//.bp { color: #999999 } /* Name.Builtin.Pseudo */
|
||||
//.vc { color: #008080 } /* Name.Variable.Class */
|
||||
.vg { color: $solar-blue !important; } /* Name.Variable.Global */
|
||||
.vi { color: $solar-blue !important; } /* Name.Variable.Instance */
|
||||
.nv { color: $solar-blue !important; } /* Name.Variable */
|
||||
//.w { color: #bbbbbb } /* Text.Whitespace */
|
||||
.mf { color: $solar-cyan !important; } /* Literal.Number.Float */
|
||||
.m { color: $solar-cyan !important; } /* Literal.Number */
|
||||
.mh { color: $solar-cyan !important; } /* Literal.Number.Hex */
|
||||
.mi { color: $solar-cyan !important; } /* Literal.Number.Integer */
|
||||
//.mo { color: #009999 } /* Literal.Number.Oct */
|
||||
.s { color: $solar-cyan !important; } /* Literal.String */
|
||||
//.sb { color: #d14 } /* Literal.String.Backtick */
|
||||
//.sc { color: #d14 } /* Literal.String.Char */
|
||||
.sd { color: $solar-cyan !important; } /* Literal.String.Doc */
|
||||
.s2 { color: $solar-cyan !important; } /* Literal.String.Double */
|
||||
.se { color: $solar-red !important; } /* Literal.String.Escape */
|
||||
//.sh { color: #d14 } /* Literal.String.Heredoc */
|
||||
.si { color: $solar-blue !important; } /* Literal.String.Interpol */
|
||||
//.sx { color: #d14 } /* Literal.String.Other */
|
||||
.sr { color: $solar-cyan !important; } /* Literal.String.Regex */
|
||||
.s1 { color: $solar-cyan !important; } /* Literal.String.Single */
|
||||
//.ss { color: #990073 } /* Literal.String.Symbol */
|
||||
//.il { color: #009999 } /* Literal.Number.Integer.Long */
|
||||
div { .gd, .gd .x, .gi, .gi .x { display: inline-block; width: 100%; }}
|
||||
}
|
||||
|
||||
.highlight, .gist-highlight {
|
||||
pre { background: none; @include border-radius(0px); border: none; padding: 0; margin-bottom: 0; }
|
||||
margin-bottom: 1.8em;
|
||||
background: $base03;
|
||||
overflow-y: hidden;
|
||||
overflow-x: auto;
|
||||
}
|
||||
|
||||
$solar-scroll-bg: rgba(#fff, .15);
|
||||
$solar-scroll-thumb: rgba(#fff, .2);
|
||||
@if $solarized == light {
|
||||
$solar-scroll-bg: rgba(#000, .15);
|
||||
$solar-scroll-thumb: rgba(#000, .15);
|
||||
}
|
||||
|
||||
pre, .highlight, .gist-highlight {
|
||||
&::-webkit-scrollbar { height: .5em; background: $solar-scroll-bg; }
|
||||
&::-webkit-scrollbar-thumb:horizontal { background: $solar-scroll-thumb; -webkit-border-radius: 4px; border-radius: 4px }
|
||||
}
|
||||
|
||||
.highlight code {
|
||||
@extend .pre-code; background: #000;
|
||||
}
|
||||
figure.code {
|
||||
background: none;
|
||||
padding: 0;
|
||||
border: 0;
|
||||
margin-bottom: 1.5em;
|
||||
pre { margin-bottom: 0; }
|
||||
figcaption {
|
||||
position: relative;
|
||||
@extend .code-title;
|
||||
a { @extend .download-source; }
|
||||
}
|
||||
.highlight {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.code-title {
|
||||
text-align: center;
|
||||
font-size: 13px;
|
||||
line-height: 2em;
|
||||
text-shadow: #cbcccc 0 1px 0;
|
||||
color: #474747;
|
||||
font-weight: normal;
|
||||
margin-bottom: 0;
|
||||
@include border-top-radius(5px);
|
||||
font-family: "Helvetica Neue", Arial, "Lucida Grande", "Lucida Sans Unicode", Lucida, sans-serif;
|
||||
background: #aaaaaa image-url("code_bg.png") top repeat-x;
|
||||
border: 1px solid #565656;
|
||||
border-top-color: #cbcbcb;
|
||||
border-left-color: #a5a5a5;
|
||||
border-right-color: #a5a5a5;
|
||||
border-bottom: 0;
|
||||
}
|
||||
|
||||
.download-source {
|
||||
position: absolute; right: .8em;
|
||||
@include hover-link;
|
||||
color: #666 !important;
|
||||
z-index: 1;
|
||||
font-size: 13px;
|
||||
text-shadow: #cbcccc 0 1px 0;
|
||||
padding-left: 3em;
|
||||
}
|
|
@ -1,106 +0,0 @@
|
|||
.side-shadow-border {
|
||||
@include box-shadow(lighten($sidebar-bg, 5) 0 1px);
|
||||
}
|
||||
aside.sidebar {
|
||||
overflow: hidden;
|
||||
color: $sidebar-color;
|
||||
text-shadow: lighten($sidebar-bg, 8) 0 1px;
|
||||
a { @extend .force-wrap; }
|
||||
section {
|
||||
@extend .sans;
|
||||
font-size: .8em;
|
||||
line-height: 1.4em;
|
||||
margin-bottom: 1.5em;
|
||||
h1 {
|
||||
margin: 1.5em 0 0;
|
||||
padding-bottom: .2em;
|
||||
border-bottom: 1px solid $sidebar-border;
|
||||
@extend .side-shadow-border;
|
||||
+ p {
|
||||
padding-top: .4em;
|
||||
}
|
||||
}
|
||||
}
|
||||
img {
|
||||
@extend .flex-content;
|
||||
@extend .basic-alignment;
|
||||
@include shadow-box($border: #fff .3em solid);
|
||||
}
|
||||
ul {
|
||||
margin-bottom: 0.5em;
|
||||
margin-left: 0;
|
||||
}
|
||||
li {
|
||||
list-style: none;
|
||||
padding: .5em 0;
|
||||
margin: 0;
|
||||
border-bottom: 1px solid $sidebar-border;
|
||||
@extend .side-shadow-border;
|
||||
p:last-child {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
}
|
||||
a {
|
||||
color: inherit;
|
||||
@include transition(color .5s);
|
||||
}
|
||||
&:hover a {
|
||||
color: $sidebar-link-color;
|
||||
&:hover { color: $sidebar-link-color-hover; }
|
||||
}
|
||||
}
|
||||
.aside-alt-link {
|
||||
color: $sidebar-link-color-subdued;
|
||||
&:hover {
|
||||
color: $sidebar-link-color-subdued-hover;
|
||||
}
|
||||
}
|
||||
|
||||
@media only screen and (min-width: 768px) {
|
||||
.toggle-sidebar {
|
||||
outline: none;
|
||||
position: absolute; right: -10px; top: 0; bottom: 0;
|
||||
display: inline-block;
|
||||
text-decoration: none;
|
||||
color: mix($text-color-light, $sidebar-bg);
|
||||
width: 9px;
|
||||
cursor: pointer;
|
||||
&:hover {
|
||||
background: mix($sidebar-border, $sidebar-bg);
|
||||
@include background(linear-gradient(left, rgba($sidebar-border, .5), rgba($sidebar-border, 0)));
|
||||
}
|
||||
&:after {
|
||||
position: absolute; right: -11px; top: 0;
|
||||
width: 20px;
|
||||
font-size: 1.2em;
|
||||
line-height: 1.1em;
|
||||
padding-bottom: .15em;
|
||||
@include border-bottom-right-radius(.3em);
|
||||
text-align: center;
|
||||
background: $main-bg $noise-bg;
|
||||
border-bottom: 1px solid $sidebar-border;
|
||||
border-right: 1px solid $sidebar-border;
|
||||
content: "\00BB";
|
||||
text-indent: -1px;
|
||||
}
|
||||
.collapse-sidebar & {
|
||||
text-indent: 0px;
|
||||
right: -20px;
|
||||
width: 19px;
|
||||
&:hover {
|
||||
background: mix($sidebar-border, $sidebar-bg);
|
||||
}
|
||||
&:after {
|
||||
border-left: 1px solid $sidebar-border;
|
||||
text-shadow: #fff 0 1px;
|
||||
content: "\00AB";
|
||||
left: 0px; right: 0;
|
||||
text-align: center;
|
||||
text-indent: 0;
|
||||
border: 0;
|
||||
border-right-width: 0;
|
||||
background: none;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -1,4 +0,0 @@
|
|||
.delicious-posts {
|
||||
a.delicious-link { margin-bottom: .5em; display: block; }
|
||||
p { font-size: 1em; }
|
||||
}
|
|
@ -1,26 +0,0 @@
|
|||
.googleplus {
|
||||
h1 {
|
||||
-moz-box-shadow: none !important;
|
||||
-webkit-box-shadow: none !important;
|
||||
-o-box-shadow: none !important;
|
||||
box-shadow: none !important;
|
||||
border-bottom: 0px none !important;
|
||||
}
|
||||
a {
|
||||
text-decoration: none;
|
||||
white-space: normal !important;
|
||||
line-height: 32px;
|
||||
|
||||
img {
|
||||
float: left;
|
||||
margin-right: 0.5em;
|
||||
border: 0 none;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.googleplus-hidden {
|
||||
position: absolute;
|
||||
top: -1000em;
|
||||
left: -1000em;
|
||||
}
|
|
@ -1,12 +0,0 @@
|
|||
#pinboard_linkroll {
|
||||
.pin-title, .pin-description {
|
||||
display: block;
|
||||
margin-bottom: .5em;
|
||||
}
|
||||
.pin-tag {
|
||||
@include hover-link;
|
||||
@extend .aside-alt-link;
|
||||
&:after { content: ','; }
|
||||
&:last-child:after { content: ''; }
|
||||
}
|
||||
}
|
|
@ -1,34 +0,0 @@
|
|||
#tweets {
|
||||
.loading {
|
||||
background: inline-image('bird_32_gray.png') no-repeat center .5em;
|
||||
color: darken($sidebar-bg, 18);
|
||||
text-shadow: $main-bg 0 1px;
|
||||
text-align: center;
|
||||
padding: 2.5em 0 .5em;
|
||||
&.error {
|
||||
background: inline-image('bird_32_gray_fail.png') no-repeat center .5em;
|
||||
}
|
||||
}
|
||||
p {
|
||||
position: relative;
|
||||
padding-right: 1em;
|
||||
}
|
||||
a[href*=status]:first-child {
|
||||
color: $twitter-status-link;
|
||||
float: right;
|
||||
padding: 0 0 .1em 1em;
|
||||
position: relative; right: -1.3em;
|
||||
text-shadow: #fff 0 1px;
|
||||
font-size: .7em;
|
||||
span { font-size: 1.5em; }
|
||||
text-decoration: none;
|
||||
&:hover {
|
||||
color: $sidebar-link-color-subdued-hover;
|
||||
text-decoration: none;
|
||||
}
|
||||
}
|
||||
a[href*='twitter.com/search']{
|
||||
@extend .aside-alt-link;
|
||||
@include hover-link;
|
||||
}
|
||||
}
|
|
@ -1,10 +0,0 @@
|
|||
@import "compass";
|
||||
@include global-reset;
|
||||
@include reset-html5;
|
||||
|
||||
@import "custom/colors";
|
||||
@import "custom/fonts";
|
||||
@import "custom/layout";
|
||||
@import "base";
|
||||
@import "partials";
|
||||
@import "custom/styles";
|
|
@ -1,5 +0,0 @@
|
|||
{% include disqus.html %}
|
||||
{% include facebook_like.html %}
|
||||
{% include google_plus_one.html %}
|
||||
{% include twitter_sharing.html %}
|
||||
{% include custom/after_footer.html %}
|
|
@ -1,8 +0,0 @@
|
|||
{% capture category %}{{ post.categories | size }}{% endcapture %}
|
||||
<h1><a href="{{ root_url }}{{ post.url }}">{{post.title}}</a></h1>
|
||||
<time datetime="{{ post.date | datetime | date_to_xmlschema }}" pubdate>{{ post.date | date: "<span class='month'>%b</span> <span class='day'>%d</span> <span class='year'>%Y</span>"}}</time>
|
||||
{% if category != '0' %}
|
||||
<footer>
|
||||
<span class="categories">posted in {{ post.categories | category_links }}</span>
|
||||
</footer>
|
||||
{% endif %}
|
|
@ -1,28 +0,0 @@
|
|||
{% unless page.no_header %}
|
||||
<header>
|
||||
{% if index %}
|
||||
<h1 class="entry-title"><a href="{{ root_url }}{{ post.url }}">{% if site.titlecase %}{{ post.title | titlecase }}{% else %}{{ post.title }}{% endif %}</a></h1>
|
||||
{% else %}
|
||||
<h1 class="entry-title">{% if site.titlecase %}{{ page.title | titlecase }}{% else %}{{ page.title }}{% endif %}</h1>
|
||||
{% endif %}
|
||||
{% unless page.meta == false %}
|
||||
<p class="meta">
|
||||
{% include post/date.html %}{{ time }}
|
||||
{% if site.disqus_short_name and page.comments != false and post.comments != false and site.disqus_show_comment_count == true %}
|
||||
| <a href="{% if index %}{{ root_url }}{{ post.url }}{% endif %}#disqus_thread">Comments</a>
|
||||
{% endif %}
|
||||
</p>
|
||||
{% endunless %}
|
||||
</header>
|
||||
{% endunless %}
|
||||
{% if index %}
|
||||
<div class="entry-content">{{ content | excerpt }}</div>
|
||||
{% capture excerpted %}{{ content | has_excerpt }}{% endcapture %}
|
||||
{% if excerpted == 'true' %}
|
||||
<footer>
|
||||
<a rel="full-article" href="{{ root_url }}{{ post.url }}">{{ site.excerpt_link }}</a>
|
||||
</footer>
|
||||
{% endif %}
|
||||
{% else %}
|
||||
<div class="entry-content">{{ content }}</div>
|
||||
{% endif %}
|
|
@ -1,8 +0,0 @@
|
|||
{% if site.delicious_user %}
|
||||
<section>
|
||||
<h1>On Delicious</h1>
|
||||
<div id="delicious"></div>
|
||||
<script type="text/javascript" src="http://feeds.delicious.com/v2/json/{{ site.delicious_user }}?count={{ site.delicious_count }}&sort=date&callback=renderDeliciousLinks"></script>
|
||||
<p><a href="http://delicious.com/{{ site.delicious_user }}">My Delicious Bookmarks »</a></p>
|
||||
</section>
|
||||
{% endif %}
|
|
@ -1,30 +0,0 @@
|
|||
{% if site.github_user %}
|
||||
<section>
|
||||
<h1>GitHub Repos</h1>
|
||||
<ul id="gh_repos">
|
||||
<li class="loading">Status updating...</li>
|
||||
</ul>
|
||||
{% if site.github_show_profile_link %}
|
||||
<a href="https://github.com/{{site.github_user}}">@{{site.github_user}}</a> on GitHub
|
||||
{% endif %}
|
||||
<script type="text/javascript">
|
||||
$.domReady(function(){
|
||||
if (!window.jXHR){
|
||||
var jxhr = document.createElement('script');
|
||||
jxhr.type = 'text/javascript';
|
||||
jxhr.src = '{{ root_url}}/javascripts/libs/jXHR.js';
|
||||
var s = document.getElementsByTagName('script')[0];
|
||||
s.parentNode.insertBefore(jxhr, s);
|
||||
}
|
||||
|
||||
github.showRepos({
|
||||
user: '{{site.github_user}}',
|
||||
count: {{site.github_repo_count}},
|
||||
skip_forks: {{site.github_skip_forks}},
|
||||
target: '#gh_repos'
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<script src="{{ root_url }}/javascripts/github.js" type="text/javascript"> </script>
|
||||
</section>
|
||||
{% endif %}
|
|
@ -1,11 +0,0 @@
|
|||
{% if site.googleplus_user %}
|
||||
<section class="googleplus{% if site.googleplus_hidden %} googleplus-hidden{% endif %}">
|
||||
<h1>
|
||||
<a href="https://plus.google.com/{{ site.googleplus_user }}?rel=author">
|
||||
<img src="http://www.google.com/images/icons/ui/gprofile_button-32.png" width="32" height="32">
|
||||
Google+
|
||||
</a>
|
||||
</h1>
|
||||
</section>
|
||||
{% endif %}
|
||||
|
|
@ -1,19 +0,0 @@
|
|||
{% if site.pinboard_user %}
|
||||
<section>
|
||||
<h1>My Pinboard</h1>
|
||||
<ul id="pinboard_linkroll">Fetching linkroll...</ul>
|
||||
<p><a href="http://pinboard.in/u:{{ site.pinboard_user }}">My Pinboard Bookmarks »</a></p>
|
||||
</section>
|
||||
<script type="text/javascript">
|
||||
var linkroll = 'pinboard_linkroll'; //id target for pinboard list
|
||||
var pinboard_user = "{{ site.pinboard_user }}"; //id target for pinboard list
|
||||
var pinboard_count = {{ site.pinboard_count }}; //id target for pinboard list
|
||||
(function(){
|
||||
var pinboardInit = document.createElement('script');
|
||||
pinboardInit.type = 'text/javascript';
|
||||
pinboardInit.async = true;
|
||||
pinboardInit.src = '{{ root_url }}/javascripts/pinboard.js';
|
||||
document.getElementsByTagName('head')[0].appendChild(pinboardInit);
|
||||
})();
|
||||
</script>
|
||||
{% endif %}
|
|
@ -1,10 +0,0 @@
|
|||
<section>
|
||||
<h1>Recent Posts</h1>
|
||||
<ul id="recent_posts">
|
||||
{% for post in site.posts limit: site.recent_posts %}
|
||||
<li class="post">
|
||||
<a href="{{ root_url }}{{ post.url }}">{{ post.title }}</a>
|
||||
</li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
</section>
|
|
@ -1,19 +0,0 @@
|
|||
{% if site.twitter_user %}
|
||||
<section>
|
||||
<h1>Latest Tweets</h1>
|
||||
<ul id="tweets">
|
||||
<li class="loading">Status updating...</li>
|
||||
</ul>
|
||||
<script type="text/javascript">
|
||||
$.domReady(function(){
|
||||
getTwitterFeed("{{site.twitter_user}}", {{site.twitter_tweet_count}}, {{site.twitter_show_replies}});
|
||||
});
|
||||
</script>
|
||||
<script src="{{ root_url }}/javascripts/twitter.js" type="text/javascript"> </script>
|
||||
{% if site.twitter_follow_button %}
|
||||
<a href="http://twitter.com/{{ site.twitter_user }}" class="twitter-follow-button" data-show-count="{{ site.twitter_show_follower_count }}">Follow @{{ site.twitter_user }}</a>
|
||||
{% else %}
|
||||
<p>Follow <a href="http://twitter.com/{{site.twitter_user}}">@{{ site.twitter_user }}</a></p>
|
||||
{% endif %}
|
||||
</section>
|
||||
{% endif %}
|
|
@ -1,3 +0,0 @@
|
|||
{% comment %}
|
||||
Add content to be output at the bottom of each page. (You might use this for analytics scripts, for example)
|
||||
{% endcomment %}
|
|
@ -1,4 +0,0 @@
|
|||
<section>
|
||||
<h1>About Me</h1>
|
||||
<p>A little something about me.</p>
|
||||
</section>
|
|
@ -1,27 +0,0 @@
|
|||
---
|
||||
layout: nil
|
||||
---
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<feed xmlns="http://www.w3.org/2005/Atom">
|
||||
|
||||
<title><![CDATA[{{ page.title }} | {{ site.title }}]]></title>
|
||||
<link href="{{ site.url }}/{{ page.feed_url }}" rel="self"/>
|
||||
<link href="{{ site.url }}/"/>
|
||||
<updated>{{ site.time | date_to_xmlschema }}</updated>
|
||||
<id>{{ site.url }}/</id>
|
||||
<author>
|
||||
<name><![CDATA[{{ site.author | strip_html }}]]></name>
|
||||
{% if site.email %}<email><![CDATA[{{ site.email }}]]></email>{% endif %}
|
||||
</author>
|
||||
<generator uri="http://octopress.org/">Octopress</generator>
|
||||
|
||||
{% for post in site.categories[page.category] limit: 5 %}
|
||||
<entry>
|
||||
<title type="html"><![CDATA[{{ post.title | cdata_escape }}]]></title>
|
||||
<link href="{{ site.url }}{{ post.url }}"/>
|
||||
<updated>{{ post.date | date_to_xmlschema }}</updated>
|
||||
<id>{{ site.url }}{{ post.id }}</id>
|
||||
<content type="html"><![CDATA[{{ post.content | expand_urls: site.url | markdownify | cdata_escape }}]]></content>
|
||||
</entry>
|
||||
{% endfor %}
|
||||
</feed>
|
|
@ -1,4 +0,0 @@
|
|||
<p>
|
||||
Copyright © {{ site.time | date: "%Y" }} - {{ site.author }} -
|
||||
<span class="credit">Powered by <a href="http://octopress.org">Octopress</a></span>
|
||||
</p>
|
|
@ -1,3 +0,0 @@
|
|||
<!--Fonts from Google"s Web font directory at http://google.com/webfonts -->
|
||||
<link href="http://fonts.googleapis.com/css?family=PT+Serif:regular,italic,bold,bolditalic" rel="stylesheet" type="text/css">
|
||||
<link href="http://fonts.googleapis.com/css?family=PT+Sans:regular,italic,bold,bolditalic" rel="stylesheet" type="text/css">
|
|
@ -1,6 +0,0 @@
|
|||
<hgroup>
|
||||
<h1><a href="{{ root_url }}/">{{ site.title }}</a></h1>
|
||||
{% if site.subtitle %}
|
||||
<h2>{{ site.subtitle }}</h2>
|
||||
{% endif %}
|
||||
</hgroup>
|
|
@ -1,4 +0,0 @@
|
|||
<ul class="main-navigation">
|
||||
<li><a href="{{ root_url }}/">Blog</a></li>
|
||||
<li><a href="{{ root_url }}/blog/archives">Archives</a></li>
|
||||
</ul>
|
|
@ -1,21 +0,0 @@
|
|||
{% comment %} Load script if disquss comments are enabled and `page.comments` is either empty (index) or set to true {% endcomment %}
|
||||
{% if site.disqus_short_name and page.comments != false %}
|
||||
<script type="text/javascript">
|
||||
var disqus_shortname = '{{ site.disqus_short_name }}';
|
||||
{% if page.comments == true %}
|
||||
{% comment %} `page.comments` can be only be set to true on pages/posts, so we embed the comments here. {% endcomment %}
|
||||
// var disqus_developer = 1;
|
||||
var disqus_identifier = '{{ site.url }}{{ page.url }}';
|
||||
var disqus_url = '{{ site.url }}{{ page.url }}';
|
||||
var disqus_script = 'embed.js';
|
||||
{% else %}
|
||||
{% comment %} As `page.comments` is empty, we must be on the index page. {% endcomment %}
|
||||
var disqus_script = 'count.js';
|
||||
{% endif %}
|
||||
(function () {
|
||||
var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
|
||||
dsq.src = 'http://' + disqus_shortname + '.disqus.com/' + disqus_script;
|
||||
(document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
|
||||
}());
|
||||
</script>
|
||||
{% endif %}
|
|
@ -1,10 +0,0 @@
|
|||
{% if site.facebook_like %}
|
||||
<div id="fb-root"></div>
|
||||
<script>(function(d, s, id) {
|
||||
var js, fjs = d.getElementsByTagName(s)[0];
|
||||
if (d.getElementById(id)) {return;}
|
||||
js = d.createElement(s); js.id = id; js.async = true;
|
||||
js.src = "//connect.facebook.net/en_US/all.js#appId=212934732101925&xfbml=1";
|
||||
fjs.parentNode.insertBefore(js, fjs);
|
||||
}(document, 'script', 'facebook-jssdk'));</script>
|
||||
{% endif %}
|
|
@ -1 +0,0 @@
|
|||
{% include custom/footer.html %}
|
|
@ -1,13 +0,0 @@
|
|||
{% if site.google_analytics_tracking_id %}
|
||||
<script type="text/javascript">
|
||||
var _gaq = _gaq || [];
|
||||
_gaq.push(['_setAccount', '{{ site.google_analytics_tracking_id }}']);
|
||||
_gaq.push(['_trackPageview']);
|
||||
|
||||
(function() {
|
||||
var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
|
||||
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
|
||||
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
|
||||
})();
|
||||
</script>
|
||||
{% endif %}
|
|
@ -1,9 +0,0 @@
|
|||
{% if site.google_plus_one %}
|
||||
<script type="text/javascript">
|
||||
(function() {
|
||||
var script = document.createElement('script'); script.type = 'text/javascript'; script.async = true;
|
||||
script.src = 'https://apis.google.com/js/plusone.js';
|
||||
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(script, s);
|
||||
})();
|
||||
</script>
|
||||
{% endif %}
|
|
@ -1,29 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<!--[if IEMobile 7 ]><html class="no-js iem7"><![endif]-->
|
||||
<!--[if lt IE 9]><html class="no-js lte-ie8"><![endif]-->
|
||||
<!--[if (gt IE 8)|(gt IEMobile 7)|!(IEMobile)|!(IE)]><!--><html class="no-js" lang="en"><!--<![endif]-->
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>{% if page.title %}{{ page.title }} - {% endif %}{{ site.title }}</title>
|
||||
<meta name="author" content="{{ site.author }}">
|
||||
|
||||
{% capture description %}{% if page.description %}{{ page.description }}{% else %}{{ content | raw_content }}{% endif %}{% endcapture %}
|
||||
<meta name="description" content="{{ description | strip_html | condense_spaces | truncate:150 }}">
|
||||
{% if page.keywords %}<meta name="keywords" content="{{ page.keywords }}">{% endif %}
|
||||
|
||||
<!-- http://t.co/dKP3o1e -->
|
||||
<meta name="HandheldFriendly" content="True">
|
||||
<meta name="MobileOptimized" content="320">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
|
||||
{% capture canonical %}{{ site.url }}{% if site.permalink contains '.html' %}{{ page.url }}{% else %}{% if page.url contains site.category_dir %}/{% endif %}{{ page.url | remove:'index.html' }}{% endif %}{% endcapture %}
|
||||
<link rel="canonical" href="{{ canonical }}">
|
||||
<link href="{{ root_url }}/favicon.png" rel="icon">
|
||||
<link href="{{ root_url }}/stylesheets/screen.css" media="screen, projection" rel="stylesheet" type="text/css">
|
||||
<link href="{{ site.subscribe_rss }}" rel="alternate" title="{{site.title}}" type="application/atom+xml">
|
||||
{% include custom/head.html %}
|
||||
<script src="{{ root_url }}/javascripts/modernizr-2.0.js"></script>
|
||||
<script src="{{ root_url }}/javascripts/ender.js"></script>
|
||||
<script src="{{ root_url }}/javascripts/octopress.js" type="text/javascript"></script>
|
||||
{% include google_analytics.html %}
|
||||
</head>
|
|
@ -1 +0,0 @@
|
|||
{% include custom/header.html %}
|
|
@ -1,15 +0,0 @@
|
|||
<ul class="subscription" data-subscription="rss{% if site.subscribe_email %} email{% endif %}">
|
||||
<li><a href="{{ site.subscribe_rss }}" rel="subscribe-rss" title="subscribe via RSS">RSS</a></li>
|
||||
{% if site.subscribe_email %}
|
||||
<li><a href="{{ site.subscribe_email }}" rel="subscribe-email" title="subscribe via email">Email</a></li>
|
||||
{% endif %}
|
||||
</ul>
|
||||
{% if site.simple_search %}
|
||||
<form action="{{ site.simple_search }}" method="get">
|
||||
<fieldset role="search">
|
||||
<input type="hidden" name="q" value="site:{{ site.url | shorthand_url }}" />
|
||||
<input class="search" type="text" name="q" results="0" placeholder="Search"/>
|
||||
</fieldset>
|
||||
</form>
|
||||
{% endif %}
|
||||
{% include custom/navigation.html %}
|
|
@ -1,8 +0,0 @@
|
|||
{% if post.author %}
|
||||
{% assign author = post.author %}
|
||||
{% elsif page.author %}
|
||||
{% assign author = page.author %}
|
||||
{% else %}
|
||||
{% assign author = site.author %}
|
||||
{% endif %}
|
||||
{% if author %}<span class="byline author vcard">Posted by <span class="fn">{{ author }}</span></span>{% endif %}
|
|
@ -1,10 +0,0 @@
|
|||
{% capture category %}{% if post %}{{ post.categories | category_links | size }}{% else %}{{ page.categories | category_links | size }}{% endif %}{% endcapture %}
|
||||
{% unless category == '0' %}
|
||||
<span class="categories">
|
||||
{% if post %}
|
||||
{{ post.categories | category_links }}
|
||||
{% else %}
|
||||
{{ page.categories | category_links }}
|
||||
{% endif %}
|
||||
</span>
|
||||
{% endunless %}
|
|
@ -1,15 +0,0 @@
|
|||
{% capture date %}{{ page.date }}{{ post.date }}{% endcapture %}
|
||||
{% capture date_formatted %}{{ page.date_formatted }}{{ post.date_formatted }}{% endcapture %}
|
||||
{% capture has_date %}{{ date | size }}{% endcapture %}
|
||||
|
||||
{% capture updated %}{{ page.updated }}{{ post.updated }}{% endcapture %}
|
||||
{% capture updated_formatted %}{{ page.updated_formatted }}{{ post.updated_formatted }}{% endcapture %}
|
||||
{% capture was_updated %}{{ updated | size }}{% endcapture %}
|
||||
|
||||
{% if has_date != '0' %}
|
||||
{% capture time %}<time datetime="{{ date | datetime | date_to_xmlschema }}" pubdate{% if updated %} data-updated="true"{% endif %}>{{ date_formatted }}</time>{% endcapture %}
|
||||
{% endif %}
|
||||
|
||||
{% if was_updated != '0' %}
|
||||
{% capture updated %}<time datetime="{{ updated | datetime | date_to_xmlschema }}" class="updated">Updated {{ updated_formatted }}</time>{% endcapture %}
|
||||
{% else %}{% assign updated = false %}{% endif %}
|
|
@ -1 +0,0 @@
|
|||
<noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
|
|
@ -1,11 +0,0 @@
|
|||
<div class="sharing">
|
||||
{% if site.twitter_tweet_button %}
|
||||
<a href="http://twitter.com/share" class="twitter-share-button" data-url="{{ site.url }}{{ page.url }}" data-via="{{ site.twitter_user }}" data-counturl="{{ site.url }}{{ page.url }}" >Tweet</a>
|
||||
{% endif %}
|
||||
{% if site.google_plus_one %}
|
||||
<div class="g-plusone" data-size="{{ site.google_plus_one_size }}"></div>
|
||||
{% endif %}
|
||||
{% if site.facebook_like %}
|
||||
<div class="fb-like" data-send="true" data-width="450" data-show-faces="false"></div>
|
||||
{% endif %}
|
||||
</div>
|
|
@ -1,11 +0,0 @@
|
|||
{% if site.twitter_follow_button or site.twitter_tweet_button %}
|
||||
<script type="text/javascript">
|
||||
(function(){
|
||||
var twitterWidgets = document.createElement('script');
|
||||
twitterWidgets.type = 'text/javascript';
|
||||
twitterWidgets.async = true;
|
||||
twitterWidgets.src = 'http://platform.twitter.com/widgets.js';
|
||||
document.getElementsByTagName('head')[0].appendChild(twitterWidgets);
|
||||
})();
|
||||
</script>
|
||||
{% endif %}
|
|
@ -1,17 +0,0 @@
|
|||
---
|
||||
layout: page
|
||||
footer: false
|
||||
---
|
||||
|
||||
<div id="blog-archives" class="category">
|
||||
{% for post in site.categories[page.category] %}
|
||||
{% capture this_year %}{{ post.date | date: "%Y" }}{% endcapture %}
|
||||
{% unless year == this_year %}
|
||||
{% assign year = this_year %}
|
||||
<h2>{{ year }}</h2>
|
||||
{% endunless %}
|
||||
<article>
|
||||
{% include archive_post.html %}
|
||||
</article>
|
||||
{% endfor %}
|
||||
</div>
|
|
@ -1,14 +0,0 @@
|
|||
{% capture root_url %}{{ site.root | strip_slash }}{% endcapture %}
|
||||
{% include head.html %}
|
||||
<body {% if page.body_id %} id="{{ page.body_id }}" {% endif %} {% if page.sidebar == false %} class="no-sidebar" {% endif %} {% if page.sidebar == 'collapse' or site.sidebar == 'collapse' %} class="collapse-sidebar sidebar-footer" {% endif %}>
|
||||
<header role="banner">{% include header.html %}</header>
|
||||
<nav role="navigation">{% include navigation.html %}</nav>
|
||||
<div id="main">
|
||||
<div id="content">
|
||||
{{ content | expand_urls: root_url }}
|
||||
</div>
|
||||
</div>
|
||||
<footer role="contentinfo">{% include footer.html %}</footer>
|
||||
{% include after_footer.html %}
|
||||
</body>
|
||||
</html>
|
|
@ -1,42 +0,0 @@
|
|||
---
|
||||
layout: default
|
||||
---
|
||||
|
||||
<div>
|
||||
<article role="article">
|
||||
{% if page.title %}
|
||||
<header>
|
||||
<h1 class="entry-title">{% if site.titlecase %}{{ page.title | titlecase }}{% else %}{{ page.title }}{% endif %}</h1>
|
||||
{% if page.date %}<p class="meta">{% include post/date.html %}{{ time }}</p>{% endif %}
|
||||
</header>
|
||||
{% endif %}
|
||||
{{ content }}
|
||||
{% unless page.footer == false %}
|
||||
<footer>
|
||||
{% if page.date or page.author %}<p class="meta">
|
||||
{% if page.author %}{% include post/author.html %}{% endif %}
|
||||
{% include post/date.html %}{% if updated %}{{ updated }}{% else %}{{ time }}{% endif %}
|
||||
{% if page.categories %}{% include post/categories.html %}{% endif %}
|
||||
</p>{% endif %}
|
||||
{% unless page.sharing == false %}
|
||||
{% include post/sharing.html %}
|
||||
{% endunless %}
|
||||
</footer>
|
||||
{% endunless %}
|
||||
</article>
|
||||
{% if site.disqus_short_name and page.comments == true %}
|
||||
<section>
|
||||
<h1>Comments</h1>
|
||||
<div id="disqus_thread" aria-live="polite">{% include post/disqus_thread.html %}</div>
|
||||
</section>
|
||||
{% endif %}
|
||||
</div>
|
||||
{% unless page.sidebar == false %}
|
||||
<aside class="sidebar">
|
||||
{% if site.page_asides.size %}
|
||||
{% include_array page_asides %}
|
||||
{% else %}
|
||||
{% include_array default_asides %}
|
||||
{% endif %}
|
||||
</aside>
|
||||
{% endunless %}
|
|
@ -1,43 +0,0 @@
|
|||
---
|
||||
layout: default
|
||||
single: true
|
||||
---
|
||||
|
||||
<div>
|
||||
<article class="hentry" role="article">
|
||||
{% include article.html %}
|
||||
<footer>
|
||||
<p class="meta">
|
||||
{% include post/author.html %}
|
||||
{% include post/date.html %}{% if updated %}{{ updated }}{% else %}{{ time }}{% endif %}
|
||||
{% include post/categories.html %}
|
||||
</p>
|
||||
{% unless page.sharing == false %}
|
||||
{% include post/sharing.html %}
|
||||
{% endunless %}
|
||||
<p class="meta">
|
||||
{% if page.previous.url %}
|
||||
<a class="basic-alignment left" href="{{page.previous.url}}" title="Previous Post: {{page.previous.title}}">« {{page.previous.title}}</a>
|
||||
{% endif %}
|
||||
{% if page.next.url %}
|
||||
<a class="basic-alignment right" href="{{page.next.url}}" title="Next Post: {{page.next.title}}">{{page.next.title}} »</a>
|
||||
{% endif %}
|
||||
</p>
|
||||
</footer>
|
||||
</article>
|
||||
{% if site.disqus_short_name and page.comments == true %}
|
||||
<section>
|
||||
<h1>Comments</h1>
|
||||
<div id="disqus_thread" aria-live="polite">{% include post/disqus_thread.html %}</div>
|
||||
</section>
|
||||
{% endif %}
|
||||
</div>
|
||||
{% unless page.sidebar == false %}
|
||||
<aside class="sidebar">
|
||||
{% if site.post_asides.size %}
|
||||
{% include_array post_asides %}
|
||||
{% else %}
|
||||
{% include_array default_asides %}
|
||||
{% endif %}
|
||||
</aside>
|
||||
{% endunless %}
|
|
@ -1,27 +0,0 @@
|
|||
---
|
||||
layout: nil
|
||||
---
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<feed xmlns="http://www.w3.org/2005/Atom">
|
||||
|
||||
<title><![CDATA[{{ site.title }}]]></title>
|
||||
<link href="{{ site.url }}/atom.xml" rel="self"/>
|
||||
<link href="{{ site.url }}/"/>
|
||||
<updated>{{ site.time | date_to_xmlschema }}</updated>
|
||||
<id>{{ site.url }}/</id>
|
||||
<author>
|
||||
<name><![CDATA[{{ site.author | strip_html }}]]></name>
|
||||
{% if site.email %}<email><![CDATA[{{ site.email }}]]></email>{% endif %}
|
||||
</author>
|
||||
<generator uri="http://octopress.org/">Octopress</generator>
|
||||
|
||||
{% for post in site.posts limit: 20 %}
|
||||
<entry>
|
||||
<title type="html"><![CDATA[{{ post.title | cdata_escape }}]]></title>
|
||||
<link href="{{ site.url }}{{ post.url }}"/>
|
||||
<updated>{{ post.date | date_to_xmlschema }}</updated>
|
||||
<id>{{ site.url }}{{ post.id }}</id>
|
||||
<content type="html"><![CDATA[{{ post.content | expand_urls: site.url | cdata_escape }}]]></content>
|
||||
</entry>
|
||||
{% endfor %}
|
||||
</feed>
|
|
@ -1,18 +0,0 @@
|
|||
---
|
||||
layout: page
|
||||
title: Blog Archive
|
||||
footer: false
|
||||
---
|
||||
|
||||
<div id="blog-archives">
|
||||
{% for post in site.posts reverse %}
|
||||
{% capture this_year %}{{ post.date | date: "%Y" }}{% endcapture %}
|
||||
{% unless year == this_year %}
|
||||
{% assign year = this_year %}
|
||||
<h2>{{ year }}</h2>
|
||||
{% endunless %}
|
||||
<article>
|
||||
{% include archive_post.html %}
|
||||
</article>
|
||||
{% endfor %}
|
||||
</div>
|
|
@ -1,29 +0,0 @@
|
|||
---
|
||||
layout: default
|
||||
---
|
||||
|
||||
<div class="blog-index">
|
||||
{% assign index = true %}
|
||||
{% for post in paginator.posts %}
|
||||
{% assign content = post.content %}
|
||||
<article>
|
||||
{% include article.html %}
|
||||
</article>
|
||||
{% endfor %}
|
||||
<div class="pagination">
|
||||
{% if paginator.next_page %}
|
||||
<a class="prev" href="{{paginator.next_page}}">← Older</a>
|
||||
{% endif %}
|
||||
<a href="/blog/archives">Blog Archives</a>
|
||||
{% if paginator.previous_page %}
|
||||
<a class="next" href="{{paginator.previous_page}}">Newer →</a>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
<aside class="sidebar">
|
||||
{% if site.blog_index_asides.size %}
|
||||
{% include_array blog_index_asides %}
|
||||
{% else %}
|
||||
{% include_array default_asides %}
|
||||
{% endif %}
|
||||
</aside>
|
|
@ -1,32 +0,0 @@
|
|||
var github = (function(){
|
||||
function escapeHtml(str) {
|
||||
return $('<div/>').text(str).html();
|
||||
}
|
||||
function render(target, repos){
|
||||
var i = 0, fragment = '', t = $(target)[0];
|
||||
|
||||
for(i = 0; i < repos.length; i++) {
|
||||
fragment += '<li><a href="'+repos[i].html_url+'">'+repos[i].name+'</a><p>'+escapeHtml(repos[i].description||'')+'</p></li>';
|
||||
}
|
||||
t.innerHTML = fragment;
|
||||
}
|
||||
return {
|
||||
showRepos: function(options){
|
||||
$.ajax({
|
||||
url: "https://api.github.com/users/"+options.user+"/repos?sort=pushed&callback=?"
|
||||
, type: 'jsonp'
|
||||
, error: function (err) { $(options.target + ' li.loading').addClass('error').text("Error loading feed"); }
|
||||
, success: function(data) {
|
||||
var repos = [];
|
||||
if (!data || !data.data) { return; }
|
||||
for (var i = 0; i < data.data.length; i++) {
|
||||
if (options.skip_forks && data.data[i].fork) { continue; }
|
||||
repos.push(data.data[i]);
|
||||
}
|
||||
if (options.count) { repos.splice(options.count); }
|
||||
render(options.target, repos);
|
||||
}
|
||||
});
|
||||
}
|
||||
};
|
||||
})();
|
|
@ -1,162 +0,0 @@
|
|||
function getNav() {
|
||||
var mobileNav = $('nav[role=navigation] fieldset[role=search]').after('<fieldset class="mobile-nav"></fieldset>').next().append('<select></select>');
|
||||
mobileNav.children('select').append('<option value="">Navigate…</option>');
|
||||
$('ul[role=main-navigation]').addClass('main-navigation');
|
||||
$('ul.main-navigation a').each(function(link) {
|
||||
mobileNav.children('select').append('<option value="'+link.href+'">» '+link.text+'</option>');
|
||||
});
|
||||
$('ul.subscription a').each(function(link) {
|
||||
mobileNav.children('select').append('<option value="'+link.href+'">» '+link.text+'</option>');
|
||||
});
|
||||
mobileNav.children('select').bind('change', function(event) {
|
||||
if (event.target.value) { window.location.href = event.target.value; }
|
||||
});
|
||||
mobileNav.children('select').val('');
|
||||
}
|
||||
|
||||
function addSidebarToggler() {
|
||||
if(!$('body').hasClass('sidebar-footer')) {
|
||||
$('#content').append('<span class="toggle-sidebar"></span>');
|
||||
$('.toggle-sidebar').bind('click', function(e) {
|
||||
e.preventDefault();
|
||||
if ($('body').hasClass('collapse-sidebar')) {
|
||||
$('body').removeClass('collapse-sidebar');
|
||||
} else {
|
||||
$('body').addClass('collapse-sidebar');
|
||||
}
|
||||
});
|
||||
}
|
||||
var sections = $('aside.sidebar > section');
|
||||
if (sections.length > 1) {
|
||||
sections.each(function(section, index){
|
||||
if ((sections.length >= 3) && index % 3 === 0) {
|
||||
$(section).addClass("first");
|
||||
}
|
||||
var count = ((index +1) % 2) ? "odd" : "even";
|
||||
$(section).addClass(count);
|
||||
});
|
||||
}
|
||||
if (sections.length >= 3){ $('aside.sidebar').addClass('thirds'); }
|
||||
}
|
||||
|
||||
function testFeatures() {
|
||||
var features = ['maskImage'];
|
||||
$(features).map(function(feature) {
|
||||
if (Modernizr.testAllProps(feature)) {
|
||||
$('html').addClass(feature);
|
||||
} else {
|
||||
$('html').addClass('no-'+feature);
|
||||
}
|
||||
});
|
||||
if ("placeholder" in document.createElement("input")) {
|
||||
$('html').addClass('placeholder');
|
||||
} else {
|
||||
$('html').addClass('no-placeholder');
|
||||
}
|
||||
}
|
||||
|
||||
function addCodeLineNumbers() {
|
||||
if (navigator.appName === 'Microsoft Internet Explorer') { return; }
|
||||
$('div.gist-highlight').each(function(code) {
|
||||
var tableStart = '<table><tbody><tr><td class="gutter">',
|
||||
lineNumbers = '<pre class="line-numbers">',
|
||||
tableMiddle = '</pre></td><td class="code">',
|
||||
tableEnd = '</td></tr></tbody></table>',
|
||||
count = $('.line', code).length;
|
||||
for (var i=1;i<=count; i++) {
|
||||
lineNumbers += '<span class="line-number">'+i+'</span>\n';
|
||||
}
|
||||
var table = tableStart + lineNumbers + tableMiddle + '<pre>'+$('pre', code).html()+'</pre>' + tableEnd;
|
||||
$(code).html(table);
|
||||
});
|
||||
}
|
||||
|
||||
function flashVideoFallback(){
|
||||
var flashplayerlocation = "/assets/jwplayer/player.swf",
|
||||
flashplayerskin = "/assets/jwplayer/glow/glow.xml";
|
||||
$('video').each(function(video){
|
||||
video = $(video);
|
||||
if (!Modernizr.video.h264 && swfobject.getFlashPlayerVersion() || window.location.hash.indexOf("flash-test") !== -1){
|
||||
video.children('source[src$=mp4]').first().map(function(source){
|
||||
var src = $(source).attr('src'),
|
||||
id = 'video_'+Math.round(1 + Math.random()*(100000)),
|
||||
width = video.attr('width'),
|
||||
height = parseInt(video.attr('height'), 10) + 30;
|
||||
video.after('<div class="flash-video"><div><div id='+id+'>');
|
||||
swfobject.embedSWF(flashplayerlocation, id, width, height + 30, "9.0.0",
|
||||
{ file : src, image : video.attr('poster'), skin : flashplayerskin } ,
|
||||
{ movie : src, wmode : "opaque", allowfullscreen : "true" }
|
||||
);
|
||||
});
|
||||
video.remove();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function wrapFlashVideos() {
|
||||
$('object').each(function(object) {
|
||||
object = $(object);
|
||||
if ( $('param[name=movie]', object).length ) {
|
||||
var wrapper = object.before('<div class="flash-video"><div>').previous();
|
||||
$(wrapper).children().append(object);
|
||||
}
|
||||
});
|
||||
$('iframe[src*=vimeo],iframe[src*=youtube]').each(function(iframe) {
|
||||
iframe = $(iframe);
|
||||
var wrapper = iframe.before('<div class="flash-video"><div>').previous();
|
||||
$(wrapper).children().append(iframe);
|
||||
});
|
||||
}
|
||||
|
||||
function renderDeliciousLinks(items) {
|
||||
var output = "<ul>";
|
||||
for (var i=0,l=items.length; i<l; i++) {
|
||||
output += '<li><a href="' + items[i].u + '" title="Tags: ' + (items[i].t == "" ? "" : items[i].t.join(', ')) + '">' + items[i].d + '</a></li>';
|
||||
}
|
||||
output += "</ul>";
|
||||
$('#delicious').html(output);
|
||||
}
|
||||
|
||||
$.domReady(function() {
|
||||
testFeatures();
|
||||
wrapFlashVideos();
|
||||
flashVideoFallback();
|
||||
addCodeLineNumbers();
|
||||
getNav();
|
||||
addSidebarToggler();
|
||||
});
|
||||
|
||||
// iOS scaling bug fix
|
||||
// Rewritten version
|
||||
// By @mathias, @cheeaun and @jdalton
|
||||
// Source url: https://gist.github.com/901295
|
||||
(function(doc) {
|
||||
var addEvent = 'addEventListener',
|
||||
type = 'gesturestart',
|
||||
qsa = 'querySelectorAll',
|
||||
scales = [1, 1],
|
||||
meta = qsa in doc ? doc[qsa]('meta[name=viewport]') : [];
|
||||
function fix() {
|
||||
meta.content = 'width=device-width,minimum-scale=' + scales[0] + ',maximum-scale=' + scales[1];
|
||||
doc.removeEventListener(type, fix, true);
|
||||
}
|
||||
if ((meta = meta[meta.length - 1]) && addEvent in doc) {
|
||||
fix();
|
||||
scales = [0.25, 1.6];
|
||||
doc[addEvent](type, fix, true);
|
||||
}
|
||||
}(document));
|
||||
|
||||
/*! SWFObject v2.2 modified by Brandon Mathis to contain only what is necessary to dynamically embed flash objects
|
||||
* Uncompressed source in javascripts/libs/swfobject-dynamic.js
|
||||
* <http://code.google.com/p/swfobject/>
|
||||
released under the MIT License <http://www.opensource.org/licenses/mit-license.php>
|
||||
*/
|
||||
var swfobject=function(){function s(a,b,d){var q,k=n(d);if(g.wk&&g.wk<312)return q;if(k){if(typeof a.id==l)a.id=d;if(g.ie&&g.win){var e="",c;for(c in a)if(a[c]!=Object.prototype[c])c.toLowerCase()=="data"?b.movie=a[c]:c.toLowerCase()=="styleclass"?e+=' class="'+a[c]+'"':c.toLowerCase()!="classid"&&(e+=" "+c+'="'+a[c]+'"');c="";for(var f in b)b[f]!=Object.prototype[f]&&(c+='<param name="'+f+'" value="'+b[f]+'" />');k.outerHTML='<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"'+e+">"+c+
|
||||
"</object>";q=n(a.id)}else{f=i.createElement(o);f.setAttribute("type",m);for(var h in a)a[h]!=Object.prototype[h]&&(h.toLowerCase()=="styleclass"?f.setAttribute("class",a[h]):h.toLowerCase()!="classid"&&f.setAttribute(h,a[h]));for(e in b)b[e]!=Object.prototype[e]&&e.toLowerCase()!="movie"&&(a=f,c=e,h=b[e],d=i.createElement("param"),d.setAttribute("name",c),d.setAttribute("value",h),a.appendChild(d));k.parentNode.replaceChild(f,k);q=f}}return q}function n(a){var b=null;try{b=i.getElementById(a)}catch(d){}return b}
|
||||
function t(a){var b=g.pv,a=a.split(".");a[0]=parseInt(a[0],10);a[1]=parseInt(a[1],10)||0;a[2]=parseInt(a[2],10)||0;return b[0]>a[0]||b[0]==a[0]&&b[1]>a[1]||b[0]==a[0]&&b[1]==a[1]&&b[2]>=a[2]?!0:!1}function u(a){return/[\\\"<>\.;]/.exec(a)!=null&&typeof encodeURIComponent!=l?encodeURIComponent(a):a}var l="undefined",o="object",m="application/x-shockwave-flash",v=window,i=document,j=navigator,g=function(){var a=typeof i.getElementById!=l&&typeof i.getElementsByTagName!=l&&typeof i.createElement!=l,
|
||||
b=j.userAgent.toLowerCase(),d=j.platform.toLowerCase(),g=d?/win/.test(d):/win/.test(b),d=d?/mac/.test(d):/mac/.test(b),b=/webkit/.test(b)?parseFloat(b.replace(/^.*webkit\/(\d+(\.\d+)?).*$/,"$1")):!1,k=!+"\u000b1",e=[0,0,0],c=null;if(typeof j.plugins!=l&&typeof j.plugins["Shockwave Flash"]==o){if((c=j.plugins["Shockwave Flash"].description)&&!(typeof j.mimeTypes!=l&&j.mimeTypes[m]&&!j.mimeTypes[m].enabledPlugin))k=!1,c=c.replace(/^.*\s+(\S+\s+\S+$)/,"$1"),e[0]=parseInt(c.replace(/^(.*)\..*$/,"$1"),
|
||||
10),e[1]=parseInt(c.replace(/^.*\.(.*)\s.*$/,"$1"),10),e[2]=/[a-zA-Z]/.test(c)?parseInt(c.replace(/^.*[a-zA-Z]+(.*)$/,"$1"),10):0}else if(typeof v.ActiveXObject!=l)try{var f=new ActiveXObject("ShockwaveFlash.ShockwaveFlash");if(f&&(c=f.GetVariable("$version")))k=!0,c=c.split(" ")[1].split(","),e=[parseInt(c[0],10),parseInt(c[1],10),parseInt(c[2],10)]}catch(h){}return{w3:a,pv:e,wk:b,ie:k,win:g,mac:d}}();return{embedSWF:function(a,b,d,i,k,e,c,f,h){var j={success:!1,id:b};if(g.w3&&!(g.wk&&g.wk<312)&&
|
||||
a&&b&&d&&i&&k){d+="";i+="";var p={};if(f&&typeof f===o)for(var m in f)p[m]=f[m];p.data=a;p.width=d;p.height=i;a={};if(c&&typeof c===o)for(var n in c)a[n]=c[n];if(e&&typeof e===o)for(var r in e)typeof a.flashvars!=l?a.flashvars+="&"+r+"="+e[r]:a.flashvars=r+"="+e[r];if(t(k))b=s(p,a,b),j.success=!0,j.ref=b}h&&h(j)},ua:g,getFlashPlayerVersion:function(){return{major:g.pv[0],minor:g.pv[1],release:g.pv[2]}},hasFlashPlayerVersion:t,createSWF:function(a,b,d){if(g.w3)return s(a,b,d)},getQueryParamValue:function(a){var b=
|
||||
i.location.search||i.location.hash;if(b){/\?/.test(b)&&(b=b.split("?")[1]);if(a==null)return u(b);for(var b=b.split("&"),d=0;d<b.length;d++)if(b[d].substring(0,b[d].indexOf("="))==a)return u(b[d].substring(b[d].indexOf("=")+1))}return""}}}();
|
||||
|
|
@ -1,7 +0,0 @@
|
|||
---
|
||||
layout: nil
|
||||
---
|
||||
User-agent: *
|
||||
Disallow:
|
||||
|
||||
Sitemap: {{ site.url }}/sitemap.xml
|
|
@ -1,5 +0,0 @@
|
|||
language: ruby
|
||||
rvm:
|
||||
- 1.9.3
|
||||
- 1.9.2
|
||||
script: bundle exec rake install; bundle exec rake generate
|
|
@ -1,29 +0,0 @@
|
|||
# Octopress Changelog
|
||||
|
||||
## 2.0
|
||||
|
||||
- Now based on [mojombo/jekyll](http://github.com/mojombo/jekyll)
|
||||
- Sports a semantic HTML5 template
|
||||
- Easy theming with Compass and Sass
|
||||
- A Mobile friendly responsive (320 and up) layout
|
||||
- Built in 3rd party support for Twitter, Google Plus One, Disqus Comments, Pinboard, Delicious, and Google Analytics
|
||||
- Deploy to Github pages or use Rsync
|
||||
- Built in support for POW and Rack servers
|
||||
- Beautiful [Solarized](http://ethanschoonover.com/solarized) syntax highlighting
|
||||
- Super easy setup and configuration
|
||||
|
||||
**New Plugins, Filters, & Generators**
|
||||
|
||||
- **Gist Tag** for easily embedding gists in your posts
|
||||
- **Pygments Cache** makes subsequent compiling much faster
|
||||
- **Include Code Tag** lets you embed external code snippets from your file system and adds a download link
|
||||
- **Pullquote Tag** Generate beautiful semantic pullquotes (no double data) based on Maykel Loomans's [technique](http://miekd.com/articles/pull-quotes-with-html5-and-css/)
|
||||
- **Blockquote Tag** makes it easy to semantically format blockquotes
|
||||
- **Category Generator** gives you archive pages for each category
|
||||
- **Sitemap.xml Generator** for search engines
|
||||
|
||||
## 1.0
|
||||
|
||||
- **No longer supported.**
|
||||
- Jekyll Matured, but Henrik's Jekyll fork did not.
|
||||
- Thanks for all your pull requests, I learned a lot.
|
18
Gemfile
|
@ -1,18 +0,0 @@
|
|||
source "http://rubygems.org"
|
||||
|
||||
group :development do
|
||||
gem 'rake', '~> 0.9'
|
||||
gem 'rack', '~> 1.4.1'
|
||||
gem 'jekyll', '~> 0.12'
|
||||
gem 'rdiscount', '~> 1.6.8'
|
||||
gem 'pygments.rb', '~> 0.3.4'
|
||||
gem 'RedCloth', '~> 4.2.9'
|
||||
gem 'haml', '~> 3.1.7'
|
||||
gem 'compass', '~> 0.12.2'
|
||||
gem 'rubypants', '~> 0.2.0'
|
||||
gem 'rb-fsevent', '~> 0.9'
|
||||
gem 'stringex', '~> 1.4.0'
|
||||
gem 'liquid', '~> 2.3.0'
|
||||
end
|
||||
|
||||
gem 'sinatra', '~> 1.3.5'
|
64
Gemfile.lock
|
@ -1,64 +0,0 @@
|
|||
GEM
|
||||
remote: http://rubygems.org/
|
||||
specs:
|
||||
RedCloth (4.2.9)
|
||||
chunky_png (1.2.5)
|
||||
classifier (1.3.3)
|
||||
fast-stemmer (>= 1.0.0)
|
||||
compass (0.12.2)
|
||||
chunky_png (~> 1.2)
|
||||
fssm (>= 0.2.7)
|
||||
sass (~> 3.1)
|
||||
directory_watcher (1.4.1)
|
||||
fast-stemmer (1.0.1)
|
||||
fssm (0.2.9)
|
||||
haml (3.1.7)
|
||||
jekyll (0.12.0)
|
||||
classifier (~> 1.3)
|
||||
directory_watcher (~> 1.1)
|
||||
kramdown (~> 0.13.4)
|
||||
liquid (~> 2.3)
|
||||
maruku (~> 0.5)
|
||||
pygments.rb (~> 0.3.2)
|
||||
kramdown (0.13.8)
|
||||
liquid (2.3.0)
|
||||
maruku (0.6.1)
|
||||
syntax (>= 1.0.0)
|
||||
posix-spawn (0.3.6)
|
||||
pygments.rb (0.3.4)
|
||||
posix-spawn (~> 0.3.6)
|
||||
yajl-ruby (~> 1.1.0)
|
||||
rack (1.4.5)
|
||||
rack-protection (1.3.2)
|
||||
rack
|
||||
rake (0.9.2.2)
|
||||
rb-fsevent (0.9.1)
|
||||
rdiscount (1.6.8)
|
||||
rubypants (0.2.0)
|
||||
sass (3.1.20)
|
||||
sinatra (1.3.5)
|
||||
rack (~> 1.4)
|
||||
rack-protection (~> 1.3)
|
||||
tilt (~> 1.3, >= 1.3.3)
|
||||
stringex (1.4.0)
|
||||
syntax (1.0.0)
|
||||
tilt (1.3.3)
|
||||
yajl-ruby (1.1.0)
|
||||
|
||||
PLATFORMS
|
||||
ruby
|
||||
|
||||
DEPENDENCIES
|
||||
RedCloth (~> 4.2.9)
|
||||
compass (~> 0.12.2)
|
||||
haml (~> 3.1.7)
|
||||
jekyll (~> 0.12)
|
||||
liquid (~> 2.3.0)
|
||||
pygments.rb (~> 0.3.4)
|
||||
rack (~> 1.4.1)
|
||||
rake (~> 0.9)
|
||||
rb-fsevent (~> 0.9)
|
||||
rdiscount (~> 1.6.8)
|
||||
rubypants (~> 0.2.0)
|
||||
sinatra (~> 1.3.5)
|
||||
stringex (~> 1.4.0)
|
|
@ -1,38 +0,0 @@
|
|||
## What is Octopress?
|
||||
|
||||
Octopress is [Jekyll](https://github.com/mojombo/jekyll) blogging at its finest.
|
||||
|
||||
1. **Octopress sports a clean responsive theme** written in semantic HTML5, focused on readability and friendliness toward mobile devices.
|
||||
2. **Code blogging is easy and beautiful.** Embed code (with [Solarized](http://ethanschoonover.com/solarized) styling) in your posts from gists, jsFiddle or from your filesystem.
|
||||
3. **Third party integration is simple** with built-in support for Twitter, Pinboard, Delicious, GitHub Repositories, Disqus Comments and Google Analytics.
|
||||
4. **It's easy to use.** A collection of rake tasks simplifies development and makes deploying a cinch.
|
||||
5. **Ships with great plug-ins** some original and others from the Jekyll community — tested and improved.
|
||||
|
||||
|
||||
## Documentation
|
||||
|
||||
Check out [Octopress.org](http://octopress.org/docs) for guides and documentation.
|
||||
|
||||
|
||||
## Contributing
|
||||
|
||||
[![Build Status](https://travis-ci.org/imathis/octopress.png?branch=master)](https://travis-ci.org/imathis/octopress)
|
||||
|
||||
We love to see people contributing to Octopress, whether it's a bug report, feature suggestion or a pull request. At the moment, we try to keep the core slick and lean, focusing on basic blogging needs, so some of your suggestions might not find their way into Octopress. For those ideas, we started a [list of 3rd party plug-ins](https://github.com/imathis/octopress/wiki/3rd-party-plugins), where you can link your own Octopress plug-in repositories. For the future, we're thinking about ways to easier add them them into our main releases.
|
||||
|
||||
|
||||
## License
|
||||
(The MIT License)
|
||||
|
||||
Copyright © 2009-2013 Brandon Mathis
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the ‘Software’), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED ‘AS IS’, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
|
||||
|
||||
#### If you want to be awesome.
|
||||
- Proudly display the 'Powered by Octopress' credit in the footer.
|
||||
- Add your site to the Wiki so we can watch the community grow.
|
383
Rakefile
|
@ -1,383 +0,0 @@
|
|||
require "rubygems"
|
||||
require "bundler/setup"
|
||||
require "stringex"
|
||||
|
||||
## -- Rsync Deploy config -- ##
|
||||
# Be sure your public key is listed in your server's ~/.ssh/authorized_keys file
|
||||
ssh_user = "user@domain.com"
|
||||
ssh_port = "22"
|
||||
document_root = "~/website.com/"
|
||||
rsync_delete = false
|
||||
deploy_default = "push"
|
||||
rsync_args = "" # Any extra arguments to pass to rsync
|
||||
|
||||
# This will be configured for you when you run config_deploy
|
||||
deploy_branch = "master"
|
||||
|
||||
## -- Misc Configs -- ##
|
||||
|
||||
public_dir = "public" # compiled site directory
|
||||
source_dir = "source" # source file directory
|
||||
blog_index_dir = 'source' # directory for your blog's index page (if you put your index in source/blog/index.html, set this to 'source/blog')
|
||||
deploy_dir = "_deploy" # deploy directory (for Github pages deployment)
|
||||
stash_dir = "_stash" # directory to stash posts for speedy generation
|
||||
posts_dir = "_posts" # directory for blog files
|
||||
themes_dir = ".themes" # directory for blog files
|
||||
new_post_ext = "markdown" # default new post file extension when using the new_post task
|
||||
new_page_ext = "markdown" # default new page file extension when using the new_page task
|
||||
server_port = "4000" # port for preview server eg. localhost:4000
|
||||
|
||||
|
||||
desc "Initial setup for Octopress: copies the default theme into the path of Jekyll's generator. Rake install defaults to rake install[classic] to install a different theme run rake install[some_theme_name]"
|
||||
task :install, :theme do |t, args|
|
||||
if File.directory?(source_dir) || File.directory?("sass")
|
||||
abort("rake aborted!") if ask("A theme is already installed, proceeding will overwrite existing files. Are you sure?", ['y', 'n']) == 'n'
|
||||
end
|
||||
# copy theme into working Jekyll directories
|
||||
theme = args.theme || 'classic'
|
||||
puts "## Copying "+theme+" theme into ./#{source_dir} and ./sass"
|
||||
mkdir_p source_dir
|
||||
cp_r "#{themes_dir}/#{theme}/source/.", source_dir
|
||||
mkdir_p "sass"
|
||||
cp_r "#{themes_dir}/#{theme}/sass/.", "sass"
|
||||
mkdir_p "#{source_dir}/#{posts_dir}"
|
||||
mkdir_p public_dir
|
||||
end
|
||||
|
||||
#######################
|
||||
# Working with Jekyll #
|
||||
#######################
|
||||
|
||||
desc "Generate jekyll site"
|
||||
task :generate do
|
||||
raise "### You haven't set anything up yet. First run `rake install` to set up an Octopress theme." unless File.directory?(source_dir)
|
||||
puts "## Generating Site with Jekyll"
|
||||
system "compass compile --css-dir #{source_dir}/stylesheets"
|
||||
system "jekyll"
|
||||
end
|
||||
|
||||
desc "Watch the site and regenerate when it changes"
|
||||
task :watch do
|
||||
raise "### You haven't set anything up yet. First run `rake install` to set up an Octopress theme." unless File.directory?(source_dir)
|
||||
puts "Starting to watch source with Jekyll and Compass."
|
||||
system "compass compile --css-dir #{source_dir}/stylesheets" unless File.exist?("#{source_dir}/stylesheets/screen.css")
|
||||
jekyllPid = Process.spawn({"OCTOPRESS_ENV"=>"preview"}, "jekyll --auto")
|
||||
compassPid = Process.spawn("compass watch")
|
||||
|
||||
trap("INT") {
|
||||
[jekyllPid, compassPid].each { |pid| Process.kill(9, pid) rescue Errno::ESRCH }
|
||||
exit 0
|
||||
}
|
||||
|
||||
[jekyllPid, compassPid].each { |pid| Process.wait(pid) }
|
||||
end
|
||||
|
||||
desc "preview the site in a web browser"
|
||||
task :preview do
|
||||
raise "### You haven't set anything up yet. First run `rake install` to set up an Octopress theme." unless File.directory?(source_dir)
|
||||
puts "Starting to watch source with Jekyll and Compass. Starting Rack on port #{server_port}"
|
||||
system "compass compile --css-dir #{source_dir}/stylesheets" unless File.exist?("#{source_dir}/stylesheets/screen.css")
|
||||
jekyllPid = Process.spawn({"OCTOPRESS_ENV"=>"preview"}, "jekyll --auto")
|
||||
compassPid = Process.spawn("compass watch")
|
||||
rackupPid = Process.spawn("rackup --port #{server_port}")
|
||||
|
||||
trap("INT") {
|
||||
[jekyllPid, compassPid, rackupPid].each { |pid| Process.kill(9, pid) rescue Errno::ESRCH }
|
||||
exit 0
|
||||
}
|
||||
|
||||
[jekyllPid, compassPid, rackupPid].each { |pid| Process.wait(pid) }
|
||||
end
|
||||
|
||||
# usage rake new_post[my-new-post] or rake new_post['my new post'] or rake new_post (defaults to "new-post")
|
||||
desc "Begin a new post in #{source_dir}/#{posts_dir}"
|
||||
task :new_post, :title do |t, args|
|
||||
if args.title
|
||||
title = args.title
|
||||
else
|
||||
title = get_stdin("Enter a title for your post: ")
|
||||
end
|
||||
raise "### You haven't set anything up yet. First run `rake install` to set up an Octopress theme." unless File.directory?(source_dir)
|
||||
mkdir_p "#{source_dir}/#{posts_dir}"
|
||||
filename = "#{source_dir}/#{posts_dir}/#{Time.now.strftime('%Y-%m-%d')}-#{title.to_url}.#{new_post_ext}"
|
||||
if File.exist?(filename)
|
||||
abort("rake aborted!") if ask("#{filename} already exists. Do you want to overwrite?", ['y', 'n']) == 'n'
|
||||
end
|
||||
puts "Creating new post: #{filename}"
|
||||
open(filename, 'w') do |post|
|
||||
post.puts "---"
|
||||
post.puts "layout: post"
|
||||
post.puts "title: \"#{title.gsub(/&/,'&')}\""
|
||||
post.puts "date: #{Time.now.strftime('%Y-%m-%d %H:%M')}"
|
||||
post.puts "comments: true"
|
||||
post.puts "categories: "
|
||||
post.puts "---"
|
||||
end
|
||||
end
|
||||
|
||||
# usage rake new_page[my-new-page] or rake new_page[my-new-page.html] or rake new_page (defaults to "new-page.markdown")
|
||||
desc "Create a new page in #{source_dir}/(filename)/index.#{new_page_ext}"
|
||||
task :new_page, :filename do |t, args|
|
||||
raise "### You haven't set anything up yet. First run `rake install` to set up an Octopress theme." unless File.directory?(source_dir)
|
||||
args.with_defaults(:filename => 'new-page')
|
||||
page_dir = [source_dir]
|
||||
if args.filename.downcase =~ /(^.+\/)?(.+)/
|
||||
filename, dot, extension = $2.rpartition('.').reject(&:empty?) # Get filename and extension
|
||||
title = filename
|
||||
page_dir.concat($1.downcase.sub(/^\//, '').split('/')) unless $1.nil? # Add path to page_dir Array
|
||||
if extension.nil?
|
||||
page_dir << filename
|
||||
filename = "index"
|
||||
end
|
||||
extension ||= new_page_ext
|
||||
page_dir = page_dir.map! { |d| d = d.to_url }.join('/') # Sanitize path
|
||||
filename = filename.downcase.to_url
|
||||
|
||||
mkdir_p page_dir
|
||||
file = "#{page_dir}/#{filename}.#{extension}"
|
||||
if File.exist?(file)
|
||||
abort("rake aborted!") if ask("#{file} already exists. Do you want to overwrite?", ['y', 'n']) == 'n'
|
||||
end
|
||||
puts "Creating new page: #{file}"
|
||||
open(file, 'w') do |page|
|
||||
page.puts "---"
|
||||
page.puts "layout: page"
|
||||
page.puts "title: \"#{title}\""
|
||||
page.puts "date: #{Time.now.strftime('%Y-%m-%d %H:%M')}"
|
||||
page.puts "comments: true"
|
||||
page.puts "sharing: true"
|
||||
page.puts "footer: true"
|
||||
page.puts "---"
|
||||
end
|
||||
else
|
||||
puts "Syntax error: #{args.filename} contains unsupported characters"
|
||||
end
|
||||
end
|
||||
|
||||
# usage rake isolate[my-post]
|
||||
desc "Move all other posts than the one currently being worked on to a temporary stash location (stash) so regenerating the site happens much more quickly."
|
||||
task :isolate, :filename do |t, args|
|
||||
stash_dir = "#{source_dir}/#{stash_dir}"
|
||||
FileUtils.mkdir(stash_dir) unless File.exist?(stash_dir)
|
||||
Dir.glob("#{source_dir}/#{posts_dir}/*.*") do |post|
|
||||
FileUtils.mv post, stash_dir unless post.include?(args.filename)
|
||||
end
|
||||
end
|
||||
|
||||
desc "Move all stashed posts back into the posts directory, ready for site generation."
|
||||
task :integrate do
|
||||
FileUtils.mv Dir.glob("#{source_dir}/#{stash_dir}/*.*"), "#{source_dir}/#{posts_dir}/"
|
||||
end
|
||||
|
||||
desc "Clean out caches: .pygments-cache, .gist-cache, .sass-cache"
|
||||
task :clean do
|
||||
rm_rf [".pygments-cache/**", ".gist-cache/**", ".sass-cache/**", "source/stylesheets/screen.css"]
|
||||
end
|
||||
|
||||
desc "Move sass to sass.old, install sass theme updates, replace sass/custom with sass.old/custom"
|
||||
task :update_style, :theme do |t, args|
|
||||
theme = args.theme || 'classic'
|
||||
if File.directory?("sass.old")
|
||||
puts "removed existing sass.old directory"
|
||||
rm_r "sass.old", :secure=>true
|
||||
end
|
||||
mv "sass", "sass.old"
|
||||
puts "## Moved styles into sass.old/"
|
||||
cp_r "#{themes_dir}/"+theme+"/sass/", "sass"
|
||||
cp_r "sass.old/custom/.", "sass/custom"
|
||||
puts "## Updated Sass ##"
|
||||
end
|
||||
|
||||
desc "Move source to source.old, install source theme updates, replace source/_includes/navigation.html with source.old's navigation"
|
||||
task :update_source, :theme do |t, args|
|
||||
theme = args.theme || 'classic'
|
||||
if File.directory?("#{source_dir}.old")
|
||||
puts "## Removed existing #{source_dir}.old directory"
|
||||
rm_r "#{source_dir}.old", :secure=>true
|
||||
end
|
||||
mkdir "#{source_dir}.old"
|
||||
cp_r "#{source_dir}/.", "#{source_dir}.old"
|
||||
puts "## Copied #{source_dir} into #{source_dir}.old/"
|
||||
cp_r "#{themes_dir}/"+theme+"/source/.", source_dir, :remove_destination=>true
|
||||
cp_r "#{source_dir}.old/_includes/custom/.", "#{source_dir}/_includes/custom/", :remove_destination=>true
|
||||
cp "#{source_dir}.old/favicon.png", source_dir
|
||||
mv "#{source_dir}/index.html", "#{blog_index_dir}", :force=>true if blog_index_dir != source_dir
|
||||
cp "#{source_dir}.old/index.html", source_dir if blog_index_dir != source_dir && File.exists?("#{source_dir}.old/index.html")
|
||||
puts "## Updated #{source_dir} ##"
|
||||
end
|
||||
|
||||
##############
|
||||
# Deploying #
|
||||
##############
|
||||
|
||||
desc "Default deploy task"
|
||||
task :deploy do
|
||||
# Check if preview posts exist, which should not be published
|
||||
if File.exists?(".preview-mode")
|
||||
puts "## Found posts in preview mode, regenerating files ..."
|
||||
File.delete(".preview-mode")
|
||||
Rake::Task[:generate].execute
|
||||
end
|
||||
|
||||
Rake::Task[:copydot].invoke(source_dir, public_dir)
|
||||
Rake::Task["#{deploy_default}"].execute
|
||||
end
|
||||
|
||||
desc "Generate website and deploy"
|
||||
task :gen_deploy => [:integrate, :generate, :deploy] do
|
||||
end
|
||||
|
||||
desc "copy dot files for deployment"
|
||||
task :copydot, :source, :dest do |t, args|
|
||||
FileList["#{args.source}/**/.*"].exclude("**/.", "**/..", "**/.DS_Store", "**/._*").each do |file|
|
||||
cp_r file, file.gsub(/#{args.source}/, "#{args.dest}") unless File.directory?(file)
|
||||
end
|
||||
end
|
||||
|
||||
desc "Deploy website via rsync"
|
||||
task :rsync do
|
||||
exclude = ""
|
||||
if File.exists?('./rsync-exclude')
|
||||
exclude = "--exclude-from '#{File.expand_path('./rsync-exclude')}'"
|
||||
end
|
||||
puts "## Deploying website via Rsync"
|
||||
ok_failed system("rsync -avze 'ssh -p #{ssh_port}' #{exclude} #{rsync_args} #{"--delete" unless rsync_delete == false} #{public_dir}/ #{ssh_user}:#{document_root}")
|
||||
end
|
||||
|
||||
desc "deploy public directory to github pages"
|
||||
multitask :push do
|
||||
puts "## Deploying branch to Github Pages "
|
||||
(Dir["#{deploy_dir}/*"]).each { |f| rm_rf(f) }
|
||||
Rake::Task[:copydot].invoke(public_dir, deploy_dir)
|
||||
puts "\n## copying #{public_dir} to #{deploy_dir}"
|
||||
cp_r "#{public_dir}/.", deploy_dir
|
||||
cd "#{deploy_dir}" do
|
||||
system "git add ."
|
||||
system "git add -u"
|
||||
puts "\n## Commiting: Site updated at #{Time.now.utc}"
|
||||
message = "Site updated at #{Time.now.utc}"
|
||||
system "git commit -m \"#{message}\""
|
||||
puts "\n## Pushing generated #{deploy_dir} website"
|
||||
system "git push origin #{deploy_branch} --force"
|
||||
puts "\n## Github Pages deploy complete"
|
||||
end
|
||||
end
|
||||
|
||||
desc "Update configurations to support publishing to root or sub directory"
|
||||
task :set_root_dir, :dir do |t, args|
|
||||
puts ">>> !! Please provide a directory, eg. rake config_dir[publishing/subdirectory]" unless args.dir
|
||||
if args.dir
|
||||
if args.dir == "/"
|
||||
dir = ""
|
||||
else
|
||||
dir = "/" + args.dir.sub(/(\/*)(.+)/, "\\2").sub(/\/$/, '');
|
||||
end
|
||||
rakefile = IO.read(__FILE__)
|
||||
rakefile.sub!(/public_dir(\s*)=(\s*)(["'])[\w\-\/]*["']/, "public_dir\\1=\\2\\3public#{dir}\\3")
|
||||
File.open(__FILE__, 'w') do |f|
|
||||
f.write rakefile
|
||||
end
|
||||
compass_config = IO.read('config.rb')
|
||||
compass_config.sub!(/http_path(\s*)=(\s*)(["'])[\w\-\/]*["']/, "http_path\\1=\\2\\3#{dir}/\\3")
|
||||
compass_config.sub!(/http_images_path(\s*)=(\s*)(["'])[\w\-\/]*["']/, "http_images_path\\1=\\2\\3#{dir}/images\\3")
|
||||
compass_config.sub!(/http_fonts_path(\s*)=(\s*)(["'])[\w\-\/]*["']/, "http_fonts_path\\1=\\2\\3#{dir}/fonts\\3")
|
||||
compass_config.sub!(/css_dir(\s*)=(\s*)(["'])[\w\-\/]*["']/, "css_dir\\1=\\2\\3public#{dir}/stylesheets\\3")
|
||||
File.open('config.rb', 'w') do |f|
|
||||
f.write compass_config
|
||||
end
|
||||
jekyll_config = IO.read('_config.yml')
|
||||
jekyll_config.sub!(/^destination:.+$/, "destination: public#{dir}")
|
||||
jekyll_config.sub!(/^subscribe_rss:\s*\/.+$/, "subscribe_rss: #{dir}/atom.xml")
|
||||
jekyll_config.sub!(/^root:.*$/, "root: /#{dir.sub(/^\//, '')}")
|
||||
File.open('_config.yml', 'w') do |f|
|
||||
f.write jekyll_config
|
||||
end
|
||||
rm_rf public_dir
|
||||
mkdir_p "#{public_dir}#{dir}"
|
||||
puts "## Site's root directory is now '/#{dir.sub(/^\//, '')}' ##"
|
||||
end
|
||||
end
|
||||
|
||||
desc "Set up _deploy folder and deploy branch for Github Pages deployment"
|
||||
task :setup_github_pages, :repo do |t, args|
|
||||
if args.repo
|
||||
repo_url = args.repo
|
||||
else
|
||||
puts "Enter the read/write url for your repository"
|
||||
puts "(For example, 'git@github.com:your_username/your_username.github.com)"
|
||||
repo_url = get_stdin("Repository url: ")
|
||||
end
|
||||
user = repo_url.match(/:([^\/]+)/)[1]
|
||||
branch = (repo_url.match(/\/[\w-]+\.github\.com/).nil?) ? 'gh-pages' : 'master'
|
||||
project = (branch == 'gh-pages') ? repo_url.match(/\/([^\.]+)/)[1] : ''
|
||||
unless (`git remote -v` =~ /origin.+?octopress(?:\.git)?/).nil?
|
||||
# If octopress is still the origin remote (from cloning) rename it to octopress
|
||||
system "git remote rename origin octopress"
|
||||
if branch == 'master'
|
||||
# If this is a user/organization pages repository, add the correct origin remote
|
||||
# and checkout the source branch for committing changes to the blog source.
|
||||
system "git remote add origin #{repo_url}"
|
||||
puts "Added remote #{repo_url} as origin"
|
||||
system "git config branch.master.remote origin"
|
||||
puts "Set origin as default remote"
|
||||
system "git branch -m master source"
|
||||
puts "Master branch renamed to 'source' for committing your blog source files"
|
||||
else
|
||||
unless !public_dir.match("#{project}").nil?
|
||||
system "rake set_root_dir[#{project}]"
|
||||
end
|
||||
end
|
||||
end
|
||||
url = "http://#{user}.github.com"
|
||||
url += "/#{project}" unless project == ''
|
||||
jekyll_config = IO.read('_config.yml')
|
||||
jekyll_config.sub!(/^url:.*$/, "url: #{url}")
|
||||
File.open('_config.yml', 'w') do |f|
|
||||
f.write jekyll_config
|
||||
end
|
||||
rm_rf deploy_dir
|
||||
mkdir deploy_dir
|
||||
cd "#{deploy_dir}" do
|
||||
system "git init"
|
||||
system "echo 'My Octopress Page is coming soon …' > index.html"
|
||||
system "git add ."
|
||||
system "git commit -m \"Octopress init\""
|
||||
system "git branch -m gh-pages" unless branch == 'master'
|
||||
system "git remote add origin #{repo_url}"
|
||||
rakefile = IO.read(__FILE__)
|
||||
rakefile.sub!(/deploy_branch(\s*)=(\s*)(["'])[\w-]*["']/, "deploy_branch\\1=\\2\\3#{branch}\\3")
|
||||
rakefile.sub!(/deploy_default(\s*)=(\s*)(["'])[\w-]*["']/, "deploy_default\\1=\\2\\3push\\3")
|
||||
File.open(__FILE__, 'w') do |f|
|
||||
f.write rakefile
|
||||
end
|
||||
end
|
||||
puts "\n---\n## Now you can deploy to #{url} with `rake deploy` ##"
|
||||
end
|
||||
|
||||
def ok_failed(condition)
|
||||
if (condition)
|
||||
puts "OK"
|
||||
else
|
||||
puts "FAILED"
|
||||
end
|
||||
end
|
||||
|
||||
def get_stdin(message)
|
||||
print message
|
||||
STDIN.gets.chomp
|
||||
end
|
||||
|
||||
def ask(message, valid_options)
|
||||
if valid_options
|
||||
answer = get_stdin("#{message} #{valid_options.to_s.gsub(/"/, '').gsub(/, /,'/')} ") while !valid_options.include?(answer)
|
||||
else
|
||||
answer = get_stdin(message)
|
||||
end
|
||||
answer
|
||||
end
|
||||
|
||||
desc "list tasks"
|
||||
task :list do
|
||||
puts "Tasks: #{(Rake::Task.tasks - [Rake::Task[:list]]).join(', ')}"
|
||||
puts "(type rake -T for more detail)\n\n"
|
||||
end
|
99
_config.yml
|
@ -1,99 +0,0 @@
|
|||
# ----------------------- #
|
||||
# Main Configs #
|
||||
# ----------------------- #
|
||||
|
||||
url: http://abhin4v.github.com
|
||||
title: abhinavsarkar.net
|
||||
subtitle:
|
||||
author: Abhinav Sarkar
|
||||
simple_search: http://google.com/search
|
||||
description:
|
||||
|
||||
# Default date format is "ordinal" (resulting in "July 22nd 2007")
|
||||
# You can customize the format as defined in
|
||||
# http://www.ruby-doc.org/core-1.9.2/Time.html#method-i-strftime
|
||||
# Additionally, %o will give you the ordinal representation of the day
|
||||
date_format: "ordinal"
|
||||
|
||||
# RSS / Email (optional) subscription links (change if using something like Feedburner)
|
||||
subscribe_rss: /atom.xml
|
||||
subscribe_email:
|
||||
# RSS feeds can list your email address if you like
|
||||
email:
|
||||
|
||||
# ----------------------- #
|
||||
# Jekyll & Plugins #
|
||||
# ----------------------- #
|
||||
|
||||
# If publishing to a subdirectory as in http://site.com/project set 'root: /project'
|
||||
root: /
|
||||
permalink: /blog/:year/:month/:day/:title/
|
||||
source: source
|
||||
destination: public
|
||||
plugins: plugins
|
||||
code_dir: downloads/code
|
||||
category_dir: blog/cats
|
||||
markdown: rdiscount
|
||||
pygments: false # default python pygments have been replaced by pygments.rb
|
||||
|
||||
paginate: 10 # Posts per page on the blog index
|
||||
pagination_dir: blog # Directory base for pagination URLs eg. /blog/page/2/
|
||||
recent_posts: 5 # Posts in the sidebar Recent Posts section
|
||||
excerpt_link: "Read on →" # "Continue reading" link text at the bottom of excerpted articles
|
||||
|
||||
titlecase: true # Converts page and post titles to titlecase
|
||||
|
||||
# list each of the sidebar modules you want to include, in the order you want them to appear.
|
||||
# To add custom asides, create files in /source/_includes/custom/asides/ and add them to the list like 'custom/asides/custom_aside_name.html'
|
||||
default_asides: [asides/recent_posts.html, asides/github.html, asides/twitter.html, asides/delicious.html, asides/pinboard.html, asides/googleplus.html]
|
||||
|
||||
# Each layout uses the default asides, but they can have their own asides instead. Simply uncomment the lines below
|
||||
# and add an array with the asides you want to use.
|
||||
# blog_index_asides:
|
||||
# post_asides:
|
||||
# page_asides:
|
||||
|
||||
# ----------------------- #
|
||||
# 3rd Party Settings #
|
||||
# ----------------------- #
|
||||
|
||||
# Github repositories
|
||||
github_user: abhin4v
|
||||
github_repo_count: 5
|
||||
github_show_profile_link: true
|
||||
github_skip_forks: true
|
||||
|
||||
# Twitter
|
||||
twitter_user: abhin4v
|
||||
twitter_tweet_count: 5
|
||||
twitter_show_replies: false
|
||||
twitter_follow_button: true
|
||||
twitter_show_follower_count: false
|
||||
twitter_tweet_button: false
|
||||
|
||||
# Google +1
|
||||
google_plus_one: false
|
||||
google_plus_one_size: medium
|
||||
|
||||
# Google Plus Profile
|
||||
# Hidden: No visible button, just add author information to search results
|
||||
googleplus_user:
|
||||
googleplus_hidden: false
|
||||
|
||||
# Pinboard
|
||||
pinboard_user:
|
||||
pinboard_count: 3
|
||||
|
||||
# Delicious
|
||||
delicious_user: abhin4v
|
||||
delicious_count: 3
|
||||
|
||||
# Disqus Comments
|
||||
disqus_short_name: abhinavsarkarnet
|
||||
disqus_show_comment_count: false
|
||||
|
||||
# Google Analytics
|
||||
google_analytics_tracking_id:
|
||||
|
||||
# Facebook Like
|
||||
facebook_like: false
|
Before Width: | Height: | Size: 141 B After Width: | Height: | Size: 141 B |
Before Width: | Height: | Size: 82 B After Width: | Height: | Size: 82 B |
Before Width: | Height: | Size: 118 B After Width: | Height: | Size: 118 B |
Before Width: | Height: | Size: 203 B After Width: | Height: | Size: 203 B |
Before Width: | Height: | Size: 636 B After Width: | Height: | Size: 636 B |
Before Width: | Height: | Size: 343 B After Width: | Height: | Size: 343 B |
Before Width: | Height: | Size: 835 B After Width: | Height: | Size: 835 B |
Before Width: | Height: | Size: 210 B After Width: | Height: | Size: 210 B |
Before Width: | Height: | Size: 664 B After Width: | Height: | Size: 664 B |
Before Width: | Height: | Size: 170 B After Width: | Height: | Size: 170 B |
Before Width: | Height: | Size: 442 B After Width: | Height: | Size: 442 B |
Before Width: | Height: | Size: 251 B After Width: | Height: | Size: 251 B |
Before Width: | Height: | Size: 553 B After Width: | Height: | Size: 553 B |
Before Width: | Height: | Size: 112 B After Width: | Height: | Size: 112 B |
Before Width: | Height: | Size: 94 B After Width: | Height: | Size: 94 B |
Before Width: | Height: | Size: 103 B After Width: | Height: | Size: 103 B |
Before Width: | Height: | Size: 114 B After Width: | Height: | Size: 114 B |
Before Width: | Height: | Size: 116 B After Width: | Height: | Size: 116 B |