Skip to content

Instantly share code, notes, and snippets.

View eculver's full-sized avatar
🧠
Braining

Evan Culver eculver

🧠
Braining
View GitHub Profile
@eculver
eculver / interesting font strings
Created June 4, 2010 18:30
interesting font strings
'ITC Avant Garde Gothic', 'Century Gothic', Helvetica, Arial, sans-serif; /* ohdoctah.com */
@eculver
eculver / gist:530619
Created August 17, 2010 16:15 — forked from padolsey/gist:527683
Super sexy IE detection
// ----------------------------------------------------------
// If you're not in IE (or IE version is less than 5) then:
// ie === undefined
// If you're in IE (>5) then you can determine which version:
// ie === 7; // IE7
// Thus, to detect IE:
// if (ie) {}
// And to detect the version:
// ie === 6 // IE6
// ie > 7 // IE8, IE9 ...
@eculver
eculver / recursive find and replace with sed
Created September 23, 2010 05:13
recursive find and replace with sed
find ./ -type f -exec sed -i 's/string1/string2/g' {} \;
@eculver
eculver / Copy SSH keys to remote host
Created October 7, 2010 16:12
Copy SSH keys to remote host
ssh-copy-id -i /root/.ssh/id_rsa.pub [email protected]
@eculver
eculver / gist:615932
Created October 7, 2010 21:34 — forked from paulirish/gist:576335
Things to do when IE9 Beta comes out

Things to do when IE9 Beta comes out

Note significant features added since IE9 PP4

  • Implemented but not announced: box-shadow, hsla
  • Expecting: 2d transforms, css animation, css transitions, flexible box model
  • Maybe: gradients, columns, reflections, svg filters, uncrippling @font-face, 3d transforms
  • Maybe version auto-update functionality

Test Modernizr against it

  • Does it still throw an error checking elem.msTransform?
@eculver
eculver / x-browser CSS opacity
Created October 11, 2010 16:21
x-browser CSS opacity
selector {
filter: alpha(opacity=90);
height: 58px;
-moz-opacity: .9;
-ms-filter: 'progid:DXImageTransform.Microsoft.Alpha(Opacity=90)';
opacity: .9;
-webkit-opacity: .9;
}
@eculver
eculver / Pass arguments to bash "alias"
Created October 11, 2010 23:28
Pass arguments to bash "alias"
function durrgrep () {
grep -Ir -s --exclude="*\.svn*" $*
}
echo 'export PATH=$HOME/local/bin:$PATH' >> ~/.bashrc
. ~/.bashrc
mkdir ~/local
mkdir ~/node-latest-install
cd ~/node-latest-install
curl http://nodejs.org/dist/node-latest.tar.gz | tar xz --strip-components=1
./configure --prefix=~/local
make install
curl http://npmjs.org/install.sh | sh
@eculver
eculver / directory
Created November 13, 2010 02:17
bash -- removes the oldest file/directory.
ls -t | tail -n1 | xargs rm -rf
@eculver
eculver / nth line number
Created November 19, 2010 20:38
nth line number
awk '{ if (NR==n) print $0 }' file