Skip to content

Instantly share code, notes, and snippets.

View natlownes's full-sized avatar

Nat Lownes natlownes

View GitHub Profile
-R
--exclude=.git
--exclude=node_modules
--exclude=Session*.vim
--langdef=coffee
--langmap=coffee:.coffee
--regex-coffee=/^[ \t]*class ([a-zA-Z_$][0-9a-zA-Z_$]*).*$/\1/c,class/
--regex-coffee=/^[ \t]*([a-zA-Z_$@][0-9a-zA-Z_$\.]*)[ \t]*[:=].*[=-]>.*$/\1/f,function/
--regex-coffee=/^[ \t]*([a-zA-Z_$@][0-9a-zA-Z_$\.]*)[ \t]*=[^->\n]*$/\1/v,variable/
" tagbar
let g:tagbar_usearrows = 1
nnoremap <leader>T :TagbarToggle<CR>
let g:tagbar_type_coffee = {
\ 'ctagstype' : 'coffee',
\ 'kinds' : [
\ 'c:classes',
\ 'f:functions',
\ 'v:variables'
\ ],
_ = require 'lodash'
mixinEvents = (obj) ->
obj_destroy = obj.destroy
_.extend obj,
_listeners: {}
_listeningTo: []
sudo killall -9 xbmc.bin
sudo killall -9 xbmc-standalone
sudo killall -9 Xorg
sudo /etc/init.d/gdm3 stop
sudo /etc/init.d/gdm3 start
0 info it worked if it ends with ok
1 verbose cli [ 'node', '/Users/nat/.nvm/v0.8.23/bin/npm', 'publish', '.' ]
2 info using [email protected]
3 info using [email protected]
4 verbose publish [ '.' ]
5 verbose read json /Users/nat/src/headrest/package.json
6 verbose cache add [ '.', null ]
7 silly cache add name=undefined spec="." args=[".",null]
8 verbose parsed url { pathname: '.', path: '.', href: '.' }
9 silly lockFile 3a52ce78- .
@natlownes
natlownes / gist:6554889
Created September 13, 2013 19:20
rebuild CtrlP cache and ctags
augroup RebuildCaches
autocmd!
autocmd BufWritePost * call RebuildTags()
autocmd FocusGained * CtrlPClearCache
autocmd BufWritePost * CtrlPClearCache
augroup END
function! RebuildTags()
let cmd = 'ctags -R'
let output=system(cmd)
var head = document.getElementsByTagName('head')[0];
var script = document.createElement('script');
script.onload = function() {
var hrefs = jQuery('a[href*=".wav"]');
for(var i=0;i<hrefs.length;i++) {
var uri = (hrefs[i].href);
var audio = jQuery('<audio autoplay loop src="' + uri + '">')
jQuery('body').append(audio);
};
}

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname
var fs = require("fs"),
http = require("http"),
path = require("path"),
url = require("url"),
util = require("util"),
sys = require("sys"),
zlib = require('zlib');
var port = parseFloat(process.argv[2]) || 8081;
### Keybase proof
I hereby claim:
* I am natlownes on github.
* I am narf (https://keybase.io/narf) on keybase.
* I have a public key whose fingerprint is 4883 C577 22A3 0ADC F196 2484 A77D 30B9 3D83 A61A
To claim this, I am signing this object: