This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"use strict"; | |
var history = window.history; | |
var routes = {}; | |
var defaultCallback; | |
function applyRoutes() { | |
var callback = routes[document.location.pathname]; | |
if (callback) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
DEFAULT="\e[39m" | |
RED="\e[31m" | |
GREEN="\e[32m" | |
YELLOW="\e[33m" | |
BLUE="\e[34m" | |
MAGENTA="\e[35m" | |
CYAN="\e[36m" | |
GRAY="\e[37m" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function red (text) { return colorize(text, 'red') } | |
function green (text) { return colorize(text, 'green') } | |
function yellow (text) { return colorize(text, 'yellow') } | |
function blue (text) { return colorize(text, 'blue') } | |
function magenta (text) { return colorize(text, 'magenta') } | |
function cyan (text) { return colorize(text, 'cyan') } | |
function gray (text) { return colorize(text, 'gray') } | |
function colorize(text, color, style) { | |
// color: 'red', 'green', 'blue'... (see below) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var gulp = require('gulp'); | |
gulp.task('default', function (done) { | |
var chalk = require('chalk'); | |
console.log(''); | |
console.log(chalk.bold('Available tasks')); | |
console.log(chalk.cyan(' build') + ' Build and minify the application.'); | |
console.log(chalk.cyan(' clean') + ' Clean the build directory.'); | |
console.log(chalk.cyan.bold(' default') + ' Display this help.'); | |
console.log(chalk.cyan(' dist') + ' Create a distributable .tar.gz file.'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Show hidden characters
{ | |
"curly": true, | |
"eqeqeq": true, | |
"immed": true, | |
"latedef": false, | |
"newcap": true, | |
"noarg": true, | |
"sub": true, | |
"undef": true, | |
"unused": true, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[color] | |
ui = true | |
[core] | |
editor = vim | |
[push] | |
default = simple | |
[alias] | |
last = cat-file commit HEAD | |
cm = commit -a -m\"[refactor] code mort\" | |
format = commit -a -m\"[refactor] format\" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cd pictures | |
FILES=$( find . -type f -name "*jpg" | sort -V ) | |
mkdir temp && cd temp | |
for file in $FILES; do | |
BASE=$(echo $file | sed 's/.jpg//g'); | |
convert ../$BASE.jpg $BASE.pdf; | |
done && | |
pdftk *pdf cat output ../FINAL_NAME.pdf && | |
cd .. | |
rm -rf temp |