Skip to content

Instantly share code, notes, and snippets.

View jcrosen's full-sized avatar

Jeremy Villasenor jcrosen

View GitHub Profile
@jcrosen
jcrosen / discogs_api_oauth_console_example.py
Last active February 9, 2018 00:31
Example discogs API console with built-in Oauth support
#!/usr/bin/env python
#
# This illustrates the call-flow required to complete an OAuth request
# against the discogs.com API. The script will download and save a single
# image from the discogs.com API as an example.
# See README.md for further documentation.
#
import oauth2 as oauth
import urlparse
import json
@jcrosen
jcrosen / Default (OSX).sublime-keymap
Created March 14, 2014 18:21
my custom sublime keymap
[
{ "keys": ["tab"], "command": "move", "args": {"by": "characters", "forward": true, "separators": true}, "context":
[
{ "key": "preceding_text", "operator": "not_regex_contains", "operand": " $", "match_all": true },
{ "key": "following_text", "operator": "regex_contains", "operand": "^[)'\"\\]}]", "match_all": true },
{ "key": "auto_complete_visible", "operator": "equal", "operand": false },
{ "key": "selection_empty", "operator": "equal", "operand": true },
]
},
{ "keys": ["super+shift+w"], "command": "close_window" },
@jcrosen
jcrosen / gist:6769287
Last active December 24, 2015 08:18 — forked from lucasfais/gist:1207002
Sublime Text 2 - Useful Shortcuts (Mac OS X)

Sublime Text 2 Shortcuts (Mac OS X)

Editing

⌘L select line (repeat select next lines)
⌘D select word (repeat select others occurrences in context for multiple editing)
⌃⇧M select content into brackets
⌘⇧↩ insert line before
⌘↩ inter line after
⌃⇧K delete line
[alias]
st = status
ci = commit
br = branch
co = checkout
cob = checkout -b
com = checkout master
df = diff
l = log -p --graph --abbrev-commit --decorate
lg = log --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr)%Creset' --abbrev-commit --date=relative