Skip to content

Instantly share code, notes, and snippets.

View debuggingfuture's full-sized avatar

debuggingfuture (Vincent) debuggingfuture

View GitHub Profile
@debuggingfuture
debuggingfuture / gist:5652575
Last active March 10, 2016 22:01
In Sublime Text 2 to use `Cmd-Shift-F` to reindent javascript with jsFormat without affecting other format, put this in the Key Bindings :
{
"keys": ["super+shift+f"], "command": "js_format"
},
{
"keys": ["super+shift+f"], "command": "reindent"
,"context":
[{ "key": "selector", "operator": "not_equal", "operand": "source.js"},
{ "key": "selector", "operator": "not_equal", "operand": "source.json"}
]
}
@debuggingfuture
debuggingfuture / gist:5548010
Last active December 17, 2015 04:08
test case for cheeatz
document.write('Hello World!');
//print only first column from space separated file using awk
cat input.ssv | awk '{print $1}'
@debuggingfuture
debuggingfuture / lsof-i.sh
Last active December 16, 2015 23:58
List process
//List all process with open network connection
sudo lsof -i
@debuggingfuture
debuggingfuture / type-a.sh
Last active December 16, 2015 23:50
Check how a command will be interpreted in BASH
//Check a command is built in / alias / external
~ $ type ls
ls is hashed (/bin/ls)
//external
~ $ type cdcd is a function
//function

key|desc ---|---|--- Ctrl-2, l | Assign to local variable