This file contains 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
// No directories with --follow. | |
git log -M --follow <filename> |
This file contains 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
// http://stackoverflow.com/a/2133217/292408 | |
function scrollToTop() { | |
$( "div.scroll" ).scrollTop( -10000 ) | |
} | |
setInterval( scrollToTop, 1000 ); | |
// clearInterval(tid); |
This file contains 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
// http://jonthegeek.blogspot.be/2009/07/multi-parameter-firefox-keywords-and.html | |
javascript: | |
var s='%s'; | |
url='http://maps.google.com/maps?saddr=%s&daddr=%s'; | |
query=''; | |
urlchunks=url.split('%s'); | |
schunks=s.split(';'); | |
for(i=0; i<schunks.length; i++)query+=urlchunks[i]+schunks[i]; | |
location.replace(query); |
This file contains 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
System Load Indicator - https://launchpad.net/indicator-multiload | |
cp -p /etc/hosts | |
cp -p /etc/apache2/sites-available | |
Chrome | |
Inkscape | |
Composer Global | |
Drush via Composer | |
PhpStorm + Codesniffer & Drupal Coder rules via Composer | |
Insync | |
Tmux |
This file contains 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 | |
# https://gist.github.com/gregferrell/747642 | |
if [[ $1 ]]; | |
then | |
php -r " echo var_dump(unserialize('"$1"')); echo \"\\n\";" | |
else | |
STRING=`pbpaste` | |
php -r " echo var_dump(unserialize('"$STRING"')); echo \"\\n\";" | |
fi |
This file contains 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 throttle( fn, time ) { | |
var t = 0; | |
return function() { | |
var args = arguments, ctx = this; | |
clearTimeout(t); | |
t = setTimeout( function() { | |
fn.apply( ctx, args ); | |
}, time ); | |
}; |
This file contains 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
sudo -E -u www-data drush @pub7.local test-run ActionsConfigurationTestCase --uri=loc.example.com |
This file contains 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
<div class="crosshair"></div> |
This file contains 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
open new hotfix branch off of tag | |
merge branch into master | |
tag the branch SPECIAL | |
* cd into root of clone | |
* ./builds/scripts/pub-tag.sh 7.23.1 (example, don't use v prefix, script does it for us) | |
* ./builds/scripts/pub-tag2.sh | |
* git checkout master --force | |
* ./builds/scripts/pub-tag3.sh | |
NOTE: If pub-tag2.sh and pub-tag3.sh don't work or you get confused that is okay. pub-tag.sh is the one that really does the tag but contact Sam Boyer and let him know about it. If all you can ever do is the first script, that is fine. |
This file contains 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/sh | |
HEART_FULL=♥ | |
HEART_EMPTY=♡ | |
[ -z "$NUM_HEARTS" ] && | |
NUM_HEARTS=5 | |
cutinate() | |
{ | |
perc=$1 |