Skip to content

Instantly share code, notes, and snippets.

First create an account on Heroku and download the Heroku Toolbelt.
Then open the terminal and sign into Heroku (it will ask for email/password and to generate a public key): $ heroku login
Now I just cd'ed in to my project folder and create an Heroku app (Cedar becoming the default stack): $ heroku create
FInally, add all the Kirby files to that folder plus the files needed for the mbstring functions (you can get them here in php/mbstring/ –just rename example-php.ini to php.ini).
That's it, just $ git push heroku master and you're done!
@media only screen and (min-width: 320px) {
/* Small screen, non-retina */
}
@media
only screen and (-webkit-min-device-pixel-ratio: 2) and (min-width: 320px),
only screen and ( min--moz-device-pixel-ratio: 2) and (min-width: 320px),
only screen and ( -o-min-device-pixel-ratio: 2/1) and (min-width: 320px),
@Vestride
Vestride / Cleanup Layer Comps.jsx
Created July 5, 2012 02:02
Photoshop layer comp cleanup script
/**
* Photoshop layer comp cleanup script
*
* This script will run through all the layer comps, find layers that are hidden in every comp
* as well as any groups that are empty and delete them. Save before doing this just in case ;)
*
* @author Glen Cheney (http://glencheney)
* @version 1.1
* @date 7.10.12
*/
@jlong
jlong / uri.js
Created April 20, 2012 13:29
URI Parsing with Javascript
var parser = document.createElement('a');
parser.href = "http://example.com:3000/pathname/?search=test#hash";
parser.protocol; // => "http:"
parser.hostname; // => "example.com"
parser.port; // => "3000"
parser.pathname; // => "/pathname/"
parser.search; // => "?search=test"
parser.hash; // => "#hash"
parser.host; // => "example.com:3000"
@millermedeiros
millermedeiros / gist:891886
Created March 29, 2011 06:21
iPad HTML5 video quirks and hacks
/*
* Example how to preload HTML5 video on the iPad (iOS 3.2+)
* @author Miller Medeiros
* Released under WTFPL
*/
var vid = document.createElement('video');
vid.src = 'lol_catz.mp4';
document.getElementById('video-holder').appendChild(vid);
/*
---
name: guilloche
script: guilloche.js
description: guilloche
provides: [Guilloche]
...
*/
@remy
remy / audiosprite.js
Created December 23, 2010 13:54
An example of how an audio sprite can be used (includes fixes for iOS)
function Track(src, spriteLength, audioLead) {
var track = this,
audio = document.createElement('audio');
audio.src = src;
audio.autobuffer = true;
audio.load();
audio.muted = true; // makes no difference on iOS :(
/* This is the magic. Since we can't preload, and loading requires a user's
input. So we bind a touch event to the body, and fingers crossed, the