Skip to content

Instantly share code, notes, and snippets.

#!/bin/bash
hash make 2>&- || { echo >&2 "I require make but it's not installed. Aborting."; exit 1; }
hash autoreconf 2>&- || { echo >&2 "I require aureconf but it's not installed. Aborting."; exit 1; }
hash unzip 2>&- || { echo >&2 "I require unzip but it's not installed. Aborting."; exit 1; }
hash svn 2>&- || { echo >&2 "I require svn but it's not installed. Aborting."; exit 1; }
function errorcheck(){
if [ "$?" -gt 0 ]; then
@lotsofcode
lotsofcode / .bashrc
Created December 13, 2011 20:10 — forked from endtwist/.bashrc
Bash config
PS1="\[\e[0:32m\]\w \[\e[0;39m\]\$ "
if [ -f ~/.git-completion.bash ]; then
source ~/.git-completion.bash
PS1="\[\e[0:32m\]\w"'$(__git_ps1 " \[\e[1;30m\](%s)")'"\[\e[0;39m\]\$ "
fi
export CLICOLOR=1
export ll='ls -al'
@lotsofcode
lotsofcode / hack.sh
Created March 31, 2012 11:28 — forked from erikh/hack.sh
OSX For Hackers
#!/usr/bin/env sh
##
# This is script with usefull tips taken from:
# https://github.com/mathiasbynens/dotfiles/blob/master/.osx
#
# install it:
# curl -sL https://raw.github.com/gist/2108403/hack.sh | sh
#
@lotsofcode
lotsofcode / Custom.css
Created May 25, 2012 10:00 — forked from bentruyman/Custom.css
IR_Black Theme for Chrome Developer Tools
/**********************************************/
/*
/* IR_Black Skin by Ben Truyman - 2011
/*
/* Based on Todd Werth's IR_Black:
/* http://blog.toddwerth.com/entries/2
/*
/* Inspired by Darcy Clarke's blog post:
/* http://darcyclarke.me/design/skin-your-chrome-inspector/
/*
@lotsofcode
lotsofcode / readme2ghpage.rb
Created June 22, 2012 15:37 — forked from hopsoft/readme2ghpage.rb
Convert your README.md on master to index.md on gh-pages
#!/usr/bin/env ruby
# checkout the readme from the master branch
`git checkout gh-pages; git checkout master README.md`
path = `pwd`.gsub(/\n/, "")
readme_path = File.join(path, "README.md")
index_path = File.join(path, "index.md")
# write the index readme file
@lotsofcode
lotsofcode / new_bashrc.sh
Created August 11, 2012 09:17 — forked from josephwecker/new_bashrc.sh
Replace .bashrc, .bash_profile, .profile, etc. with something much more clean, consistent, and meaningful.
#!/bin/bash
# License: Public Domain.
# Author: Joseph Wecker, 2012
#
# Are you tired of trying to remember what .bashrc does vs .bash_profile vs .profile?
# Are you tired of trying to remember how darwin/mac-osx treat them differently from linux?
# Are you tired of not having your ~/.bash* stuff work the way you expect?
#
# Symlink all of the following to this file:
# * ~/.bashrc
@lotsofcode
lotsofcode / slug.js
Created October 4, 2012 15:32 — forked from bentruyman/slug.js
JavaScript Slug Generator
// Generates a URL-friendly "slug" from a provided string.
// For example: "This Is Great!!!" transforms into "this-is-great"
function generateSlug (value) {
// 1) convert to lowercase
// 2) remove dashes and pluses
// 3) replace spaces with dashes
// 4) remove everything but alphanumeric characters and dashes
return value.toLowerCase().replace(/-+/g, '').replace(/\s+/g, '-').replace(/[^a-z0-9-]/g, '');
};
@lotsofcode
lotsofcode / jQuery.ajaxQueue.min.js
Created October 11, 2012 16:04 — forked from gnarf/jQuery.ajaxQueue.min.js
jQuery.ajaxQueue - A queue for ajax requests
/*
* jQuery.ajaxQueue - A queue for ajax requests
*
* (c) 2011 Corey Frang
* Dual licensed under the MIT and GPL licenses.
*
* Requires jQuery 1.5+
*/
(function(a){var b=a({});a.ajaxQueue=function(c){function g(b){d=a.ajax(c).done(e.resolve).fail(e.reject).then(b,b)}var d,e=a.Deferred(),f=e.promise();b.queue(g),f.abort=function(h){if(d)return d.abort(h);var i=b.queue(),j=a.inArray(g,i);j>-1&&i.splice(j,1),e.rejectWith(c.context||c,[f,h,""]);return f};return f}})(jQuery)
cd PATH_TO_YOUR_DEVKIT_DIR
ruby dk.rb init
ruby dk.rb install
// $mq-mobile-portrait : 320px !default;
// $mq-mobile-landscape : 480px !default;
// $mq-tablet-portrait : 640px !default; -- changed because i want my blog content is around this wide, not 768. you should let content & design determine your breakpoints
// $mq-tablet-landscape : 1024px !default;
// $mq-desktop : 1382px !default;
$mq-mobile-portrait : 20em !default;
$mq-mobile-landscape : 30em !default;
$mq-tablet-portrait : 40em !default;
$mq-tablet-landscape : 64em !default;