⌘T | go to file |
⌘⌃P | go to project |
⌘KB | toggle side bar |
⌘⇧P | command prompt |
⌃ ` | python console |
⌘⇧N | new window (useful for new project) |
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
Homebrew (https://github.com/mxcl/homebrew/wiki/installation) | |
brew install postgres | |
brew install gdal --with-postgres (EDIT THE FORMULA FIRST, see https://github.com/mxcl/homebrew/issues/8301) | |
brew install postgis | |
edit /etc/paths to put /usr/local/bin on top, so that lion's psql doesnt win | |
PostGIS templates (based on https://wiki.archlinux.org/index.php/PostGIS) | |
createdb template_postgis -E UTF8 | |
createlang plpgsql template_postgis | |
psql -d template_postgis -f /usr/local/share/postgis/postgis.sql |
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
/* | |
IOS CHECK | |
Based on: http://stackoverflow.com/questions/8348139/detect-ios-version-less-than-5-with-javascript | |
*/ | |
(function(){ | |
NYTD.NYTMM.iOS = false; | |
NYTD.NYTMM.iOSInfo = { | |
userAgent: null, | |
version: null, // major versions of iOS: 4,5,6 | |
minor: null, // minor versions: 1, for 5.1 |
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
// Based on pieces from this thread: | |
// http://stackoverflow.com/questions/1881716/merging-jquery-objects | |
// use: var currentRowEls = []; // array of various jQ ojbects | |
// $.mergeSelectors(currentRowEls).css({width:'200px'}); | |
(function($){ | |
$.mergeSelectors = function(objs) { | |
var ret = objs.shift(); | |
while (objs.length) { | |
ret = ret.add(objs.shift()); |
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
this.$portfolioItems.removeClass(function(index, cssClass){ | |
return (cssClass.match (/(?:(?:row|col)-[\d]|last-row|first-row)/) || []).join(' '); | |
}) |
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
brew install ffmpeg --with-libvorbis --with-nonfree --with-gpl --with-libvpx --with-pthreads --with-libx264 --with-libfaac --with-libtheora |
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
Source: http://mmb.pcb.ub.es/~carlesfe/unix/tricks.txt | |
I have marked with a * those which I think are absolutely essential | |
Items for each section are sorted by oldest to newest. Come back soon for more! | |
BASH | |
* In bash, 'ctrl-r' searches your command history as you type | |
- Input from the commandline as if it were a file by replacing | |
'command < file.in' with 'command <<< "some input text"' | |
- '^' is a sed-like operator to replace chars from last command |
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
find . -name '*.JPG' | awk 'BEGIN{ a=1 }{ printf "mv %s %04d.jpg\n", $0, a++ }' | bash; | |
ffmpeg -r 24 -f image2 -s 1920x1280 -i %4d.jpg -vcodec libx264 -crf 15 test.mp4 |
OlderNewer