Skip to content

Instantly share code, notes, and snippets.

@alexpos
Created January 10, 2013 10:01
Show Gist options
  • Save alexpos/4500891 to your computer and use it in GitHub Desktop.
Save alexpos/4500891 to your computer and use it in GitHub Desktop.
Sublime text - settings & snippets
{
//Plovs' Preferences.sublime-settings
// Theme Settings
"color_scheme": "Packages/Color Scheme - Default/Solarized (Light).tmTheme",
"fade_fold_buttons": false,
"bold_folder_labels": true,
"font_face": "Source Code Pro",
"font_size": 12.0,
"caret_style": "phase",
"highlight_line": true,
"line_padding_bottom": 1,
"highlight_active_indent_guide": true,
// Indentation
"detect_indentation": true,
"ensure_newline_at_eof_on_save": true,
"tab_size": 4,
"translate_tabs_to_spaces": false,
"trim_trailing_white_space_on_save": true,
//cmd-p
"file_exclude_patterns": [ "*.pyc", "*.pyo", "*.exe", "*.dll", "*.obj", "*.o", "*.a", "*.lib", "*.so", "*.dylib", "*.ncb", "*.sdf", "*.suo", "*.pdb", "*.idb", ".DS_Store", "*.class", "*.psd", "*.db" ],
"folder_exclude_patterns": [ ".svn", ".git", ".hg", "CVS", ".bundle", "log", "tmp", ".sass-cache" ],
// paths
"git_command": "/usr/bin/git",
//packages
"ignored_packages":
[
"Vintage"
]
}
# source: https://gist.github.com/4500280
#
# Bash command to fix a quirk with Sublime Text 2's "subl" command. Sometimes, when using it, under hard-to-pinpoint
# circumstances, it will open up Sublime Text 2 completely blank (i.e. the file you asked it to open will not be open).
# This snippet fixes that by essentially kicking subl under the table to wake it up and then passing on the command as
# originally typed. It doesn't do it in the event of piped stdin input, as the bug doesn't exhibit here and otherwise it
# would open another Sublime Text 2 window after you closed the first one.
function subl() {
if [[ ! -p /dev/stdin ]]; then
command subl > /dev/null 2>&1
fi
command subl "$@"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment