⌘T | go to file |
⌘⌃P | go to project |
⌘R | go to methods |
⌃G | go to line |
⌘KB | toggle side bar |
⌘⇧P | command prompt |
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
Show hidden characters
[ | |
{ "command": "set_mark" }, | |
{ "command": "move_to", "args": {"to": "eol"} }, | |
{ "command": "insert_snippet", "args": {"contents": "${TM_LINE_TERMINATOR:;}"} }, | |
{ "command": "swap_with_mark" } | |
] |
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 function was used in my test rig to convert elasticsearch results to a KML structure which is | |
// later fed to an iFrame wrapping the GoogleEarth plugin | |
var data=[]; | |
var buckets=inData.aggregations.map.buckets; | |
function addCommas(nStr) | |
{ | |
nStr += ''; |
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
#cloud-config | |
ssh_authorized_keys: | |
- ssh-rsa xyz | |
write_files: | |
- path: /var/lib/rancher/conf/cloud-config.yml | |
permissions: "0644" | |
owner: root | |
content: | | |
#cloud-config | |
ssh_authorized_keys: |
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
// CSVToMap takes a reader and returns an array of dictionaries, using the header row as the keys | |
func CSVToMap(reader io.Reader) []map[string]string { | |
r := csv.NewReader(reader) | |
rows := []map[string]string{} | |
var header []string | |
for { | |
record, err := r.Read() | |
if err == io.EOF { | |
break | |
} |
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
grep -L <TEXT> --exclude "<EXCLUDE PATTERN>" */**/* |
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
// Checkout the readme for this here: https://github.com/tilaklodha/google-authenticator | |
package main | |
import ( | |
"bytes" | |
"crypto/hmac" | |
"crypto/sha1" | |
"encoding/base32" | |
"encoding/binary" |