├── sublime ├── User │ ├── Package Control.user-ca-bundle │ ├── Markdown.sublime-settings │ ├── JavaScript.sublime-settings │ ├── Sass.sublime-settings │ ├── Ruby Haml.sublime-settings │ ├── Ruby Slim.sublime-settings │ ├── HTML (Rails).sublime-settings │ ├── Python.sublime-settings │ ├── JavaScript (Babel).sublime-settings │ ├── YAML.sublime-settings │ ├── Shell-Unix-Generic.sublime-settings │ ├── PHP.sublime-settings │ ├── XML.sublime-settings │ ├── Default.sublime-keymap │ ├── JSON.sublime-settings │ ├── Ruby.sublime-settings │ ├── SassBeautify.sublime-settings │ ├── Package Control.sublime-settings │ ├── ApplySyntax.ext-list │ ├── Preferences.sublime-settings │ ├── ApplySyntax.sublime-settings │ ├── SublimeLinter.sublime-settings │ └── SublimeLinter │ │ ├── All Hallow's Eve (SL).tmTheme │ │ ├── LAZY (SL).tmTheme │ │ ├── Zenburnesque (SL).tmTheme │ │ ├── Blackboard (SL).tmTheme │ │ ├── Monokai Bright (SL).tmTheme │ │ ├── Monokai (SL).tmTheme │ │ ├── Espresso Libre (SL).tmTheme │ │ ├── Dawn (SL).tmTheme │ │ ├── Twilight (SL).tmTheme │ │ └── Cobalt (SL).tmTheme ├── editor.zsh └── install-manually.sh ├── bin ├── git-all ├── git-amend ├── git-undo ├── set-defaults ├── git-unpushed ├── headers ├── git-copy-branch-name ├── git-track ├── git-nuke ├── search ├── git-delete-local-merged ├── git-credit ├── git-unpushed-stat ├── dot ├── e ├── gitio ├── curltime ├── git-promote ├── movieme ├── git-up ├── cloudapp ├── mustacheme ├── res ├── known ├── git-rank-contributors └── git-wtf ├── mongodb └── aliases.zsh ├── ruby ├── path.zsh ├── rbenv.zsh ├── .pryrc ├── .gemrc ├── .rubocop.yml ├── install.sh ├── completion.zsh ├── aliases.zsh ├── .irbrc └── rails_g_and_open.rb ├── functions ├── gf ├── _c ├── _git-rm ├── _boom ├── c ├── extract └── _brew ├── python ├── path.zsh ├── pyenv.zsh └── install-manually.sh ├── docker └── aliases.zsh ├── hammerspoon ├── config │ ├── init.lua │ └── Spoons │ │ └── EjectMenu.spoon │ │ └── init.lua └── install.sh ├── silverfin └── aliases.zsh ├── .gitignore ├── system ├── keys.zsh ├── _path.zsh ├── grc.zsh └── aliases.zsh ├── xcode └── install-manually.sh ├── postgresql ├── aliases.zsh ├── install-manually.sh └── start.sh ├── tmux ├── install-manually.sh ├── aliases.zsh ├── .tmux │ └── visor.sh ├── run_in_all_naked_panes.zsh └── .tmux.conf ├── zsh ├── fpath.zsh ├── completion.zsh ├── aliases.zsh ├── window.zsh ├── .zshrc ├── config.zsh └── prompt.zsh ├── oh-my-zsh ├── install.sh └── oh-my-zsh.zsh ├── vim └── .vimrc ├── git ├── .gitignore ├── completion.zsh ├── aliases.zsh └── .gitconfig ├── install ├── dockup └── aliases.zsh ├── karabiner-elements ├── install.sh └── config │ └── assets │ └── complex_modifications │ └── 1536509707.json ├── bundle └── .bundle │ └── config ├── homebrew └── install.sh ├── LICENSE.md ├── osx └── set-defaults.sh ├── bootstrap └── README.md /sublime/User/Package Control.user-ca-bundle: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /sublime/editor.zsh: -------------------------------------------------------------------------------- 1 | export EDITOR="subl --wait" 2 | -------------------------------------------------------------------------------- /bin/git-all: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # 3 | # Stage all unstaged. 4 | 5 | git add -A 6 | -------------------------------------------------------------------------------- /mongodb/aliases.zsh: -------------------------------------------------------------------------------- 1 | alias mdb="mongod --config /usr/local/etc/mongod.conf" 2 | -------------------------------------------------------------------------------- /sublime/User/Markdown.sublime-settings: -------------------------------------------------------------------------------- 1 | { 2 | "enable_table_editor": true 3 | } 4 | -------------------------------------------------------------------------------- /ruby/path.zsh: -------------------------------------------------------------------------------- 1 | # Add Heroku toolbelt 2 | export PATH="/usr/local/heroku/bin:$PATH" 3 | -------------------------------------------------------------------------------- /sublime/User/JavaScript.sublime-settings: -------------------------------------------------------------------------------- 1 | { 2 | "extensions": 3 | [ 4 | ] 5 | } 6 | -------------------------------------------------------------------------------- /functions/gf: -------------------------------------------------------------------------------- 1 | gf() { 2 | local branch=$1 3 | git checkout -b $branch origin/$branch 4 | } -------------------------------------------------------------------------------- /sublime/User/Sass.sublime-settings: -------------------------------------------------------------------------------- 1 | { 2 | "extensions": 3 | [ 4 | "scss" 5 | ] 6 | } 7 | -------------------------------------------------------------------------------- /python/path.zsh: -------------------------------------------------------------------------------- 1 | # Add Python binaries 2 | export PATH="$HOME/Library/Python/2.7/bin:$PATH" 3 | -------------------------------------------------------------------------------- /sublime/User/Ruby Haml.sublime-settings: -------------------------------------------------------------------------------- 1 | { 2 | "extensions": 3 | [ 4 | "haml" 5 | ] 6 | } 7 | -------------------------------------------------------------------------------- /sublime/User/Ruby Slim.sublime-settings: -------------------------------------------------------------------------------- 1 | { 2 | "extensions": 3 | [ 4 | "emblem" 5 | ] 6 | } 7 | -------------------------------------------------------------------------------- /docker/aliases.zsh: -------------------------------------------------------------------------------- 1 | alias dockerclean="docker rm \$(docker ps -a -q); docker rmi \$(docker images -q)" 2 | -------------------------------------------------------------------------------- /sublime/User/HTML (Rails).sublime-settings: -------------------------------------------------------------------------------- 1 | { 2 | "extensions": 3 | [ 4 | "html.erb" 5 | ] 6 | } 7 | -------------------------------------------------------------------------------- /sublime/User/Python.sublime-settings: -------------------------------------------------------------------------------- 1 | { 2 | "extensions": 3 | [ 4 | "pyw", 5 | "py3" 6 | ] 7 | } 8 | -------------------------------------------------------------------------------- /sublime/User/JavaScript (Babel).sublime-settings: -------------------------------------------------------------------------------- 1 | { 2 | "extensions": 3 | [ 4 | "js", 5 | "jsx" 6 | ] 7 | } 8 | -------------------------------------------------------------------------------- /hammerspoon/config/init.lua: -------------------------------------------------------------------------------- 1 | hs.loadSpoon("EjectMenu") 2 | spoon.EjectMenu.show_in_menubar = true 3 | spoon.EjectMenu:start() -------------------------------------------------------------------------------- /ruby/rbenv.zsh: -------------------------------------------------------------------------------- 1 | # init according to man page 2 | if (( $+commands[rbenv] )) 3 | then 4 | eval "$(rbenv init -)" 5 | fi 6 | -------------------------------------------------------------------------------- /bin/git-amend: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # 3 | # Use the last commit message and amend your stuffs. 4 | 5 | git commit --amend -C HEAD 6 | -------------------------------------------------------------------------------- /bin/git-undo: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # 3 | # Undo your last commit, but don't throw away your changes 4 | 5 | git reset --soft HEAD^ 6 | -------------------------------------------------------------------------------- /silverfin/aliases.zsh: -------------------------------------------------------------------------------- 1 | alias sfc="cx run -i -s 'sf-prod-20171230' -e production --server kudu 'cd \$STACK_PATH; bin/rails c'" 2 | -------------------------------------------------------------------------------- /sublime/User/YAML.sublime-settings: -------------------------------------------------------------------------------- 1 | { 2 | "extensions": 3 | [ 4 | "yml.dist", 5 | "yml", 6 | ".gemrc" 7 | ] 8 | } 9 | -------------------------------------------------------------------------------- /sublime/User/Shell-Unix-Generic.sublime-settings: -------------------------------------------------------------------------------- 1 | { 2 | "extensions": 3 | [ 4 | "zsh", 5 | "bash", 6 | "sh" 7 | ] 8 | } 9 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | *.cache 2 | sublime/User/Package Control.last-run 3 | karabiner-elements/config/automatic_backups 4 | bundle/.bundle/cache 5 | -------------------------------------------------------------------------------- /functions/_c: -------------------------------------------------------------------------------- 1 | #compdef c 2 | _files -W $PROJECTS -/ 3 | _files -W $GOPATH/src/github.com -/ 4 | 5 | # See further documentation in `functions/c`. 6 | -------------------------------------------------------------------------------- /system/keys.zsh: -------------------------------------------------------------------------------- 1 | # Pipe my public key to my clipboard. 2 | alias pubkey="more ~/.ssh/id_rsa.pub | pbcopy | echo '=> Public key copied to pasteboard.'" 3 | -------------------------------------------------------------------------------- /bin/set-defaults: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # 3 | # Sets OS X defaults by running $DOTFILES_ROOT/osx/set-defaults.sh. 4 | 5 | exec $DOTFILES_ROOT/osx/set-defaults.sh 6 | -------------------------------------------------------------------------------- /sublime/User/PHP.sublime-settings: -------------------------------------------------------------------------------- 1 | { 2 | "extensions": 3 | [ 4 | "php4", 5 | "inc", 6 | "php5", 7 | "phtml", 8 | "php3" 9 | ] 10 | } 11 | -------------------------------------------------------------------------------- /sublime/User/XML.sublime-settings: -------------------------------------------------------------------------------- 1 | { 2 | "extensions": 3 | [ 4 | "xslt", 5 | "xsd", 6 | "xml.dist", 7 | "xml", 8 | "svg" 9 | ] 10 | } 11 | -------------------------------------------------------------------------------- /python/pyenv.zsh: -------------------------------------------------------------------------------- 1 | if which pyenv > /dev/null; then eval "$(pyenv init -)"; fi 2 | if which pyenv-virtualenv-init > /dev/null; then eval "$(pyenv virtualenv-init -)"; fi 3 | -------------------------------------------------------------------------------- /bin/git-unpushed: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # 3 | # Show the diff of everything you haven't pushed yet. 4 | 5 | branch=$(git rev-parse --abbrev-ref HEAD) 6 | git diff origin/$branch..HEAD 7 | -------------------------------------------------------------------------------- /sublime/User/Default.sublime-keymap: -------------------------------------------------------------------------------- 1 | [ 2 | {"keys": ["j", "k"], "command": "_enter_normal_mode", "args": {"mode": "mode_insert"}, "context": [{"key": "vi_insert_mode_aware"}] } 3 | ] -------------------------------------------------------------------------------- /sublime/User/JSON.sublime-settings: -------------------------------------------------------------------------------- 1 | { 2 | "extensions": 3 | [ 4 | ".jscsrc", 5 | ".csslintrc", 6 | ".jshintrc", 7 | ".bowerrc", 8 | ".eslintrc" 9 | ] 10 | } 11 | -------------------------------------------------------------------------------- /system/_path.zsh: -------------------------------------------------------------------------------- 1 | export PATH="./bin:/usr/local/bin:/usr/local/sbin:$DOTFILES_ROOT/bin:$PATH" 2 | export MANPATH="/usr/local/man:/usr/local/mysql/man:/usr/local/git/man:$MANPATH" 3 | -------------------------------------------------------------------------------- /system/grc.zsh: -------------------------------------------------------------------------------- 1 | # GRC colorizes nifty unix tools all over the place 2 | if (( $+commands[grc] )) && (( $+commands[brew] )) 3 | then 4 | source `brew --prefix`/etc/grc.bashrc 5 | fi 6 | -------------------------------------------------------------------------------- /xcode/install-manually.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # 3 | # This installs the Xcode command line tools, required to build 4 | # certain gems, libraries and executables. 5 | 6 | xcode-select --install 7 | -------------------------------------------------------------------------------- /bin/headers: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # 3 | # https://github.com/rtomayko/dotfiles/blob/rtomayko/bin/headers 4 | 5 | curl -sv "$@" 2>&1 >/dev/null | 6 | grep -v "^\*" | 7 | grep -v "^}" | 8 | cut -c3- -------------------------------------------------------------------------------- /hammerspoon/install.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | if [ -d "$HOME/.hammerspoon" ]; then 4 | mv ~/.hammerspoon ~/.hammerspoon-backup 5 | fi 6 | ln -s $DOTFILES_ROOT/hammerspoon/config ~/.hammerspoon 7 | -------------------------------------------------------------------------------- /postgresql/aliases.zsh: -------------------------------------------------------------------------------- 1 | alias runpg="dockup && $DOTFILES_ROOT/postgresql/start.sh && dockssh -N -L 5432:localhost:5432" 2 | alias postgres-local="postgres -D /Users/david/Library/homebrew/postgresql@14" -------------------------------------------------------------------------------- /postgresql/install-manually.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | if test ! $(which postgres) 4 | then 5 | echo " Installing postgresql for you." 6 | brew install postgresql > /tmp/postgresql-install.log 7 | fi 8 | -------------------------------------------------------------------------------- /tmux/install-manually.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | if test ! $(which tmux) 4 | then 5 | echo " Installing tmux for you." 6 | brew install tmux reattach-to-user-namespace > /tmp/tmux-install.log 7 | fi 8 | -------------------------------------------------------------------------------- /zsh/fpath.zsh: -------------------------------------------------------------------------------- 1 | #add each topic folder to fpath so that they can add functions and completion scripts 2 | for topic_folder ($DOTFILES_ROOT/*) if [ -d $topic_folder ]; then fpath=($topic_folder $fpath); fi; 3 | -------------------------------------------------------------------------------- /oh-my-zsh/install.sh: -------------------------------------------------------------------------------- 1 | if [ ! -d ~/.oh-my-zsh ]; then 2 | echo " Installing oh-my-zsh for you." 3 | 4 | sh -c "$(curl -fsSL https://raw.github.com/robbyrussell/oh-my-zsh/master/tools/install.sh)" 5 | fi 6 | -------------------------------------------------------------------------------- /bin/git-copy-branch-name: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # 3 | # Copy the current branch name to the clipboard. 4 | 5 | branch=$(git rev-parse --abbrev-ref HEAD) 6 | echo $branch 7 | echo $branch | tr -d '\n' | tr -d ' ' | pbcopy 8 | -------------------------------------------------------------------------------- /zsh/completion.zsh: -------------------------------------------------------------------------------- 1 | # matches case insensitive for lowercase 2 | zstyle ':completion:*' matcher-list 'm:{a-z}={A-Z}' 3 | 4 | # pasting with tabs doesn't perform completion 5 | zstyle ':completion:*' insert-tab pending 6 | -------------------------------------------------------------------------------- /bin/git-track: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # 3 | # Sets up your branch to track a remote branch. Assumes you mean 4 | # `origin/$branch-name`. 5 | 6 | branch=$(git rev-parse --abbrev-ref HEAD) 7 | git branch $branch --set-upstream-to origin/$branch -------------------------------------------------------------------------------- /python/install-manually.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | if test ! $(which pyenv) 4 | then 5 | echo " Installing pyenv for you." 6 | brew install pyenv > /tmp/pyenv-install.log 7 | fi 8 | 9 | brew install pyenv-virtualenv 10 | -------------------------------------------------------------------------------- /bin/git-nuke: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # 3 | # Nukes a branch locally and on the origin remote. 4 | # 5 | # $1 - Branch name. 6 | # 7 | # Examples 8 | # 9 | # git nuke add-git-nuke 10 | 11 | git branch -D $1 12 | git push origin :$1 13 | -------------------------------------------------------------------------------- /ruby/.pryrc: -------------------------------------------------------------------------------- 1 | if defined?(PryDebugger) 2 | Pry.commands.alias_command 'c', 'continue' 3 | Pry.commands.alias_command 's', 'step' 4 | Pry.commands.alias_command 'n', 'next' 5 | Pry.commands.alias_command 'f', 'finish' 6 | end 7 | -------------------------------------------------------------------------------- /tmux/aliases.zsh: -------------------------------------------------------------------------------- 1 | # Make commands with arguments work such as "subl /tmp" 2 | # Requires reattach-to-user-namespace under tmux 3 | alias subl="reattach-to-user-namespace /usr/local/bin/subl" 4 | alias tclear="run_in_all_naked_panes clear" 5 | -------------------------------------------------------------------------------- /zsh/aliases.zsh: -------------------------------------------------------------------------------- 1 | alias reload!='. ~/.zshrc' 2 | 3 | # List all dotfiles 4 | alias lhd="ls -ld .??*" 5 | 6 | # ls + grep 7 | alias lgrep="ls -lha | grep" 8 | 9 | # run rails console for dokku 10 | alias dkc="dokku run rails c" 11 | -------------------------------------------------------------------------------- /vim/.vimrc: -------------------------------------------------------------------------------- 1 | syntax on 2 | 3 | " Wrap gitcommit file types at the appropriate length 4 | filetype indent plugin on 5 | 6 | " Enable mouse 7 | if has("mouse") 8 | set mouse=a 9 | endif 10 | 11 | " Map 'jk' to exit mode 12 | :imap jk 13 | -------------------------------------------------------------------------------- /ruby/.gemrc: -------------------------------------------------------------------------------- 1 | --- 2 | :update_sources: true 3 | :verbose: true 4 | :backtrace: false 5 | :benchmark: false 6 | gem: --no-document --no-ri --no-rdoc --with-cppflags="-I/usr/local/opt/openssl/include" 7 | install: --with-cppflags=-I/usr/local/opt/openssl/include 8 | -------------------------------------------------------------------------------- /git/.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | *.orig 3 | *~ 4 | *.swp 5 | 6 | # Contain files with personal notes that shouldn't be added to the repository 7 | *.personal.md 8 | *.personal 9 | *.personal.rb 10 | 11 | # Ignore IntelliJ IDEA project files 12 | .idea/ 13 | -------------------------------------------------------------------------------- /bin/search: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # 3 | # Quick search in a directory for a string ($1). 4 | # 5 | set -e 6 | 7 | # use -iru to search directories ack usually ignores (like .git) 8 | if [ -x /usr/bin/ack-grep ]; then 9 | ack-grep -i $1 10 | else 11 | ack -i $1 12 | fi 13 | -------------------------------------------------------------------------------- /postgresql/start.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | CONTAINER_NAME="postgresql" 4 | 5 | if test ! $(docker ps -afq "name=postgresql") 6 | then 7 | docker run --name $CONTAINER_NAME -e POSTGRES_PASSWORD=postgres -p 5432 postgres 8 | else 9 | docker start $CONTAINER_NAME 10 | fi 11 | -------------------------------------------------------------------------------- /sublime/User/Ruby.sublime-settings: -------------------------------------------------------------------------------- 1 | { 2 | "detect_indentation": false, 3 | "extensions": 4 | [ 5 | "thor", 6 | "podspec", 7 | "simplecov", 8 | "jbuilder", 9 | "rb", 10 | "rake", 11 | "rabl" 12 | ], 13 | "tab_size": 2, 14 | "translate_tabs_to_spaces": true 15 | } 16 | -------------------------------------------------------------------------------- /ruby/.rubocop.yml: -------------------------------------------------------------------------------- 1 | Style/AccessModifierIndentation: 2 | EnforcedStyle: outdent 3 | SupportedStyles: 4 | - outdent 5 | - indent 6 | Style/Documentation: 7 | Enabled: false 8 | Metrics/LineLength: 9 | Max: 120 10 | Rails: 11 | Enabled: true 12 | Style/StringLiterals: 13 | Enabled: false 14 | -------------------------------------------------------------------------------- /bin/git-delete-local-merged: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # 3 | # Delete all local branches that have been merged into HEAD. Stolen from 4 | # our favorite @tekkub: 5 | # 6 | # https://plus.google.com/115587336092124934674/posts/dXsagsvLakJ 7 | 8 | git branch -d `git branch --merged | grep -v '^*' | grep -v 'master' | tr -d '\n'` 9 | -------------------------------------------------------------------------------- /system/aliases.zsh: -------------------------------------------------------------------------------- 1 | # grc overides for ls 2 | # Made possible through contributions from generous benefactors like 3 | # `brew install coreutils` 4 | if $(gls &>/dev/null) 5 | then 6 | alias ls="gls -F --color" 7 | alias l="gls -lAh --color" 8 | alias ll="gls -l --color" 9 | alias la='gls -A --color' 10 | fi -------------------------------------------------------------------------------- /functions/_git-rm: -------------------------------------------------------------------------------- 1 | #compdef git-rm 2 | _arguments -S -A '-*' \ 3 | '-f[override the up-to-date check]' \ 4 | "-n[don't actually remove the files, just show if they exist in the index]" \ 5 | '-r[allow recursive removal when a leading directory-name is given]' \ 6 | '--cached[only remove files from the index]' && ret=0 7 | _files 8 | -------------------------------------------------------------------------------- /bin/git-credit: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # 3 | # A very slightly quicker way to credit an author on the latest commit. 4 | # 5 | # $1 - The full name of the author. 6 | # $2 - The email address of the author. 7 | # 8 | # Examples 9 | # 10 | # git credit "Zach Holman" zach@example.com 11 | # 12 | 13 | git commit --amend --author "$1 <$2>" -C HEAD 14 | -------------------------------------------------------------------------------- /git/completion.zsh: -------------------------------------------------------------------------------- 1 | # Uses git's autocompletion for inner commands. Assumes an install of git's 2 | # bash `git-completion` script at $completion below (this is where Homebrew 3 | # tosses it, at least). 4 | completion='$(brew --prefix)/share/zsh/site-functions/_git' 5 | 6 | if test -f $completion 7 | then 8 | source $completion 9 | fi 10 | -------------------------------------------------------------------------------- /install: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | # 3 | # Run all install.sh files. Current dir is set to `dotfiles/` 4 | 5 | set -e 6 | 7 | cd "$(dirname $0)" 8 | export DOTFILES_ROOT=$(pwd) 9 | 10 | set -e 11 | 12 | # find the installers and run them iteratively 13 | find . -name install.sh | while read installer ; do sh -c "${installer}" ; done 14 | -------------------------------------------------------------------------------- /dockup/aliases.zsh: -------------------------------------------------------------------------------- 1 | alias dockup="source ~/scripts/docker-vagrant-parallels/up.sh" 2 | alias dockdown="~/scripts/docker-vagrant-parallels/down.sh" 3 | alias dockhalt="~/scripts/docker-vagrant-parallels/halt.sh" 4 | alias dockssh="~/scripts/docker-vagrant-parallels/ssh.sh" 5 | alias dockrun="docker-compose run --rm --service-ports web" 6 | alias dockbe="dockrun bundle exec" 7 | -------------------------------------------------------------------------------- /bin/git-unpushed-stat: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # 3 | # Show the diffstat of everything you haven't pushed yet. 4 | 5 | branch=$(git rev-parse --abbrev-ref HEAD) 6 | count=$(git rev-list --count HEAD origin/$branch...HEAD) 7 | 8 | if [ "$count" -eq "1" ] 9 | then 10 | s='' 11 | else 12 | s='s' 13 | fi 14 | 15 | git diff --stat origin/$branch..HEAD 16 | echo " $count commit$s total" 17 | -------------------------------------------------------------------------------- /ruby/install.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | if test ! $(which rbenv) 4 | then 5 | echo " Installing rbenv for you." 6 | brew install rbenv > /tmp/rbenv-install.log 7 | fi 8 | 9 | if test ! $(which ruby-build) 10 | then 11 | echo " Installing ruby-build for you." 12 | brew install ruby-build > /tmp/ruby-build-install.log 13 | fi 14 | 15 | # Install for when you need mimemagic gem 16 | brew install shared-mime-info -------------------------------------------------------------------------------- /bin/dot: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # 3 | # dot 4 | # 5 | # `dot` handles installation, updates, things like that. Run it periodically 6 | # to make sure you're on the latest and greatest. 7 | export DOTFILES_ROOT=$HOME/poetry/dotfiles 8 | 9 | # Set OS X defaults 10 | $DOTFILES_ROOT/osx/set-defaults.sh 11 | 12 | # Upgrade homebrew 13 | brew update 14 | 15 | # Install homebrew packages 16 | $DOTFILES_ROOT/homebrew/install.sh 2>&1 17 | -------------------------------------------------------------------------------- /sublime/User/SassBeautify.sublime-settings: -------------------------------------------------------------------------------- 1 | { 2 | "indent": 2, 3 | "dasherize": false, 4 | "old": false, 5 | "path": false, 6 | "beautifyOnSave": false, 7 | "inlineComments": false, 8 | "newlineBetweenSelectors": false, 9 | "path": "./bin:/usr/local/bin:/usr/local/sbin:/Users/david/poetry/dotfiles/bin:/Users/david/.rbenv/shims:/usr/local/heroku/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/texbin" 10 | } 11 | -------------------------------------------------------------------------------- /karabiner-elements/install.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | rm -rf ~/.config/karabiner 4 | ln -s $DOTFILES_ROOT/karabiner-elements/config ~/.config/karabiner 5 | 6 | # if ! brew cask ls --versions karabiner-elements 2>/dev/null >/dev/null 7 | # then 8 | # echo " Installing karabiner-elements for you." 9 | # brew cask install karabiner-elements > /tmp/karabiner-elements-install.log 10 | # fi 11 | 12 | launchctl kickstart -k gui/`id -u`/org.pqrs.karabiner.karabiner_console_user_server 13 | -------------------------------------------------------------------------------- /bin/e: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # 3 | # Quick shortcut to an editor. 4 | # 5 | # This means that as I travel back and forth between editors, hey, I don't have 6 | # to re-learn any arcane commands. Neat. 7 | # 8 | # USAGE: 9 | # 10 | # $ e 11 | # # => opens the current directory in your editor 12 | # 13 | # $ e . 14 | # $ e /usr/local 15 | # # => opens the specified directory in your editor 16 | 17 | if [ "$1" = "" ] ; then 18 | exec $EDITOR . 19 | else 20 | exec $EDITOR "$1" 21 | fi 22 | -------------------------------------------------------------------------------- /ruby/completion.zsh: -------------------------------------------------------------------------------- 1 | # Stolen from 2 | # https://github.com/sstephenson/rbenv/blob/master/completions/rbenv.zsh 3 | 4 | if [[ ! -o interactive ]]; then 5 | return 6 | fi 7 | 8 | compctl -K _rbenv rbenv 9 | 10 | _rbenv() { 11 | local word words completions 12 | read -cA words 13 | word="${words[2]}" 14 | 15 | if [ "${#words}" -eq 2 ]; then 16 | completions="$(rbenv commands)" 17 | else 18 | completions="$(rbenv completions "${word}")" 19 | fi 20 | 21 | reply=("${(ps:\n:)completions}") 22 | } -------------------------------------------------------------------------------- /zsh/window.zsh: -------------------------------------------------------------------------------- 1 | # From http://dotfiles.org/~_why/.zshrc 2 | # Sets the window title nicely no matter where you are 3 | function title() { 4 | # escape '%' chars in $1, make nonprintables visible 5 | a=${(V)1//\%/\%\%} 6 | 7 | # Truncate command, and join lines. 8 | a=$(print -Pn "%40>...>$a" | tr -d "\n") 9 | 10 | case $TERM in 11 | screen) 12 | print -Pn "\ek$a:$3\e\\" # screen title (in ^A") 13 | ;; 14 | xterm*|rxvt) 15 | print -Pn "\e]2;$2\a" # plain xterm title ($3 for pwd) 16 | ;; 17 | esac 18 | } 19 | 20 | -------------------------------------------------------------------------------- /bundle/.bundle/config: -------------------------------------------------------------------------------- 1 | --- 2 | BUNDLE_BUILD__EVENTMACHINE: "--with-cppflags=-I/usr/local/opt/openssl/include" 3 | BUNDLE_BUILD__PUMA: "--with-cppflags=-I/usr/local/opt/openssl/include --with-ldflags=-L/usr/local/opt/openssl/lib" 4 | BUNDLE_BUILD__LIBV8: "--with-system-v8" 5 | BUNDLE_GEM__TEST: "rspec" 6 | BUNDLE_GEM__MIT: "true" 7 | BUNDLE_GEM__COC: "false" 8 | BUNDLE_GITHUB__HTTPS: "true" 9 | BUNDLE_BUILD__SASSC: "--disable-march-tune-native" # https://stackoverflow.com/questions/66456656/error-installing-sassc-clang-compiler-does-not-support-march-native-m1 10 | -------------------------------------------------------------------------------- /sublime/install-manually.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # Setup a machine for Sublime Text 3 3 | set -x 4 | 5 | # Install `subl` command line tool 6 | ln -s "/Applications/Sublime Text.app/Contents/SharedSupport/bin/subl" /usr/local/bin/subl 7 | 8 | # Symlink settings 9 | mv ~/Library/Application\ Support/Sublime\ Text\ 3/Packages/User ~/Library/Application\ Support/Sublime\ Text\ 3/Packages/User.backup 10 | ln -s $DOTFILES_ROOT/sublime/User ~/Library/Application\ Support/Sublime\ Text\ 3/Packages/User 11 | 12 | echo " Linked Sublime settings. Make sure to have Package Control installed." 13 | -------------------------------------------------------------------------------- /sublime/User/Package Control.sublime-settings: -------------------------------------------------------------------------------- 1 | { 2 | "bootstrapped": true, 3 | "in_process_packages": 4 | [ 5 | ], 6 | "installed_packages": 7 | [ 8 | "ApplySyntax", 9 | "Babel", 10 | "Better CoffeeScript", 11 | "BracketHighlighter", 12 | "eco", 13 | "EJS", 14 | "LESS", 15 | "Markdown Extended", 16 | "Package Control", 17 | "RailsGoToSpec", 18 | "Ruby Markers", 19 | "Ruby Slim", 20 | "Sass", 21 | "SassBeautify", 22 | "SublimeLinter", 23 | "SublimeLinter-contrib-scss-lint", 24 | "SublimeLinter-rubocop", 25 | "SublimeLinter-ruby", 26 | "Table Editor", 27 | "Theme - SoDaReloaded" 28 | ] 29 | } 30 | -------------------------------------------------------------------------------- /bin/gitio: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | # Usage: gitio URL [CODE] 3 | # 4 | # Turns a github.com URL 5 | # into a git.io URL 6 | # 7 | # Created by @defunkt: 8 | # https://gist.github.com/1209316 9 | # 10 | # Copies the git.io URL to your clipboard. 11 | 12 | url = ARGV[0] 13 | code = ARGV[1] 14 | 15 | if url !~ /^(https?:\/\/)?(gist\.)?github.com/ 16 | abort "* github.com URLs only" 17 | end 18 | 19 | if url !~ /^http/ 20 | url = "https://#{url}" 21 | end 22 | 23 | if code 24 | code = "-F code=#{code}" 25 | end 26 | 27 | output = `curl -i http://git.io -F 'url=#{url}' #{code} 2> /dev/null` 28 | if output =~ /Location: (.+)\n?/ 29 | puts $1 30 | `echo #$1 | pbcopy` 31 | else 32 | puts output 33 | end 34 | -------------------------------------------------------------------------------- /tmux/.tmux/visor.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/tmux source-file 2 | 3 | # Start three horizontally split panes. Useful for new sessions in TotalTerminal. 4 | # To use in TotalTerminal, edit the Visor Terminal.app profile, and set the command to: 5 | # 6 | # /usr/local/bin/tmux start-server; source-file /Users/david/.tmux/visor.sh 7 | # 8 | # Uncheck "Run inside shell" for faster bootup 9 | 10 | # Start new session detached 11 | new-session -d 12 | 13 | split-window -t 0 -h # split first pane into two 14 | split-window -t 1 -h # split second pane into two 15 | select-pane -t 0 # select first pane 16 | select-layout even-horizontal # even out 17 | 18 | # Attach to new session 19 | attach 20 | 21 | -------------------------------------------------------------------------------- /functions/_boom: -------------------------------------------------------------------------------- 1 | #compdef boom 2 | 3 | local state line cmds ret=1 4 | 5 | _arguments -C '1: :->cmds' '*: :->args' 6 | 7 | case $state in 8 | cmds) 9 | local -a cmds 10 | cmds=( 11 | 'all:show all items in all lists' 12 | 'edit:edit the boom JSON file in $EDITOR' 13 | 'help:help text' 14 | ) 15 | _describe -t commands 'boom command' cmds && ret=0 16 | _values 'lists' $(boom | awk '{print $1}') 17 | ;; 18 | args) 19 | case $line[1] in 20 | (boom|all|edit|help) 21 | ;; 22 | *) 23 | _values 'items' `boom $line[1] | awk '{print $1}' | sed -e 's/://'` 2>/dev/null && ret=0 24 | ;; 25 | esac 26 | ;; 27 | esac 28 | 29 | return ret 30 | -------------------------------------------------------------------------------- /functions/c: -------------------------------------------------------------------------------- 1 | #!/bin/zsh 2 | # 3 | # This lets you quickly jump into a project directory. 4 | # 5 | # Type: 6 | # 7 | # c 8 | # 9 | # ...to autocomplete on all of your projects in the directories specified in 10 | # `functions/_c`. Typically I'm using it like: 11 | # 12 | # c holm/bo 13 | # 14 | # ...to quickly jump into holman/boom, for example. 15 | # 16 | # This also accounts for how Go structures its projects. For example, it will 17 | # autocomplete both on $PROJECTS, and also assume you want to autocomplete on 18 | # your Go projects in $GOPATH/src. 19 | 20 | if [ ! -z "$1" ] && [ -s "$GOPATH/src/github.com/$1" ]; then 21 | cd "$GOPATH/src/github.com/$1" 22 | else 23 | cd "$PROJECTS/$1" 24 | fi 25 | -------------------------------------------------------------------------------- /bin/curltime: -------------------------------------------------------------------------------- 1 | #!/bin/zsh 2 | # From https://stackoverflow.com/questions/18215389/how-do-i-measure-request-and-response-times-at-once-using-curl 3 | # - Use read to output heredoc stream into the $OutputFormat variable 4 | # - Add "IFS=" to not remove leading and trailing whitespace 5 | IFS= read -d '' OutputFormat <<"EOF" 6 | time_namelookup: %{time_namelookup}s 7 | time_connect: %{time_connect}s 8 | time_appconnect: %{time_appconnect}s 9 | time_pretransfer: %{time_pretransfer}s 10 | time_redirect: %{time_redirect}s 11 | time_starttransfer: %{time_starttransfer}s 12 | ----------- 13 | time_total: %{time_total}s 14 | 15 | 16 | EOF 17 | 18 | curl -w $OutputFormat -o /dev/null -s "$1" 19 | -------------------------------------------------------------------------------- /ruby/aliases.zsh: -------------------------------------------------------------------------------- 1 | alias sc='script/console' 2 | alias sg='script/generate' 3 | alias sd='script/destroy' 4 | 5 | # Be. Excited. Be! Be! Excited! 6 | alias be="bundle exec" 7 | 8 | # Grep rails routes 9 | alias rgrep="bundle exec rake routes | grep" 10 | 11 | # Run migrate, rollback, and migrate again. This is a good test 12 | # to check if the migration works in both directions. Thanks Bikeshed.fm! 13 | alias remigrate="bundle exec rake db:migrate && bundle exec rake db:rollback && bundle exec rake db:migrate" 14 | alias migrate="bundle exec rails db:migrate" 15 | 16 | # Open all generated files in Sublime 17 | alias rg="$DOTFILES_ROOT/ruby/rails_g_and_open.rb" 18 | 19 | # Start foreman using Procfile.personal 20 | alias pfore="foreman start -f Procfile.personal" 21 | -------------------------------------------------------------------------------- /bin/git-promote: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # 3 | # Promotes a local topic branch to a remote tracking branch of the same name, 4 | # by pushing and then setting up the git config 5 | # 6 | # Thanks to ENTP: 7 | # http://hoth.entp.com/2008/11/10/improving-my-git-workflow 8 | 9 | curr_branch=$(git symbolic-ref -q HEAD | sed -e 's|^refs/heads/||') 10 | 11 | remote_branch=$(git branch -r | grep "origin/${curr_branch}") 12 | [ -z "${remote_branch}" ] && ( git push origin "${curr_branch}" ) 13 | 14 | origin=$(git config --get "branch.${curr_branch}.remote") 15 | [ -z "${origin}" ] && ( git config --add "branch.${curr_branch}.remote" origin ) 16 | 17 | merge=$(git config --get "branch.${curr_branch}.merge") 18 | [ -z "${merge}" ] && ( git config --add "branch.${curr_branch}.merge" "refs/heads/${curr_branch}" ) -------------------------------------------------------------------------------- /sublime/User/ApplySyntax.ext-list: -------------------------------------------------------------------------------- 1 | { 2 | "HTML (Rails)": 3 | [ 4 | "html.erb" 5 | ], 6 | "JSON": 7 | [ 8 | ".bowerrc", 9 | ".csslintrc", 10 | ".eslintrc", 11 | ".jscsrc", 12 | ".jshintrc" 13 | ], 14 | "PHP": 15 | [ 16 | "inc", 17 | "php3", 18 | "php4", 19 | "php5", 20 | "phtml" 21 | ], 22 | "Python": 23 | [ 24 | "py3", 25 | "pyw" 26 | ], 27 | "Ruby": 28 | [ 29 | "jbuilder", 30 | "podspec", 31 | "rabl", 32 | "rake", 33 | "rb", 34 | "simplecov", 35 | "thor" 36 | ], 37 | "Ruby Haml": 38 | [ 39 | "haml" 40 | ], 41 | "Ruby Slim": 42 | [ 43 | "emblem" 44 | ], 45 | "Shell-Unix-Generic": 46 | [ 47 | "bash", 48 | "sh", 49 | "zsh" 50 | ], 51 | "XML": 52 | [ 53 | "xml.dist" 54 | ], 55 | "YAML": 56 | [ 57 | ".gemrc", 58 | "yml", 59 | "yml.dist" 60 | ] 61 | } 62 | -------------------------------------------------------------------------------- /homebrew/install.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # 3 | # Homebrew 4 | # 5 | # This installs some of the common dependencies needed (or at least desired) 6 | # using Homebrew. 7 | 8 | # Check for Homebrew 9 | if test ! $(which brew) 10 | then 11 | echo " Installing Homebrew for you." 12 | ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" 13 | fi 14 | 15 | # Install homebrew packages 16 | brew install grc coreutils spark openssl 17 | 18 | # Development utils 19 | brew install pup httpie jq moreutils 20 | brew install graphicsmagick 21 | 22 | # For nokogiri gem 23 | brew install libiconv libxml2 libxslt 24 | brew link --force libxml2 25 | 26 | # Install patched ansible 27 | for filename in $(find -H "$DOTFILES_ROOT/homebrew/formulae" -name '*.rb' ) 28 | do 29 | brew install file://$filename 30 | done 31 | 32 | exit 0 33 | -------------------------------------------------------------------------------- /sublime/User/Preferences.sublime-settings: -------------------------------------------------------------------------------- 1 | { 2 | "color_scheme": "Packages/User/SublimeLinter/Monokai (SL).tmTheme", 3 | "ensure_newline_at_eof_on_save": true, 4 | "font_size": 10, 5 | "ignored_packages": 6 | [ 7 | "Vintage" 8 | ], 9 | "tab_size": 2, 10 | "theme": "SoDaReloaded Dark.sublime-theme", 11 | "translate_tabs_to_spaces": true, 12 | "trim_trailing_white_space_on_save": true, 13 | "vintageous_reset_mode_when_switching_tabs": false, 14 | 15 | // These files will still show up in the side bar, but won't be included in 16 | // Goto Anything or Find in Files 17 | "binary_file_patterns": [ 18 | // Defaults 19 | "*.jpg", "*.jpeg", "*.png", "*.gif", "*.ttf", "*.tga", "*.dds", "*.ico", "*.eot", "*.pdf", "*.swf", "*.jar", "*.zip", 20 | 21 | // Custom additions 22 | "node_modules/", "tmp/", "*.js.map", "vendor/bin/" 23 | ] 24 | } 25 | -------------------------------------------------------------------------------- /git/aliases.zsh: -------------------------------------------------------------------------------- 1 | # Use `hub` as our git wrapper: 2 | # http://defunkt.github.com/hub/ 3 | hub_path=$(which hub) 4 | if (( $+commands[hub] )) 5 | then 6 | alias git=$hub_path 7 | fi 8 | 9 | # The rest of my fun git aliases 10 | alias gl='git pull --prune' 11 | alias glog="git log --graph --pretty=format:'%Cred%h%Creset %an: %s - %Creset %C(yellow)%d%Creset %Cgreen(%cr)%Creset' --abbrev-commit --date=relative" 12 | alias gp='git push origin HEAD' 13 | alias gd='git diff' 14 | alias gc='git commit' 15 | alias gca='git commit -a' 16 | alias gco='git checkout' 17 | alias gcb='git copy-branch-name' 18 | alias gb='git branch' 19 | alias gs='git status -sb' # upgrade your git if -sb breaks for you. it's fun. 20 | alias rebase='git fetch && git rebase origin/master' 21 | 22 | # Run rubocop on all files that are changed versus master, thanks @mrfoto 23 | alias lazycop='git diff-tree -r --no-commit-id --name-only master HEAD | xargs rubocop' 24 | -------------------------------------------------------------------------------- /sublime/User/ApplySyntax.sublime-settings: -------------------------------------------------------------------------------- 1 | 2 | { 3 | // If you want exceptions reraised so you can see them in the console, change this to true. 4 | "reraise_exceptions": false, 5 | 6 | // If you want to have a syntax applied when new files are created, set new_file_syntax to the name of the syntax to use. 7 | // The format is exactly the same as "syntax" in the rules below. For example, if you want to have a new file use 8 | // JavaScript syntax, set new_file_syntax to 'JavaScript'. 9 | "new_file_syntax": false, 10 | 11 | // Auto add extensions to language settings file in User folder. 12 | // Do not manually remove "apply_syntax_extensions" from the settings file. 13 | // "extenstions" are ignored by "match": "all" setting. 14 | "add_exts_to_lang_settings": true, 15 | 16 | // Control level of logging in the console. 17 | // (true|false|"verbose") 18 | "debug": true, 19 | 20 | // Put your custom syntax rules here: 21 | "syntaxes": [ 22 | ] 23 | } 24 | -------------------------------------------------------------------------------- /bin/movieme: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # 3 | # MOVIE ME as in: "MOVIE ME AN ANIMATED GIF FROM THIS MOVIE, DAMMIT" 4 | # 5 | # Creates an animated gif from a movie file. Uploads to CloudApp. You must also 6 | # have `gifme` and `cloudapp` in your $PATH. 7 | # 8 | # $1 - the path to the movie we're converting. 9 | # $2 - the start time of the finished product. 10 | # This can be in seconds, or it also accepts the "hh:mm:ss[.xxx]" format. 11 | # $3 - the duration of the video sequence. 12 | # This can be in seconds, or it also accepts the "hh:mm:ss[.xxx]" format. 13 | # 14 | # Examples: 15 | # 16 | # movieme 17 | # ~/Desktop/dr-strangelove.mp4 23:12 3 18 | # ~/Desktop/holman-backflip-on-fire.mov 3.9 1.75 19 | 20 | # cleanup 21 | rm -rf /tmp/movieme 22 | 23 | # create tmp dir 24 | mkdir -p /tmp/movieme 25 | 26 | # split the movie into constituent frames 27 | ffmpeg -i $1 -f image2 -vf "scale=iw*sar:ih" -ss $2 -t $3 -r 7 /tmp/movieme/d-%05d.png 28 | 29 | # ANIMATE 30 | gifme /tmp/movieme/* -d 0 31 | -------------------------------------------------------------------------------- /ruby/.irbrc: -------------------------------------------------------------------------------- 1 | #!/usr/bin/ruby 2 | require 'irb/completion' 3 | require 'irb/ext/save-history' 4 | require 'rubygems' 5 | 6 | IRB.conf[:SAVE_HISTORY] = 1000 7 | IRB.conf[:HISTORY_FILE] = "#{ENV['HOME']}/.irb_history" 8 | 9 | IRB.conf[:PROMPT_MODE] = :SIMPLE 10 | 11 | IRB.conf[:AUTO_INDENT] = true 12 | 13 | IRB.conf[:BACK_TRACE_LIMIT]=6 14 | 15 | class Object 16 | # list methods which aren't in superclass 17 | def local_methods(obj = self) 18 | (obj.methods - obj.class.superclass.instance_methods).sort 19 | end 20 | 21 | # print documentation 22 | # 23 | # ri 'Array#pop' 24 | # Array.ri 25 | # Array.ri :pop 26 | # arr.ri :pop 27 | def ri(method = nil) 28 | unless method && method =~ /^[A-Z]/ # if class isn't specified 29 | klass = self.kind_of?(Class) ? name : self.class.name 30 | method = [klass, method].compact.join('#') 31 | end 32 | puts `ri '#{method}'` 33 | end 34 | end 35 | 36 | def me 37 | User.find_by_login(ENV['USER'].strip) 38 | end 39 | 40 | def r 41 | reload! 42 | end 43 | -------------------------------------------------------------------------------- /ruby/rails_g_and_open.rb: -------------------------------------------------------------------------------- 1 | #!/usr/bin/ruby 2 | 3 | require 'pty' 4 | 5 | def extract_created_files(lines) 6 | created_items = lines.map do |line| 7 | command, file = colorless(line).split 8 | file if command == "create" 9 | end.compact 10 | 11 | created_files = 12 | created_items.reject { |file| File.directory?(file) } 13 | 14 | created_files.reverse 15 | end 16 | 17 | def colorless(str) 18 | str.gsub /\033\[\d+m/, "" 19 | end 20 | 21 | command = "rails generate #{$*.join(" ")}" 22 | lines = [] 23 | 24 | # Use PTY to force Thor to output coloured text 25 | PTY.spawn(command) do |r, w, pid| 26 | begin 27 | while line = r.readline 28 | puts line 29 | lines << line 30 | end 31 | rescue EOFError 32 | # noop 33 | end 34 | end 35 | 36 | files = extract_created_files(lines) 37 | 38 | if files.any? 39 | puts "\nOpening files #{files.join(", ")}..." 40 | # exec("'/Applications/Sublime Text 2.app/Contents/SharedSupport/bin/subl' #{files.join(" ")}") 41 | exec("subl #{files.join(" ")}") 42 | end 43 | -------------------------------------------------------------------------------- /bin/git-up: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # 3 | # Usage: git-up 4 | # git-reup 5 | # 6 | # Like git-pull but show a short and sexy log of changes 7 | # immediately after merging (git-up) or rebasing (git-reup). 8 | # 9 | # Inspired by Kyle Neath's `git up' alias: 10 | # http://gist.github.com/249223 11 | # 12 | # Stolen from Ryan Tomayko 13 | # http://github.com/rtomayko/dotfiles/blob/rtomayko/bin/git-up 14 | 15 | set -e 16 | 17 | PULL_ARGS="$@" 18 | 19 | # when invoked as git-reup, run as `git pull --rebase' 20 | test "$(basename $0)" = "git-reup" && 21 | PULL_ARGS="--rebase $PULL_ARGS" 22 | 23 | git pull $PULL_ARGS 24 | 25 | # show diffstat of all changes if we're pulling with --rebase. not 26 | # sure why git-pull only does this when merging. 27 | test "$(basename $0)" = "git-reup" && { 28 | echo "Diff:" 29 | git --no-pager diff --color --stat HEAD@{1}.. | 30 | sed 's/^/ /' 31 | } 32 | 33 | # show an abbreviated commit log of stuff that was just merged. 34 | echo "Log:" 35 | git log --color --pretty=oneline --abbrev-commit HEAD@{1}.. | 36 | sed 's/^/ /' 37 | -------------------------------------------------------------------------------- /zsh/.zshrc: -------------------------------------------------------------------------------- 1 | # your project folder that we can `c [tab]` to 2 | export PROJECTS=~/poetry 3 | 4 | # shortcut to this dotfiles path is $DOTFILES_ROOT 5 | export DOTFILES_ROOT=$PROJECTS/dotfiles 6 | 7 | 8 | # Stash your environment variables in ~/.localrc. This means they'll stay out 9 | # of your main dotfiles repository (which may be public, like this one), but 10 | # you'll have access to them in your scripts. 11 | if [[ -a ~/.localrc ]] 12 | then 13 | source ~/.localrc 14 | fi 15 | 16 | # all of our zsh files 17 | typeset -U config_files 18 | config_files=($DOTFILES_ROOT/**/*.zsh) 19 | 20 | # load the path files 21 | for file in ${(M)config_files:#*/path.zsh} 22 | do 23 | source $file 24 | done 25 | 26 | # load everything but the path and completion files 27 | for file in ${${config_files:#*/path.zsh}:#*/completion.zsh} 28 | do 29 | source $file 30 | done 31 | 32 | # initialize autocomplete here, otherwise functions won't be loaded 33 | autoload -Uz compinit 34 | compinit 35 | 36 | # load every completion after autocomplete loads 37 | for file in ${(M)config_files:#*/completion.zsh} 38 | do 39 | source $file 40 | done 41 | 42 | unset config_files 43 | -------------------------------------------------------------------------------- /LICENSE.md: -------------------------------------------------------------------------------- 1 | The MIT License 2 | 3 | Copyright (c) Zach Holman, http://zachholman.com 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in 13 | all copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 21 | THE SOFTWARE. 22 | -------------------------------------------------------------------------------- /functions/extract: -------------------------------------------------------------------------------- 1 | # credit: http://nparikh.org/notes/zshrc.txt 2 | # Usage: extract 3 | # Description: extracts archived files / mounts disk images 4 | # Note: .dmg/hdiutil is Mac OS X-specific. 5 | extract () { 6 | if [ -f $1 ]; then 7 | case $1 in 8 | *.tar.bz2) tar -jxvf $1 ;; 9 | *.tar.gz) tar -zxvf $1 ;; 10 | *.bz2) bunzip2 $1 ;; 11 | *.dmg) hdiutil mount $1 ;; 12 | *.gz) gunzip $1 ;; 13 | *.tar) tar -xvf $1 ;; 14 | *.tbz2) tar -jxvf $1 ;; 15 | *.tgz) tar -zxvf $1 ;; 16 | *.zip) unzip $1 ;; 17 | *.ZIP) unzip $1 ;; 18 | *.pax) cat $1 | pax -r ;; 19 | *.pax.Z) uncompress $1 --stdout | pax -r ;; 20 | *.Z) uncompress $1 ;; 21 | *) echo "'$1' cannot be extracted/mounted via extract()" ;; 22 | esac 23 | else 24 | echo "'$1' is not a valid file" 25 | fi 26 | } 27 | 28 | -------------------------------------------------------------------------------- /git/.gitconfig: -------------------------------------------------------------------------------- 1 | [hub] 2 | protocol = https 3 | 4 | [user] 5 | name = David Verhasselt 6 | email = david@crowdway.com 7 | 8 | [credential] 9 | helper = osxkeychain 10 | 11 | [alias] 12 | lg = log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit 13 | co = checkout 14 | promote = !$DOTFILES_ROOT/bin/git-promote 15 | wtf = !$DOTFILES_ROOT/bin/git-wtf 16 | rank-contributors = !$DOTFILES_ROOT/bin/git-rank-contributors 17 | count = !git shortlog -sn 18 | 19 | [push] 20 | default = simple 21 | 22 | [filter "media"] 23 | clean = git-media-clean %f 24 | smudge = git-media-smudge %f 25 | 26 | [core] 27 | excludesfile = ~/.gitignore 28 | editor = vim 29 | 30 | [mergetool] 31 | keepBackup = true 32 | 33 | [difftool "Kaleidoscope"] 34 | [difftool] 35 | [diff] 36 | tool = Kaleidoscope 37 | 38 | [mergetool "Kaleidoscope"] 39 | trustexitcode = true 40 | 41 | [merge] 42 | tool = Kaleidoscope 43 | 44 | [mergetool "Kaleidoscope"] 45 | cmd = ksdiff --merge --output \"$MERGED\" --base \"$BASE\" -- \"$LOCAL\" --snapshot \"$REMOTE\" --snapshot 46 | [difftool "Kaleidoscope"] 47 | cmd = ksdiff --partial-changeset --relative-path \"$MERGED\" -- \"$LOCAL\" \"$REMOTE\" 48 | 49 | [difftool] 50 | prompt = false 51 | 52 | [mergetool] 53 | prompt = false 54 | [rerere] 55 | enabled = true 56 | [rebase] 57 | autoStash = true 58 | -------------------------------------------------------------------------------- /bin/cloudapp: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | # 3 | # cloudapp 4 | # Zach Holman / @holman 5 | # 6 | # Uploads a file from the command line to CloudApp, drops it into your 7 | # clipboard (on a Mac, at least). 8 | # 9 | # Example: 10 | # 11 | # cloudapp drunk-blake.png 12 | # 13 | # This requires Aaron Russell's cloudapp_api gem: 14 | # 15 | # gem install cloudapp_api 16 | # 17 | # Requires you set your CloudApp credentials in ~/.cloudapp as a simple file of: 18 | # 19 | # email 20 | # password 21 | 22 | require 'rubygems' 23 | 24 | ['json', 'cloudapp_api'].each do |gem| 25 | begin 26 | require gem 27 | rescue LoadError 28 | puts "You need to install #{gem}: gem install #{gem}" 29 | exit!(1) 30 | end 31 | end 32 | 33 | config_file = "#{ENV['HOME']}/.cloudapp" 34 | unless File.exist?(config_file) 35 | puts "You need to type your email and password (one per line) into "+ 36 | "`~/.cloudapp`" 37 | exit!(1) 38 | end 39 | 40 | email,password = File.read(config_file).split("\n") 41 | 42 | if ARGV[0].nil? 43 | puts "You need to specify a file to upload." 44 | exit!(1) 45 | end 46 | 47 | urls = [] 48 | ARGV.each do |x| 49 | CloudApp.authenticate(email,password) 50 | puts "Attempting to upload #{x}" 51 | url = CloudApp::Item.create(:upload, {:file => x}).url 52 | 53 | # Say it for good measure. 54 | puts "Uploaded #{x} to #{url}" 55 | 56 | # Get the embed link. 57 | url = "#{url}/#{ARGV[0].split('/').last}" 58 | urls << url 59 | end 60 | 61 | # Copy it to your (Mac's) clipboard. 62 | `echo '#{urls.join(',')}' | tr -d "\n" | pbcopy` 63 | -------------------------------------------------------------------------------- /tmux/run_in_all_naked_panes.zsh: -------------------------------------------------------------------------------- 1 | #!/bin/zsh 2 | 3 | # Runs the specified command (provided by the first argument) in all tmux panes. 4 | # 5 | # - Checks if a shell is running in the pane 6 | # - Checks if in that shell, another process is not already running 7 | # 8 | # Does not run the command if another command is already running. 9 | # 10 | # Usage: 11 | # 12 | # run_in_all_naked_panes clear 13 | # 14 | # Recommended: 15 | # 16 | # alias tclear="run_in_all_naked_panes clear" 17 | # 18 | 19 | function run_in_all_naked_panes { 20 | 21 | # Checks if a process is already running in the shell 22 | # first arg is pane ID, second arg is PID, third arg is command 23 | function run_if_naked_shell { 24 | 25 | # Returns PID of a child process, or empty if none 26 | if [[ -z $(pgrep -P $2) ]] 27 | then 28 | tmux send-keys -t $1 " $3" C-m # C-m is carriage return 29 | fi 30 | 31 | } 32 | 33 | # Assign the argument to something readable 34 | command=$1 35 | 36 | # If we're in a Tmux pane 37 | if [[ -n $TMUX_PANE ]] 38 | then 39 | # Note which pane we were originally at 40 | original_pane=$(tmux display-message -p '#P') 41 | 42 | # Run in this pane too 43 | $command 44 | fi 45 | 46 | # Loop through the panes that are in the window 47 | tmux list-panes -F '#{pane_index}:#{pane_pid}' | while IFS=':' read pane pid; do 48 | # Don't run the command in the current pane if we are in a Tmux pane, 49 | # because we would've run the command already above. 50 | if [[ $original_pane != $pane ]]; then 51 | run_if_naked_shell $pane $pid $command 52 | fi 53 | done 54 | 55 | } 56 | -------------------------------------------------------------------------------- /bin/mustacheme: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # 3 | # mustacheme 4 | # expanded from an idea from Rick Olson (@technoweenie) 5 | # 6 | # Takes a .gif, splits it into constituent frames, mustaches each, restitches 7 | # the gif, and uploads to cloudapp. 8 | # 9 | # This leverages the nifty service mustachify.me, which will analyze your photo, 10 | # identify faces, and add a mustache to your image. 11 | # 12 | # If the .gif is a remote file, we'll download it and blow it up locally. 13 | # 14 | # $1 - the path of the gif 15 | # 16 | # Examples: 17 | # 18 | # mustacheme holman-jumping-off-cliff-into-butter.gif 19 | # mustacheme http://github.com/holman/butter/blob/master/holman-butter.gif 20 | # 21 | # Dependencies: 22 | # 23 | # - ImageMagick. If you're on a Mac, run: 24 | # brew install imagemagick 25 | # - wget 26 | # - cloudapp: https://github.com/holman/dotfiles/blob/master/bin/cloudapp 27 | # - gifme: https://github.com/holman/gifme 28 | 29 | set -e 30 | 31 | # Set up mustacheme temporary working directory 32 | output=/tmp/mustacheme 33 | rm -rf $output 34 | mkdir $output 35 | 36 | if [[ $1 == http* ]] 37 | then 38 | wget $1 -O /tmp/mustache-download.gif 39 | file=/tmp/mustache-download.gif 40 | else 41 | file="$1" 42 | fi 43 | 44 | # Blow apart the GIF 45 | convert $1 -coalesce $output/frame_%03d.gif 46 | 47 | # Mustache each frame 48 | for frame in $output/*.gif 49 | do 50 | url=$(cloudapp $frame | grep Uploaded | awk '{print substr($0, index($0, "http://"))}') 51 | url="$url/$(basename $frame)" 52 | wget "http://mustachify.me/?src=$url" -O "$frame-stache" 53 | done 54 | 55 | # Ding! Fries are done. 56 | gifme $output/*-stache -d 0 57 | -------------------------------------------------------------------------------- /zsh/config.zsh: -------------------------------------------------------------------------------- 1 | if [[ -n $SSH_CONNECTION ]]; then 2 | export PS1='%m:%3~$(git_info_for_prompt)%# ' 3 | else 4 | export PS1='%3~$(git_info_for_prompt)%# ' 5 | fi 6 | 7 | export LSCOLORS="exfxcxdxbxegedabagacad" 8 | export CLICOLOR=true 9 | 10 | # UTF-8 all the things! 11 | export LC_ALL="en_US.UTF-8" 12 | export LANG="en_US.UTF-8" 13 | export LANGUAGE="en_US.UTF-8" 14 | 15 | 16 | fpath=($DOTFILES_ROOT/functions $fpath) 17 | 18 | autoload -U $DOTFILES_ROOT/functions/*(:t) 19 | 20 | HISTFILE=~/.zsh_history 21 | HISTSIZE=10000 22 | SAVEHIST=10000 23 | 24 | setopt NO_BG_NICE # don't nice background tasks 25 | setopt NO_HUP 26 | setopt NO_BEEP # no beep ever 27 | setopt NO_LIST_BEEP 28 | setopt LOCAL_OPTIONS # allow functions to have local options 29 | setopt LOCAL_TRAPS # allow functions to have local traps 30 | setopt HIST_VERIFY 31 | setopt SHARE_HISTORY # share history between sessions ??? 32 | setopt EXTENDED_HISTORY # add timestamps to history 33 | setopt PROMPT_SUBST 34 | setopt CORRECT 35 | setopt COMPLETE_IN_WORD 36 | setopt AUTOCD # go into directory without typing cd 37 | 38 | setopt APPEND_HISTORY # adds history 39 | setopt INC_APPEND_HISTORY SHARE_HISTORY # adds history incrementally and share it across sessions 40 | setopt HIST_IGNORE_ALL_DUPS # don't record dupes in history 41 | setopt HIST_REDUCE_BLANKS 42 | setopt HIST_IGNORE_SPACE # Ignore cmmands beginning with space 43 | 44 | # don't expand aliases _before_ completion has finished 45 | # like: git comm-[tab] 46 | setopt complete_aliases 47 | 48 | zle -N newtab 49 | 50 | bindkey '^[^[[D' backward-word 51 | bindkey '^[^[[C' forward-word 52 | bindkey '^[[5D' beginning-of-line 53 | bindkey '^[[5C' end-of-line 54 | bindkey '^[[3~' delete-char 55 | bindkey '^[^N' newtab 56 | bindkey '^?' backward-delete-char 57 | -------------------------------------------------------------------------------- /sublime/User/SublimeLinter.sublime-settings: -------------------------------------------------------------------------------- 1 | { 2 | "user": { 3 | "debug": false, 4 | "delay": 0.25, 5 | "error_color": "D02000", 6 | "gutter_theme": "Packages/SublimeLinter/gutter-themes/Default/Default.gutter-theme", 7 | "gutter_theme_excludes": [], 8 | "lint_mode": "background", 9 | "linters": { 10 | "rubocop": { 11 | "@disable": false, 12 | "args": [], 13 | "excludes": [] 14 | }, 15 | "ruby": { 16 | "@disable": false, 17 | "args": [], 18 | "excludes": [] 19 | }, 20 | "scss": { 21 | "@disable": false, 22 | "args": [], 23 | "exclude-linter": "", 24 | "excludes": [], 25 | "include-linter": "" 26 | } 27 | }, 28 | "mark_style": "solid underline", 29 | "no_column_highlights_line": true, 30 | "passive_warnings": false, 31 | "paths": { 32 | "linux": [], 33 | "osx": [], 34 | "windows": [] 35 | }, 36 | "python_paths": { 37 | "linux": [], 38 | "osx": [], 39 | "windows": [] 40 | }, 41 | "rc_search_limit": 3, 42 | "shell_timeout": 10, 43 | "show_errors_on_save": false, 44 | "show_marks_in_minimap": true, 45 | "syntax_map": { 46 | "html (django)": "html", 47 | "html (rails)": "html", 48 | "html 5": "html", 49 | "javascript (babel)": "javascript", 50 | "php": "html", 51 | "python django": "python" 52 | }, 53 | "warning_color": "DDB700", 54 | "wrap_find": true 55 | } 56 | } -------------------------------------------------------------------------------- /functions/_brew: -------------------------------------------------------------------------------- 1 | #compdef brew 2 | 3 | # Brew ZSH completion function 4 | # Drop this somewhere in your $fpath (like /usr/share/zsh/site-functions) 5 | # and rename it _brew 6 | # 7 | # altered from _fink 8 | 9 | _brew_all_formulae() { 10 | formulae=(`brew search`) 11 | } 12 | 13 | _brew_installed_formulae() { 14 | installed_formulae=(`brew list`) 15 | } 16 | 17 | local -a _1st_arguments 18 | _1st_arguments=( 19 | 'install:install a formula' 20 | 'remove:remove a formula' 21 | 'search:search for a formula (/regex/ or string)' 22 | 'list:list files in a formula or not-installed formulae' 23 | 'link:link a formula' 24 | 'unlink:unlink a formula' 25 | 'home:visit the homepage of a formula or the brew project' 26 | 'info:information about a formula' 27 | 'prune:remove dead links' 28 | 'update:freshen up links' 29 | 'log:git commit log for a formula' 30 | 'create:create a new formula' 31 | 'edit:edit a formula' 32 | ) 33 | 34 | local expl 35 | local -a formula installed_formulae 36 | 37 | _arguments \ 38 | '(-v --verbose)'{-v,--verbose}'[verbose]' \ 39 | '(--version)--version[version information]' \ 40 | '(--prefix)--prefix[where brew lives on this system]' \ 41 | '(--cache)--cache[brew cache]' \ 42 | '*:: :->subcmds' && return 0 43 | 44 | if (( CURRENT == 1 )); then 45 | _describe -t commands "brew subcommand" _1st_arguments 46 | return 47 | fi 48 | 49 | case "$words[1]" in 50 | list) 51 | _arguments \ 52 | '(--unbrewed)--unbrewed[files in brew --prefix not controlled by brew]' \ 53 | '1: :->forms' && return 0 54 | 55 | if [[ "$state" == forms ]]; then 56 | _brew_installed_formulae 57 | _requested installed_formulae expl 'installed formulae' compadd -a installed_formulae 58 | fi ;; 59 | install|home|log|info) 60 | _brew_all_formulae 61 | _wanted formulae expl 'all formulae' compadd -a formulae ;; 62 | remove|edit|xo) 63 | _brew_installed_formulae 64 | _wanted installed_formulae expl 'installed formulae' compadd -a installed_formulae ;; 65 | esac 66 | -------------------------------------------------------------------------------- /tmux/.tmux.conf: -------------------------------------------------------------------------------- 1 | # Set Tmux prefix to CTRL+S 2 | unbind C-b 3 | set -g prefix C-s 4 | 5 | # Vim keys in COPY and CHOICE mode 6 | set-window-option -g mode-keys vi 7 | 8 | # Use emacs in tmux status bar 9 | set-option -g status-keys "emacs" 10 | 11 | # Key bindings to navigate panes without prefix (Vim directional) 12 | bind-key -n C-h select-pane -L 13 | bind-key -n C-j select-pane -D 14 | bind-key -n C-k select-pane -U 15 | bind-key -n C-l select-pane -R 16 | 17 | # Fancy colours 18 | set-option -g default-terminal "screen-256color" 19 | 20 | # Set color of tmux status bar 21 | set -g status-bg '#666666' 22 | set -g status-fg '#aaaaaa' 23 | 24 | # Allow 50 chars in left status 25 | set -g status-left-length 50 26 | 27 | # Show current pane in right status 28 | set-option -g status-right "pane:#P" 29 | 30 | # - (dash) splits pane vertical 31 | # | (pipe) splits pane horizontal 32 | bind-key - split-window -v -c '#{pane_current_path}' 33 | bind-key \ split-window -h -c '#{pane_current_path}' 34 | 35 | # If run as "tmux attach", create a session if one does not already exist 36 | new-session -n $HOST 37 | 38 | # Lower escape timing from 500ms to 50ms for quicker response to scroll-buffer access. 39 | set -s escape-time 50 40 | 41 | # Mouse support for scrolling 42 | # -> Install EasySIMBL and MouseTerm to support Terminal.app 43 | 44 | ## Mouse support in Tmux HEAD 45 | set-option -g -q mouse on 46 | 47 | ### Start copy mode when scrolling up 48 | bind -n WheelUpPane if-shell -F -t = "#{mouse_any_flag}" "send-keys -M" "if -Ft= '#{pane_in_mode}' 'send-keys -M' 'copy-mode -e; send-keys -M'" 49 | 50 | ## Mouse support in Tmux 1.9 < x < 2.1 51 | set -g mode-mouse on 52 | set -g mouse-resize-pane on 53 | set -g mouse-select-pane on 54 | set -g mouse-select-window on 55 | 56 | # Synchronize panes 57 | bind-key a set-window-option synchronize-panes 58 | 59 | # Install reattach-to-user-namespace to make pbcopy, sublime open file work in tmux 60 | set-option -g default-command "reattach-to-user-namespace -l zsh" 61 | 62 | # Reload config 63 | bind r source-file ${HOME}/.tmux.conf \; display-message "Config reloaded." 64 | -------------------------------------------------------------------------------- /oh-my-zsh/oh-my-zsh.zsh: -------------------------------------------------------------------------------- 1 | # Path to your oh-my-zsh installation. 2 | export ZSH=~/.oh-my-zsh 3 | 4 | # Set name of the theme to load. 5 | # Look in ~/.oh-my-zsh/themes/ 6 | # Optionally, if you set this to "random", it'll load a random theme each 7 | # time that oh-my-zsh is loaded. 8 | ZSH_THEME="robbyrussell" 9 | 10 | # Uncomment the following line to use case-sensitive completion. 11 | # CASE_SENSITIVE="true" 12 | 13 | # Uncomment the following line to disable bi-weekly auto-update checks. 14 | # DISABLE_AUTO_UPDATE="true" 15 | 16 | # Uncomment the following line to change how often to auto-update (in days). 17 | # export UPDATE_ZSH_DAYS=13 18 | 19 | # Uncomment the following line to disable colors in ls. 20 | # DISABLE_LS_COLORS="true" 21 | 22 | # Uncomment the following line to disable auto-setting terminal title. 23 | # DISABLE_AUTO_TITLE="true" 24 | 25 | # Uncomment the following line to enable command auto-correction. 26 | # ENABLE_CORRECTION="true" 27 | 28 | # Uncomment the following line to display red dots whilst waiting for completion. 29 | # COMPLETION_WAITING_DOTS="true" 30 | 31 | # Uncomment the following line if you want to disable marking untracked files 32 | # under VCS as dirty. This makes repository status check for large repositories 33 | # much, much faster. 34 | # DISABLE_UNTRACKED_FILES_DIRTY="true" 35 | 36 | # Uncomment the following line if you want to change the command execution time 37 | # stamp shown in the history command output. 38 | # The optional three formats: "mm/dd/yyyy"|"dd.mm.yyyy"|"yyyy-mm-dd" 39 | # HIST_STAMPS="mm/dd/yyyy" 40 | 41 | # Would you like to use another custom folder than $ZSH/custom? 42 | # ZSH_CUSTOM=/path/to/new-custom-folder 43 | 44 | # Which plugins would you like to load? (plugins can be found in ~/.oh-my-zsh/plugins/*) 45 | # Custom plugins may be added to ~/.oh-my-zsh/custom/plugins/ 46 | # Example format: plugins=(rails git textmate ruby lighthouse) 47 | # Add wisely, as too many plugins slow down shell startup. 48 | plugins=(gitfast brew dircycle gem osx) 49 | 50 | source $ZSH/oh-my-zsh.sh 51 | 52 | # Compilation flags 53 | # export ARCHFLAGS="-arch x86_64" 54 | 55 | # ssh 56 | # export SSH_KEY_PATH="~/.ssh/dsa_id" 57 | -------------------------------------------------------------------------------- /zsh/prompt.zsh: -------------------------------------------------------------------------------- 1 | autoload colors && colors 2 | # cheers, @ehrenmurdick 3 | # http://github.com/ehrenmurdick/config/blob/master/zsh/prompt.zsh 4 | 5 | if (( $+commands[git] )) 6 | then 7 | git="$commands[git]" 8 | else 9 | git="/usr/bin/git" 10 | fi 11 | 12 | git_branch() { 13 | echo $($git symbolic-ref HEAD 2>/dev/null | awk -F/ {'print $NF'}) 14 | } 15 | 16 | git_dirty() { 17 | if $(! $git status -s &> /dev/null) 18 | then 19 | echo "" 20 | else 21 | if [[ $($git status --porcelain) == "" ]] 22 | then 23 | echo "on %{$fg_bold[green]%}$(git_prompt_info)%{$reset_color%}" 24 | else 25 | echo "on %{$fg_bold[red]%}$(git_prompt_info)%{$reset_color%}" 26 | fi 27 | fi 28 | } 29 | 30 | git_prompt_info () { 31 | ref=$($git symbolic-ref HEAD 2>/dev/null) || return 32 | # echo "(%{\e[0;33m%}${ref#refs/heads/}%{\e[0m%})" 33 | echo "${ref#refs/heads/}" 34 | } 35 | 36 | unpushed () { 37 | $git cherry -v @{upstream} 2>/dev/null 38 | } 39 | 40 | need_push () { 41 | if [[ $(unpushed) == "" ]] 42 | then 43 | echo " " 44 | else 45 | echo " with %{$fg_bold[magenta]%}unpushed%{$reset_color%} " 46 | fi 47 | } 48 | 49 | autoload local_ruby_version global_ruby_version 50 | 51 | local_ruby_version() { 52 | if (( $+commands[rbenv] )) 53 | then 54 | echo "$(rbenv version | awk '{print $1}')" 55 | fi 56 | } 57 | 58 | global_ruby_version() { 59 | if (( $+commands[rbenv] )) 60 | then 61 | echo "$(rbenv global | awk '{print $1}')" 62 | fi 63 | } 64 | 65 | rb_prompt() { 66 | local_version=$(local_ruby_version) 67 | 68 | if [[ -n $local_version ]] 69 | then 70 | if [[ $local_version == $(global_ruby_version) ]] 71 | then 72 | echo "%{$FG[107]%}$local_version%{$reset_color%} " 73 | else 74 | echo "%{$FG[118]%}$local_version%{$reset_color%} " 75 | fi 76 | else 77 | echo "" 78 | fi 79 | } 80 | 81 | directory_name() { 82 | echo "%{$fg_bold[cyan]%}%~%{$reset_color%}" 83 | } 84 | 85 | export PROMPT=$'in $(directory_name) $(git_dirty)$(need_push)\n› ' 86 | export RPROMPT=$'$(rb_prompt)' 87 | 88 | # Gets run at every prompt 89 | precmd() { 90 | title "zsh" "%m" "%55<...<%~" # See zsh/window.zsh 91 | } 92 | -------------------------------------------------------------------------------- /bin/res: -------------------------------------------------------------------------------- 1 | #!/usr/bin/osascript 2 | # 3 | # A small command line script to change screen resolutions on Mountain Lion. 4 | # 5 | # Primarily I switch between two resolutions on my Retina MacBook Pro: Retina, 6 | # and the full resolution setting. This means for particular apps I use, I can 7 | # quickly jump between seeing more pixels and less. 8 | # 9 | # There doesn't appear to be an easy way to do this without just using 10 | # AppleScript to automate clicking buttons, so that's what this does. 11 | # 12 | # Most of this script is adapted from this helpful answer: 13 | # 14 | # http://apple.stackexchange.com/a/91590 15 | # 16 | # Make sure "Enable access for assistive devices" is checked in the 17 | # Accessibility section of System Properties. 18 | 19 | local index1, index2 20 | 21 | set index1 to 3 -- 1440 x 900 (Best for Retina) 22 | set index2 to 5 -- 1920 x 1200 (More Space) 23 | 24 | tell application "System Preferences" 25 | activate 26 | set the current pane to pane id "com.apple.preference.displays" 27 | reveal anchor "displaysDisplayTab" of pane id "com.apple.preference.displays" 28 | end tell 29 | 30 | local indexToUse 31 | 32 | tell application "System Events" 33 | tell window "Built-in Retina Display" of application process "System Preferences" of application "System Events" 34 | -- Click the "Scaled" radio button 35 | click radio button "Scaled" of radio group 1 of tab group 1 36 | 37 | tell tab group 1 38 | tell radio group 1 of group 1 39 | -- Depending on what scale option/index is current selected, set the appropriate new option/index to use 40 | if (value of radio button index1) is true then 41 | set indexToUse to index2 42 | else if (value of radio button index2) is true then 43 | set indexToUse to index1 44 | end if 45 | 46 | -- Click the radio button for the new scale option/index 47 | click radio button indexToUse 48 | end tell 49 | end tell 50 | 51 | -- If option/index 1 is selected a warning prompt is displayed, click the OK button to dismiss the prompt 52 | if indexToUse = 1 then 53 | click button "OK" of sheet 1 54 | end if 55 | end tell 56 | end tell 57 | 58 | tell application "System Preferences" 59 | quit 60 | end tell 61 | -------------------------------------------------------------------------------- /bin/known: -------------------------------------------------------------------------------- 1 | #!/bin/zsh 2 | # 3 | # Removes the offending key from `known_hosts` after trying unsuccessfully to sign in 4 | # through ssh. 5 | # 6 | # Use as follows: 7 | 8 | # › ssh sandcrawler.crowdway.com 9 | # 10 | # @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ 11 | # @ WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED! @ 12 | # @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ 13 | # IT IS POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY! 14 | # Someone could be eavesdropping on you right now (man-in-the-middle attack)! 15 | # It is also possible that a host key has just been changed. 16 | # The fingerprint for the ECDSA key sent by the remote host is 17 | # SHA256:+9nZWr9tcMA6TRckj+w6t9FWoK9/CtdamWZhzg98h+8. 18 | # Please contact your system administrator. 19 | # Add correct host key in /Users/david/.ssh/known_hosts to get rid of this message. 20 | # Offending ECDSA key in /Users/david/.ssh/known_hosts:34 21 | # ECDSA host key for sandcrawler.crowdway.com has changed and you have requested strict checking. 22 | # Host key verification failed. 23 | 24 | # › known 25 | # Removing sandcrawler.crowdway.com from known_hosts 26 | 27 | # # Host sandcrawler.crowdway.com found: line 34 28 | # /Users/david/.ssh/known_hosts updated. 29 | # Original contents retained as /Users/david/.ssh/known_hosts.old 30 | 31 | # › ssh sandcrawler.crowdway.com 32 | # The authenticity of host 'sandcrawler.crowdway.com (176.9.19.183)' can't be established. 33 | # ECDSA key fingerprint is SHA256:+9nZWr9tcMA6TRckj+w6t9FWoK9/CtdamWZhzg98h+8. 34 | # Are you sure you want to continue connecting (yes/no)? 35 | 36 | # Helpful q about fc 37 | # https://superuser.com/questions/527299/how-to-call-history-fc-from-a-zsh-script 38 | export HISTFILE=~/.zsh_history 39 | fc -R 40 | previous_command="$(fc -ln | tail -n2 | head -n1)" 41 | 42 | # Run previous_command in shell, and output stderr to stdin so we can capture it easily 43 | previous_output=$(eval ${previous_command} 2>&1) 44 | 45 | # Use `tr` to replace newlines with another character - sed only works on a line by line basis 46 | # Use -E (extended regex) to avoid having to escape parenthesis 47 | untrusted_hostname=$(echo $previous_output | tr '\n' '\r' | sed -E 's/.*host key for (.+) has changed.*/\1/') 48 | 49 | echo "Removing $untrusted_hostname from known_hosts" 50 | echo 51 | ssh-keygen -R $untrusted_hostname 52 | -------------------------------------------------------------------------------- /bin/git-rank-contributors: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | 3 | ## git-rank-contributors: a simple script to trace through the logs and 4 | ## rank contributors by the total size of the diffs they're responsible for. 5 | ## A change counts twice as much as a plain addition or deletion. 6 | ## 7 | ## Output may or may not be suitable for inclusion in a CREDITS file. 8 | ## Probably not without some editing, because people often commit from more 9 | ## than one address. 10 | ## 11 | ## git-rank-contributors Copyright 2008 William Morgan . 12 | ## This program is free software: you can redistribute it and/or modify 13 | ## it under the terms of the GNU General Public License as published by 14 | ## the Free Software Foundation, either version 3 of the License, or (at 15 | ## your option) any later version. 16 | ## 17 | ## This program is distributed in the hope that it will be useful, 18 | ## but WITHOUT ANY WARRANTY; without even the implied warranty of 19 | ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 20 | ## GNU General Public License for more details. 21 | ## 22 | ## You can find the GNU General Public License at: 23 | ## http://www.gnu.org/licenses/ 24 | 25 | class String 26 | def obfuscate; gsub(/@/, " at the ").gsub(/\.(\w+)(>|$)/, ' dot \1s\2') end 27 | def htmlize; gsub("&", "&").gsub("<", "<").gsub(">", ">") end 28 | # Fix for invalid encodings http://stackoverflow.com/a/24037885 29 | def clean 30 | if RUBY_VERSION >= "2.1" 31 | scrub 32 | elsif RUBY_VERSION >= "1.9" 33 | encode("UTF-16be", :invalid => :replace).encode("UTF-8") 34 | else 35 | self 36 | end 37 | end 38 | end 39 | 40 | lines = {} 41 | verbose = ARGV.delete("-v") 42 | obfuscate = ARGV.delete("-o") 43 | htmlize = ARGV.delete("-h") 44 | 45 | author = nil 46 | state = :pre_author 47 | `git log -M -C -C -p --no-color`.clean.split("\n").each do |l| 48 | case 49 | when (state == :pre_author || state == :post_author) && l =~ /Author: (.*)$/ 50 | author = $1 51 | state = :post_author 52 | lines[author] ||= 0 53 | when state == :post_author && l =~ /^\+\+\+/ 54 | state = :in_diff 55 | when state == :in_diff && l =~ /^[\+\-]/ 56 | lines[author] += 1 57 | when state == :in_diff && l =~ /^commit / 58 | state = :pre_author 59 | end 60 | end 61 | 62 | lines.sort_by { |a, c| -c }.each do |a, c| 63 | a = a.obfuscate if obfuscate 64 | a = a.htmlize if htmlize 65 | if verbose 66 | puts "#{a}: #{c} lines of diff" 67 | else 68 | puts a 69 | end 70 | end 71 | -------------------------------------------------------------------------------- /karabiner-elements/config/assets/complex_modifications/1536509707.json: -------------------------------------------------------------------------------- 1 | { 2 | "title": "Finder", 3 | "rules": [ 4 | { 5 | "description": "Use Return as Open", 6 | "manipulators": [ 7 | { 8 | "type": "basic", 9 | "from": { 10 | "key_code": "return_or_enter", 11 | "modifiers": { 12 | "optional": ["any"] 13 | } 14 | }, 15 | "to": [ 16 | { 17 | "key_code": "o", 18 | "modifiers": ["right_command"] 19 | } 20 | ], 21 | "conditions": [ 22 | { 23 | "type": "frontmost_application_if", 24 | "bundle_identifiers": [ 25 | "^com.apple.finder" 26 | ] 27 | } 28 | ] 29 | } 30 | ] 31 | }, 32 | { 33 | "description": "Use Return as Open and Use Fn+Return as Rename", 34 | "manipulators": [ 35 | { 36 | "type": "basic", 37 | "from": { 38 | "key_code": "return_or_enter", 39 | "modifiers": { 40 | "mandatory": [ 41 | "fn" 42 | ] 43 | } 44 | }, 45 | "to": [ 46 | { 47 | "key_code": "return_or_enter" 48 | } 49 | ], 50 | "conditions": [ 51 | { 52 | "type": "frontmost_application_if", 53 | "bundle_identifiers": [ 54 | "^com.apple.finder" 55 | ] 56 | } 57 | ] 58 | }, 59 | { 60 | "type": "basic", 61 | "from": { 62 | "key_code": "return_or_enter" 63 | }, 64 | "to": [ 65 | { 66 | "key_code": "o", 67 | "modifiers": ["right_command"] 68 | } 69 | ], 70 | "conditions": [ 71 | { 72 | "type": "frontmost_application_if", 73 | "bundle_identifiers": [ 74 | "^com.apple.finder" 75 | ] 76 | } 77 | ] 78 | } 79 | ] 80 | }, 81 | { 82 | "description": "Use Delete as Move to Trash", 83 | "manipulators": [ 84 | { 85 | "type": "basic", 86 | "from": { 87 | "key_code": "delete_forward", 88 | "modifiers": { 89 | "optional": ["any"] 90 | } 91 | }, 92 | "to": [ 93 | { 94 | "key_code": "delete_or_backspace", 95 | "modifiers": ["left_command"] 96 | } 97 | ], 98 | "conditions": [ 99 | { 100 | "type": "frontmost_application_if", 101 | "bundle_identifiers": [ 102 | "^com.apple.finder" 103 | ] 104 | } 105 | ] 106 | } 107 | ] 108 | } 109 | ] 110 | } 111 | -------------------------------------------------------------------------------- /osx/set-defaults.sh: -------------------------------------------------------------------------------- 1 | # Sets reasonable OS X defaults. 2 | # 3 | # Or, in other words, set shit how I like in OS X. 4 | # 5 | # The original idea (and a couple settings) were grabbed from: 6 | # https://github.com/mathiasbynens/dotfiles/blob/master/.osx 7 | # 8 | # Run ./set-defaults.sh and you'll be good to go. 9 | # 10 | # A nice GUI to check settings can be found here: 11 | # http://apps.tempel.org/PrefsEditor 12 | # 13 | 14 | # Enable press-and-hold for keys, removing key repeat, for 15 | # easy accented characters. 16 | # defaults write -g ApplePressAndHoldEnabled -bool true # Was already the case 17 | 18 | # Use AirDrop over every interface. srsly this should be a default. 19 | defaults write com.apple.NetworkBrowser BrowseAllInterfaces 1 20 | 21 | # Always open everything in Finder's list view. This is important. 22 | defaults write com.apple.Finder FXPreferredViewStyle Nlsv 23 | 24 | # Show the ~/Library folder. 25 | chflags nohidden ~/Library 26 | 27 | # Set a really fast key repeat. 28 | defaults write NSGlobalDomain KeyRepeat -int 1 29 | 30 | # Set the Finder prefs for showing a few different volumes on the Desktop. 31 | defaults write com.apple.finder ShowExternalHardDrivesOnDesktop -bool true 32 | defaults write com.apple.finder ShowRemovableMediaOnDesktop -bool true 33 | 34 | # Hide Safari's bookmark bar. 35 | defaults write com.apple.Safari ShowFavoritesBar -bool false 36 | 37 | # Set up Safari for development. 38 | defaults write com.apple.Safari IncludeInternalDebugMenu -bool true 39 | defaults write com.apple.Safari IncludeDevelopMenu -bool true 40 | defaults write com.apple.Safari WebKitDeveloperExtrasEnabledPreferenceKey -bool true 41 | defaults write com.apple.Safari "com.apple.Safari.ContentPageGroupIdentifier.WebKit2DeveloperExtrasEnabled" -bool true 42 | defaults write NSGlobalDomain WebKitDeveloperExtras -bool true 43 | 44 | # Make CMD-V paste without formatting 45 | # defaults write NSGlobalDomain NSUserKeyEquivalents -dict "Paste and Match Style" -string "@v" 46 | defaults write NSGlobalDomain NSUserKeyEquivalents -dict "Paste" -string "@v" 47 | 48 | # Disable the crash reporter 49 | defaults write com.apple.CrashReporter DialogType -string "none" 50 | 51 | # Restart automatically if the computer freezes 52 | sudo systemsetup -setrestartfreeze on 53 | 54 | # Make CMD-F in Finder to start "Find by filename" 55 | defaults write com.apple.finder NSUserKeyEquivalents -dict "Find by Name..." -string "@f" 56 | 57 | # Make new windows in Finder start up to my home path 58 | defaults write com.apple.finder NewWindowTarget -string "PfHm" 59 | defaults write com.apple.finder NewWindowTargetPath -string "file:///Users/david/" 60 | 61 | # Autohide Dock 62 | defaults write com.apple.dock autohide -bool true 63 | 64 | # Remove Dock hide/show delay 65 | defaults write com.apple.dock autohide-delay -float 0 66 | 67 | # Shorten Dock hide/show animation 68 | defaults write com.apple.dock autohide-time-modifier -float 0.2 69 | 70 | # Restart Dock 71 | killall Dock 72 | 73 | # Map caps-lock to ctrl (needs restart) 74 | ## Handled by Karabiner so disabled here 75 | # defaults -currentHost write -g com.apple.keyboard.modifiermapping.alt_handler_id-50 -array "HIDKeyboardModifierMappingDst2HIDKeyboardModifierMappingSrc0" 76 | 77 | echo " Set up OSX settings. Some settings might need a restart to take effect." 78 | -------------------------------------------------------------------------------- /bootstrap: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | # 3 | # bootstrap installs things. 4 | 5 | cd "$(dirname "$0")" 6 | DOTFILES_ROOT=$(pwd) 7 | 8 | set -e 9 | 10 | echo '' 11 | 12 | info () { 13 | printf " [ \033[00;34m..\033[0m ] $1" 14 | } 15 | 16 | user () { 17 | printf "\r [ \033[0;33m?\033[0m ] $1 " 18 | } 19 | 20 | success () { 21 | printf "\r\033[2K [ \033[00;32mOK\033[0m ] $1\n" 22 | } 23 | 24 | fail () { 25 | printf "\r\033[2K [\033[0;31mFAIL\033[0m] $1\n" 26 | echo '' 27 | exit 28 | } 29 | 30 | link_file () { 31 | local src=$1 dst=$2 32 | 33 | local overwrite= backup= skip= 34 | local action= 35 | 36 | if [ -f "$dst" -o -d "$dst" -o -L "$dst" ] 37 | then 38 | 39 | if [ "$overwrite_all" == "false" ] && [ "$backup_all" == "false" ] && [ "$skip_all" == "false" ] 40 | then 41 | 42 | local currentSrc="$(readlink $dst)" 43 | 44 | if [ "$currentSrc" == "$src" ] 45 | then 46 | 47 | skip=true; 48 | 49 | else 50 | 51 | user "File already exists: $dst ($(basename "$src")), what do you want to do?\n\ 52 | [s]kip, [S]kip all, [o]verwrite, [O]verwrite all, [b]ackup, [B]ackup all?" 53 | read -n 1 action 54 | 55 | case "$action" in 56 | o ) 57 | overwrite=true;; 58 | O ) 59 | overwrite_all=true;; 60 | b ) 61 | backup=true;; 62 | B ) 63 | backup_all=true;; 64 | s ) 65 | skip=true;; 66 | S ) 67 | skip_all=true;; 68 | * ) 69 | ;; 70 | esac 71 | 72 | fi 73 | 74 | fi 75 | 76 | overwrite=${overwrite:-$overwrite_all} 77 | backup=${backup:-$backup_all} 78 | skip=${skip:-$skip_all} 79 | 80 | if [ "$overwrite" == "true" ] 81 | then 82 | rm -rf "$dst" 83 | success "removed $dst" 84 | fi 85 | 86 | if [ "$backup" == "true" ] 87 | then 88 | mv "$dst" "${dst}.backup" 89 | success "moved $dst to ${dst}.backup" 90 | fi 91 | 92 | if [ "$skip" == "true" ] 93 | then 94 | success "skipped $src" 95 | fi 96 | fi 97 | 98 | if [ "$skip" != "true" ] # "false" or empty 99 | then 100 | ln -s "$1" "$2" 101 | success "linked $1 to $2" 102 | fi 103 | } 104 | 105 | # Symlink all files starting with "." or ending with ".symlink" into $HOME 106 | install_dotfiles () { 107 | info 'installing dotfiles' 108 | 109 | local overwrite_all=false backup_all=false skip_all=false 110 | 111 | for src in $(find -H "$DOTFILES_ROOT" -mindepth 2 -name '*.symlink' ) 112 | do 113 | dst="$HOME/.$(basename "${src%.*}")" 114 | link_file "$src" "$dst" 115 | done 116 | 117 | for src in $(find -H "$DOTFILES_ROOT" -mindepth 2 -name '.*' ) 118 | do 119 | if [ "$(basename $src)" != ".DS_Store" ] 120 | then 121 | dst="$HOME/$(basename $src)" 122 | link_file "$src" "$dst" 123 | fi 124 | done 125 | } 126 | 127 | install_dotfiles 128 | 129 | # If we're on a Mac, let's install and setup homebrew. 130 | if [ "$(uname -s)" == "Darwin" ] 131 | then 132 | info "installing dependencies" 133 | if source bin/dot > /tmp/dotfiles-dot 2>&1 134 | then 135 | success "dependencies installed" 136 | else 137 | fail "error installing dependencies" 138 | fi 139 | fi 140 | 141 | echo '' 142 | echo ' All installed!' 143 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # David does dotfiles, too 2 | 3 | Forked from "holman does dotfiles", these are my personal dotfiles. 4 | 5 | ## Changes from "holman does dotfiles" 6 | 7 | * Move `script/` files into root directory, a place I feel is better suited for the metaness of these scripts 8 | * `script/bootstrap` also symlinks files starting with "." into $HOME as well as files ending with ".symlink". 9 | This way I can keep the original name of the files, enabling proper syntax highlighting. 10 | 11 | # Highlights 12 | 13 | ## Rails 14 | 15 | ### `rg model user` 16 | 17 | Rails generator which opens all generated files in Sublime. 18 | 19 | ### `dkc` 20 | 21 | Runs `rails c` on remote server of the current dokku app repository. Requires gem `dokku-cli` to be installed (locally). 22 | 23 | ## Tmux 24 | 25 | ### `run_in_all_naked_panes command` 26 | 27 | Runs the command in all panes in Tmux, that are not currently running a process (except for a shell). 28 | 29 | ### `tclear` 30 | 31 | Clears all panes in Tmux except for the ones running a process (except for a shell) 32 | 33 | ## Ansible 34 | 35 | Ansible's default directory structure is too verbose to my liking. I built a custom homebrew formula to integrate the patch sourced from [here](https://groups.google.com/forum/#!searchin/ansible-devel/directory%2420structure%7Csort:date/ansible-devel/BfHRSzsq9d0/cfXi5oxHAQAJ) to allow files with the directory-name instead. 36 | 37 | Before: 38 | 39 | ``` 40 | roles/dnsmasq/ 41 | ├── defaults 42 | │ └── main.yml 43 | ├── handlers 44 | │ └── main.yml 45 | ├── meta 46 | │ └── main.yml 47 | ├── tasks 48 | │ └── main.yml 49 | └── templates 50 | ├── dns.conf.j2 51 | ├── logrotate.j2 52 | └── supervisord.j2 53 | ``` 54 | 55 | After: 56 | ``` 57 | roles/dnsmasq/ 58 | ├── defaults.yml 59 | ├── handlers.yml 60 | ├── meta.yml 61 | ├── tasks.yml 62 | └── templates 63 | ├── dns.conf.j2 64 | ├── logrotate.j2 65 | └── supervisord.j2 66 | ``` 67 | 68 | 69 | ## known 70 | 71 | `known` is a tool I built to easily remove a host from `.ssh/known_hosts` after you know that its key changed. 72 | 73 | Use as follows: 74 | 75 | ``` 76 | › ssh sandcrawler.crowdway.com 77 | 78 | @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ 79 | @ WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED! @ 80 | @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ 81 | IT IS POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY! 82 | Someone could be eavesdropping on you right now (man-in-the-middle attack)! 83 | It is also possible that a host key has just been changed. 84 | The fingerprint for the ECDSA key sent by the remote host is 85 | SHA256:+9nZWr9tcMA6TRckj+w6t9FWoK9/CtdamWZhzg98h+8. 86 | Please contact your system administrator. 87 | Add correct host key in /Users/david/.ssh/known_hosts to get rid of this message. 88 | Offending ECDSA key in /Users/david/.ssh/known_hosts:34 89 | ECDSA host key for sandcrawler.crowdway.com has changed and you have requested strict checking. 90 | Host key verification failed. 91 | 92 | › known 93 | Removing sandcrawler.crowdway.com from known_hosts 94 | 95 | # Host sandcrawler.crowdway.com found: line 34 96 | /Users/david/.ssh/known_hosts updated. 97 | Original contents retained as /Users/david/.ssh/known_hosts.old 98 | 99 | › ssh sandcrawler.crowdway.com 100 | The authenticity of host 'sandcrawler.crowdway.com (176.9.19.183)' can't be established. 101 | ECDSA key fingerprint is SHA256:+9nZWr9tcMA6TRckj+w6t9FWoK9/CtdamWZhzg98h+8. 102 | Are you sure you want to continue connecting (yes/no)? 103 | ``` 104 | 105 | ## Install 106 | 107 | Run this: 108 | 109 | ```sh 110 | git clone https://github.com/dv/dotfiles.git ~/poetry/dotfiles 111 | cd ~/poetry/dotfiles 112 | ./bootstrap 113 | ``` 114 | 115 | This will symlink the appropriate files in `.dotfiles` to your home directory. 116 | Everything is configured and tweaked within `~/.dotfiles`. 117 | 118 | Then run this: 119 | 120 | ```sh 121 | ./install 122 | ``` 123 | 124 | The main file you'll want to change right off the bat is `zsh/zshrc.symlink`, 125 | which sets up a few paths that'll be different on your particular machine. 126 | 127 | `dot` is a simple script that installs some dependencies, sets sane OS X 128 | defaults, and so on. Tweak this script, and occasionally run `dot` from 129 | time to time to keep your environment fresh and up-to-date. You can find 130 | this script in `bin/`. 131 | 132 | ## Topical 133 | 134 | Everything's built around topic areas. If you're adding a new area to your 135 | forked dotfiles — say, "Java" — you can simply add a `java` directory and put 136 | files in there. Anything with an extension of `.zsh` will get automatically 137 | included into your shell. Anything that starts with a dot, or has an extension 138 | of `.symlink` will get symlinked without extension into `$HOME` when you run 139 | `script/bootstrap`. 140 | 141 | ## Components 142 | 143 | There's a few special files in the hierarchy. 144 | 145 | - **bin/**: Anything in `bin/` will get added to your `$PATH` and be made 146 | available everywhere. 147 | - **topic/\*.zsh**: Any files ending in `.zsh` get loaded into your 148 | environment. 149 | - **topic/path.zsh**: Any file named `path.zsh` is loaded first and is 150 | expected to setup `$PATH` or similar. 151 | - **topic/completion.zsh**: Any file named `completion.zsh` is loaded 152 | last and is expected to setup autocomplete. 153 | - **topic/\*.symlink**: Any files ending in `*.symlink` get symlinked into 154 | your `$HOME`. This is so you can keep all of those versioned in your dotfiles 155 | but still keep those autoloaded files in your home directory. These get 156 | symlinked in when you run `script/bootstrap`. 157 | 158 | ## Sources 159 | 160 | - Inspiration on keymapping http://stevelosh.com/blog/2012/10/a-modern-space-cadet/ (thanks for the introduction @cedricpim!) 161 | 162 | -------------------------------------------------------------------------------- /sublime/User/SublimeLinter/All Hallow's Eve (SL).tmTheme: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | author 6 | David Heinemeier Hansson 7 | name 8 | All Hallow's Eve 9 | settings 10 | 11 | 12 | settings 13 | 14 | background 15 | #000000 16 | caret 17 | #FFFFFF 18 | foreground 19 | #FFFFFF 20 | invisibles 21 | #404040 22 | lineHighlight 23 | #333300 24 | selection 25 | #73597EE0 26 | 27 | 28 | 29 | name 30 | Text base 31 | scope 32 | text 33 | settings 34 | 35 | background 36 | #434242 37 | foreground 38 | #FFFFFF 39 | 40 | 41 | 42 | name 43 | Source base 44 | scope 45 | source 46 | settings 47 | 48 | background 49 | #000000 50 | foreground 51 | #FFFFFF 52 | 53 | 54 | 55 | name 56 | Comment 57 | scope 58 | comment 59 | settings 60 | 61 | foreground 62 | #9933CC 63 | 64 | 65 | 66 | name 67 | Constant 68 | scope 69 | constant 70 | settings 71 | 72 | foreground 73 | #3387CC 74 | 75 | 76 | 77 | name 78 | Keyword 79 | scope 80 | keyword 81 | settings 82 | 83 | fontStyle 84 | 85 | foreground 86 | #CC7833 87 | 88 | 89 | 90 | name 91 | Pre-processor Line 92 | scope 93 | meta.preprocessor.c 94 | settings 95 | 96 | fontStyle 97 | 98 | foreground 99 | #D0D0FF 100 | 101 | 102 | 103 | name 104 | Pre-processor Directive 105 | scope 106 | keyword.control.import 107 | settings 108 | 109 | fontStyle 110 | 111 | 112 | 113 | 114 | name 115 | Function name 116 | scope 117 | entity.name.function 118 | settings 119 | 120 | fontStyle 121 | 122 | 123 | 124 | 125 | name 126 | Function argument 127 | scope 128 | variable.parameter 129 | settings 130 | 131 | fontStyle 132 | italic 133 | 134 | 135 | 136 | name 137 | Block comment 138 | scope 139 | source comment.block 140 | settings 141 | 142 | background 143 | #9B9B9B 144 | foreground 145 | #FFFFFF 146 | 147 | 148 | 149 | name 150 | String 151 | scope 152 | string 153 | settings 154 | 155 | foreground 156 | #66CC33 157 | 158 | 159 | 160 | name 161 | String escapes 162 | scope 163 | string constant.character.escape 164 | settings 165 | 166 | foreground 167 | #AAAAAA 168 | 169 | 170 | 171 | name 172 | String (executed) 173 | scope 174 | string.interpolated 175 | settings 176 | 177 | background 178 | #CCCC33 179 | foreground 180 | #000000 181 | 182 | 183 | 184 | name 185 | Regular expression 186 | scope 187 | string.regexp 188 | settings 189 | 190 | foreground 191 | #CCCC33 192 | 193 | 194 | 195 | name 196 | String (literal) 197 | scope 198 | string.literal 199 | settings 200 | 201 | foreground 202 | #CCCC33 203 | 204 | 205 | 206 | name 207 | String escapes (executed) 208 | scope 209 | string.interpolated constant.character.escape 210 | settings 211 | 212 | foreground 213 | #555555 214 | 215 | 216 | 217 | name 218 | Type name 219 | scope 220 | entity.name.type 221 | settings 222 | 223 | fontStyle 224 | underline 225 | 226 | 227 | 228 | name 229 | Class inheritance 230 | scope 231 | entity.other.inherited-class 232 | settings 233 | 234 | fontStyle 235 | italic underline 236 | 237 | 238 | 239 | name 240 | Tag name 241 | scope 242 | entity.name.tag 243 | settings 244 | 245 | fontStyle 246 | underline 247 | 248 | 249 | 250 | name 251 | Tag attribute 252 | scope 253 | entity.other.attribute-name 254 | settings 255 | 256 | fontStyle 257 | 258 | 259 | 260 | 261 | name 262 | Support function 263 | scope 264 | support.function 265 | settings 266 | 267 | fontStyle 268 | 269 | foreground 270 | #C83730 271 | 272 | 273 | 274 | name 275 | SublimeLinter Warning 276 | scope 277 | sublimelinter.mark.warning 278 | settings 279 | 280 | foreground 281 | #DDB700 282 | 283 | 284 | name 285 | SublimeLinter Error 286 | scope 287 | sublimelinter.mark.error 288 | settings 289 | 290 | foreground 291 | #D02000 292 | 293 | 294 | name 295 | SublimeLinter Gutter Mark 296 | scope 297 | sublimelinter.gutter-mark 298 | settings 299 | 300 | foreground 301 | #FFFFFF 302 | 303 | 304 | uuid 305 | 37F22BDC-B2F4-11D9-850C-000A95A89C98 306 | 307 | -------------------------------------------------------------------------------- /sublime/User/SublimeLinter/LAZY (SL).tmTheme: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | author 6 | Domenico Carbotta 7 | name 8 | LAZY 9 | settings 10 | 11 | 12 | settings 13 | 14 | background 15 | #FFFFFF 16 | caret 17 | #7C7C7C 18 | foreground 19 | #000000 20 | invisibles 21 | #B6B6B6 22 | lineHighlight 23 | #EFFCA68F 24 | selection 25 | #E3FC8D 26 | 27 | 28 | 29 | name 30 | Comment 31 | scope 32 | comment 33 | settings 34 | 35 | fontStyle 36 | 37 | foreground 38 | #8C868F 39 | 40 | 41 | 42 | name 43 | Constant 44 | scope 45 | constant 46 | settings 47 | 48 | fontStyle 49 | 50 | foreground 51 | #3B5BB5 52 | 53 | 54 | 55 | name 56 | Entity 57 | scope 58 | entity 59 | settings 60 | 61 | fontStyle 62 | 63 | foreground 64 | #3B5BB5 65 | 66 | 67 | 68 | name 69 | Latex Entity 70 | scope 71 | text.tex.latex entity 72 | settings 73 | 74 | fontStyle 75 | 76 | foreground 77 | #D62A28 78 | 79 | 80 | 81 | name 82 | Keyword 83 | scope 84 | keyword, storage 85 | settings 86 | 87 | fontStyle 88 | 89 | foreground 90 | #FF7800 91 | 92 | 93 | 94 | name 95 | String 96 | scope 97 | string, meta.verbatim 98 | settings 99 | 100 | fontStyle 101 | 102 | foreground 103 | #409B1C 104 | 105 | 106 | 107 | name 108 | Support 109 | scope 110 | support 111 | settings 112 | 113 | fontStyle 114 | 115 | foreground 116 | #3B5BB5 117 | 118 | 119 | 120 | name 121 | Variable 122 | scope 123 | variable 124 | settings 125 | 126 | fontStyle 127 | 128 | 129 | 130 | 131 | name 132 | Invalid – Deprecated 133 | scope 134 | invalid.deprecated 135 | settings 136 | 137 | fontStyle 138 | italic 139 | foreground 140 | #990000 141 | 142 | 143 | 144 | name 145 | Invalid – Illegal 146 | scope 147 | invalid.illegal 148 | settings 149 | 150 | background 151 | #9D1E15 152 | foreground 153 | #F8F8F8 154 | 155 | 156 | 157 | name 158 | Superclass 159 | scope 160 | entity.other.inherited-class 161 | settings 162 | 163 | fontStyle 164 | italic 165 | foreground 166 | #3B5BB5 167 | 168 | 169 | 170 | name 171 | String interpolation 172 | scope 173 | string constant.other.placeholder 174 | settings 175 | 176 | fontStyle 177 | 178 | foreground 179 | #671EBB 180 | 181 | 182 | 183 | name 184 | meta.function-call.py 185 | scope 186 | meta.function-call.py 187 | settings 188 | 189 | fontStyle 190 | 191 | foreground 192 | #3E4558 193 | 194 | 195 | 196 | name 197 | meta.tag 198 | scope 199 | meta.tag, meta.tag entity 200 | settings 201 | 202 | foreground 203 | #3A4A64 204 | 205 | 206 | 207 | name 208 | OCaml variant 209 | scope 210 | keyword.type.variant 211 | settings 212 | 213 | fontStyle 214 | 215 | foreground 216 | #7F90AA 217 | 218 | 219 | 220 | name 221 | OCaml operator 222 | scope 223 | source.ocaml keyword.operator 224 | settings 225 | 226 | foreground 227 | #000000 228 | 229 | 230 | 231 | name 232 | OCaml infix operator 233 | scope 234 | source.ocaml keyword.operator.symbol.infix 235 | settings 236 | 237 | fontStyle 238 | 239 | foreground 240 | #3B5BB5 241 | 242 | 243 | 244 | name 245 | OCaml prefix operator 246 | scope 247 | source.ocaml keyword.operator.symbol.prefix 248 | settings 249 | 250 | foreground 251 | #3B5BB5 252 | 253 | 254 | 255 | name 256 | OCaml infix f-p operator 257 | scope 258 | source.ocaml keyword.operator.symbol.infix.floating-point 259 | settings 260 | 261 | fontStyle 262 | underline 263 | 264 | 265 | 266 | name 267 | OCaml prefix f-p operator 268 | scope 269 | source.ocaml keyword.operator.symbol.prefix.floating-point 270 | settings 271 | 272 | fontStyle 273 | underline 274 | 275 | 276 | 277 | name 278 | OCaml f-p constant 279 | scope 280 | source.ocaml constant.numeric.floating-point 281 | settings 282 | 283 | fontStyle 284 | underline 285 | 286 | 287 | 288 | name 289 | SublimeLinter Warning 290 | scope 291 | sublimelinter.mark.warning 292 | settings 293 | 294 | foreground 295 | #DDB700 296 | 297 | 298 | name 299 | SublimeLinter Error 300 | scope 301 | sublimelinter.mark.error 302 | settings 303 | 304 | foreground 305 | #D02000 306 | 307 | 308 | name 309 | SublimeLinter Gutter Mark 310 | scope 311 | sublimelinter.gutter-mark 312 | settings 313 | 314 | foreground 315 | #FFFFFF 316 | 317 | 318 | uuid 319 | A1E55FCB-3CD2-4811-9E73-D9B87419443A 320 | 321 | -------------------------------------------------------------------------------- /sublime/User/SublimeLinter/Zenburnesque (SL).tmTheme: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | author 6 | William D. Neumann 7 | name 8 | Zenburnesque 9 | settings 10 | 11 | 12 | settings 13 | 14 | background 15 | #404040 16 | caret 17 | #FFFF66 18 | foreground 19 | #DEDEDE 20 | invisibles 21 | #A8A8A8 22 | lineHighlight 23 | #A0804026 24 | selection 25 | #A0A0C0 26 | 27 | 28 | 29 | name 30 | Comment 31 | scope 32 | comment 33 | settings 34 | 35 | fontStyle 36 | italic 37 | foreground 38 | #709070 39 | 40 | 41 | 42 | name 43 | Directive 44 | scope 45 | keyword.other.directive 46 | settings 47 | 48 | fontStyle 49 | bold 50 | 51 | 52 | 53 | name 54 | Line-number directives 55 | scope 56 | keyword.other.directive.line-number 57 | settings 58 | 59 | fontStyle 60 | underline 61 | 62 | 63 | 64 | name 65 | Characters 66 | scope 67 | constant.character 68 | settings 69 | 70 | foreground 71 | #FF8080 72 | 73 | 74 | 75 | name 76 | String 77 | scope 78 | string 79 | settings 80 | 81 | foreground 82 | #FF2020 83 | 84 | 85 | 86 | name 87 | Number 88 | scope 89 | constant.numeric 90 | settings 91 | 92 | foreground 93 | #22C0FF 94 | 95 | 96 | 97 | name 98 | Floating-point numbers 99 | scope 100 | constant.numeric.floating-point 101 | settings 102 | 103 | fontStyle 104 | underline 105 | 106 | 107 | 108 | name 109 | Built-in constant 110 | scope 111 | constant.language 112 | settings 113 | 114 | 115 | 116 | name 117 | User-defined constant 118 | scope 119 | constant.character, constant.other 120 | settings 121 | 122 | 123 | 124 | name 125 | Variable 126 | scope 127 | variable.parameter, variable.other 128 | settings 129 | 130 | 131 | 132 | name 133 | Language Keyword 134 | scope 135 | keyword 136 | settings 137 | 138 | foreground 139 | #FFFFA0 140 | 141 | 142 | 143 | name 144 | Module Keyword 145 | scope 146 | entity.name.module, support.other.module 147 | settings 148 | 149 | fontStyle 150 | bold 151 | foreground 152 | #FF8000 153 | 154 | 155 | 156 | name 157 | Operators 158 | scope 159 | keyword.operator 160 | settings 161 | 162 | foreground 163 | #FFFFA0 164 | 165 | 166 | 167 | name 168 | Floating-point infix operators 169 | scope 170 | source.ocaml keyword.operator.symbol.infix.floating-point 171 | settings 172 | 173 | fontStyle 174 | underline 175 | 176 | 177 | 178 | name 179 | Floating-point prefix operators 180 | scope 181 | source.ocaml keyword.operator.symbol.prefix.floating-point 182 | settings 183 | 184 | fontStyle 185 | underline 186 | 187 | 188 | 189 | name 190 | Storage Types 191 | scope 192 | storage.type 193 | settings 194 | 195 | foreground 196 | #6080FF 197 | 198 | 199 | 200 | name 201 | Variant Types 202 | scope 203 | entity.name.class.variant 204 | settings 205 | 206 | foreground 207 | #4080A0 208 | 209 | 210 | 211 | name 212 | Storage 213 | scope 214 | storage 215 | settings 216 | 217 | 218 | 219 | name 220 | Type name 221 | scope 222 | entity.name.type 223 | settings 224 | 225 | foreground 226 | #F09040 227 | 228 | 229 | 230 | name 231 | Inherited class 232 | scope 233 | entity.other.inherited-class 234 | settings 235 | 236 | 237 | 238 | name 239 | Function name 240 | scope 241 | entity.name.function 242 | settings 243 | 244 | fontStyle 245 | bold 246 | foreground 247 | #FFCC66 248 | 249 | 250 | 251 | name 252 | Type name 253 | scope 254 | storage.type.user-defined 255 | settings 256 | 257 | foreground 258 | #FFE000 259 | 260 | 261 | 262 | name 263 | Class type name 264 | scope 265 | entity.name.type.class.type 266 | settings 267 | 268 | foreground 269 | #F4A020 270 | 271 | 272 | 273 | name 274 | Function argument 275 | scope 276 | variable.parameter 277 | settings 278 | 279 | fontStyle 280 | 281 | 282 | 283 | 284 | name 285 | Tag name 286 | scope 287 | entity.name.tag 288 | settings 289 | 290 | 291 | 292 | name 293 | Tag attribute 294 | scope 295 | entity.other.attribute-name 296 | settings 297 | 298 | 299 | 300 | name 301 | Library function 302 | scope 303 | support.function 304 | settings 305 | 306 | 307 | 308 | name 309 | Library constant 310 | scope 311 | support.constant 312 | settings 313 | 314 | 315 | 316 | name 317 | Library class/type 318 | scope 319 | support.type, support.class 320 | settings 321 | 322 | 323 | 324 | name 325 | Library variable 326 | scope 327 | support.variable 328 | settings 329 | 330 | 331 | 332 | name 333 | Invalid 334 | scope 335 | invalid 336 | settings 337 | 338 | 339 | 340 | name 341 | SublimeLinter Warning 342 | scope 343 | sublimelinter.mark.warning 344 | settings 345 | 346 | foreground 347 | #DDB700 348 | 349 | 350 | name 351 | SublimeLinter Error 352 | scope 353 | sublimelinter.mark.error 354 | settings 355 | 356 | foreground 357 | #D02000 358 | 359 | 360 | name 361 | SublimeLinter Gutter Mark 362 | scope 363 | sublimelinter.gutter-mark 364 | settings 365 | 366 | foreground 367 | #FFFFFF 368 | 369 | 370 | uuid 371 | 8D4988B9-ADD8-436F-B388-BC1360F8504B 372 | 373 | -------------------------------------------------------------------------------- /sublime/User/SublimeLinter/Blackboard (SL).tmTheme: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | name 6 | Blackboard 7 | author 8 | Domenico Carbotta 9 | settings 10 | 11 | 12 | settings 13 | 14 | background 15 | #0C1021 16 | caret 17 | #FFFFFFA6 18 | foreground 19 | #F8F8F8 20 | invisibles 21 | #FFFFFF40 22 | lineHighlight 23 | #FFFFFF0F 24 | selection 25 | #253B76 26 | 27 | 28 | 29 | name 30 | Comment 31 | scope 32 | comment 33 | settings 34 | 35 | fontStyle 36 | 37 | foreground 38 | #AEAEAE 39 | 40 | 41 | 42 | name 43 | Constant 44 | scope 45 | constant 46 | settings 47 | 48 | fontStyle 49 | 50 | foreground 51 | #D8FA3C 52 | 53 | 54 | 55 | name 56 | Entity 57 | scope 58 | entity 59 | settings 60 | 61 | fontStyle 62 | 63 | foreground 64 | #FF6400 65 | 66 | 67 | 68 | name 69 | Keyword 70 | scope 71 | keyword 72 | settings 73 | 74 | fontStyle 75 | 76 | foreground 77 | #FBDE2D 78 | 79 | 80 | 81 | name 82 | Storage 83 | scope 84 | storage 85 | settings 86 | 87 | fontStyle 88 | 89 | foreground 90 | #FBDE2D 91 | 92 | 93 | 94 | name 95 | String 96 | scope 97 | string, meta.verbatim 98 | settings 99 | 100 | fontStyle 101 | 102 | foreground 103 | #61CE3C 104 | 105 | 106 | 107 | name 108 | Support 109 | scope 110 | support 111 | settings 112 | 113 | fontStyle 114 | 115 | foreground 116 | #8DA6CE 117 | 118 | 119 | 120 | name 121 | Variable 122 | scope 123 | variable 124 | settings 125 | 126 | fontStyle 127 | 128 | 129 | 130 | 131 | name 132 | Invalid – Deprecated 133 | scope 134 | invalid.deprecated 135 | settings 136 | 137 | fontStyle 138 | italic 139 | foreground 140 | #AB2A1D 141 | 142 | 143 | 144 | name 145 | Invalid – Illegal 146 | scope 147 | invalid.illegal 148 | settings 149 | 150 | background 151 | #9D1E15 152 | foreground 153 | #F8F8F8 154 | 155 | 156 | 157 | name 158 | Superclass 159 | scope 160 | entity.other.inherited-class 161 | settings 162 | 163 | fontStyle 164 | italic 165 | foreground 166 | #FF6400 167 | 168 | 169 | 170 | name 171 | String interpolation 172 | scope 173 | string constant.other.placeholder 174 | settings 175 | 176 | fontStyle 177 | 178 | foreground 179 | #FF6400 180 | 181 | 182 | 183 | name 184 | meta.function-call.py 185 | scope 186 | meta.function-call.py 187 | settings 188 | 189 | fontStyle 190 | 191 | foreground 192 | #BECDE6 193 | 194 | 195 | 196 | name 197 | meta.tag 198 | scope 199 | meta.tag, meta.tag entity 200 | settings 201 | 202 | foreground 203 | #7F90AA 204 | 205 | 206 | 207 | name 208 | entity.name.section 209 | scope 210 | entity.name.section 211 | settings 212 | 213 | fontStyle 214 | 215 | foreground 216 | #FFFFFF 217 | 218 | 219 | 220 | name 221 | OCaml variant 222 | scope 223 | keyword.type.variant 224 | settings 225 | 226 | foreground 227 | #D5E0F3 228 | 229 | 230 | 231 | name 232 | OCaml operator 233 | scope 234 | source.ocaml keyword.operator.symbol 235 | settings 236 | 237 | foreground 238 | #F8F8F8 239 | 240 | 241 | 242 | name 243 | OCaml infix operator 244 | scope 245 | source.ocaml keyword.operator.symbol.infix 246 | settings 247 | 248 | fontStyle 249 | 250 | foreground 251 | #8DA6CE 252 | 253 | 254 | 255 | name 256 | OCaml prefix operator 257 | scope 258 | source.ocaml keyword.operator.symbol.prefix 259 | settings 260 | 261 | fontStyle 262 | 263 | foreground 264 | #8DA6CE 265 | 266 | 267 | 268 | name 269 | OCaml f-p infix operator 270 | scope 271 | source.ocaml keyword.operator.symbol.infix.floating-point 272 | settings 273 | 274 | fontStyle 275 | underline 276 | 277 | 278 | 279 | name 280 | OCaml f-p prefix operator 281 | scope 282 | source.ocaml keyword.operator.symbol.prefix.floating-point 283 | settings 284 | 285 | fontStyle 286 | underline 287 | 288 | 289 | 290 | name 291 | OCaml f-p constant 292 | scope 293 | source.ocaml constant.numeric.floating-point 294 | settings 295 | 296 | fontStyle 297 | underline 298 | 299 | 300 | 301 | name 302 | LaTeX environment 303 | scope 304 | text.tex.latex meta.function.environment 305 | settings 306 | 307 | background 308 | #FFFFFF08 309 | 310 | 311 | 312 | name 313 | LaTeX environment (nested) 314 | scope 315 | text.tex.latex meta.function.environment meta.function.environment 316 | settings 317 | 318 | background 319 | #7A96FA08 320 | 321 | 322 | 323 | name 324 | Latex support 325 | scope 326 | text.tex.latex support.function 327 | settings 328 | 329 | fontStyle 330 | 331 | foreground 332 | #FBDE2D 333 | 334 | 335 | 336 | name 337 | PList unquoted string 338 | scope 339 | source.plist string.unquoted, source.plist keyword.operator 340 | settings 341 | 342 | foreground 343 | #FFFFFF 344 | 345 | 346 | 347 | name 348 | SublimeLinter Warning 349 | scope 350 | sublimelinter.mark.warning 351 | settings 352 | 353 | foreground 354 | #DDB700 355 | 356 | 357 | name 358 | SublimeLinter Error 359 | scope 360 | sublimelinter.mark.error 361 | settings 362 | 363 | foreground 364 | #D02000 365 | 366 | 367 | name 368 | SublimeLinter Gutter Mark 369 | scope 370 | sublimelinter.gutter-mark 371 | settings 372 | 373 | foreground 374 | #FFFFFF 375 | 376 | 377 | uuid 378 | A2C6BAA7-90D0-4147-BBF5-96B0CD92D109 379 | 380 | -------------------------------------------------------------------------------- /hammerspoon/config/Spoons/EjectMenu.spoon/init.lua: -------------------------------------------------------------------------------- 1 | --- === EjectMenu === 2 | --- 3 | --- A much-needed eject menu for your Mac menu bar. Allows ejecting 4 | --- individual or all non-internal disks. Ejection can also be 5 | --- triggered on sleep, on lid close, or using a hotkey. 6 | --- Using the Command key modifier causes the menu to open 7 | --- the given volume in the Finder instead of ejecting it. 8 | --- 9 | --- Download: [https://github.com/Hammerspoon/Spoons/raw/master/Spoons/EjectMenu.spoon.zip](https://github.com/Hammerspoon/Spoons/raw/master/Spoons/EjectMenu.spoon.zip) 10 | 11 | local obj={} 12 | obj.__index = obj 13 | 14 | -- Metadata 15 | obj.name = "EjectMenu" 16 | obj.version = "0.1" 17 | obj.author = "Diego Zamboni , Mark Juers " 18 | obj.homepage = "https://github.com/Hammerspoon/Spoons" 19 | obj.license = "MIT - https://opensource.org/licenses/MIT" 20 | 21 | -- Watcher for system sleep events 22 | obj.caff_watcher = nil 23 | -- Watcher for screen change events 24 | obj.screen_watcher = nil 25 | -- Watcher for keyboard events (to change the menubar icon) 26 | obj.flags_watcher = nil 27 | -- Menubar icon 28 | obj.menubar = nil 29 | 30 | --- EjectMenu.logger 31 | --- Variable 32 | --- Logger object used within the Spoon. Can be accessed to set the default log level for the messages coming from the Spoon. 33 | obj.logger = hs.logger.new('EjectMenu') 34 | 35 | --- EjectMenu.never_eject 36 | --- Variable 37 | --- List containing volume paths that should never be ejected. Default value: empty list 38 | obj.never_eject = { } 39 | 40 | --- EjectMenu.notify 41 | --- Variable 42 | --- Boolean, whether to produce a notification about the volumes that get ejected. Default value: `false` 43 | obj.notify = false 44 | 45 | --- EjectMenu.eject_on_sleep 46 | --- Variable 47 | --- Boolean, whether to eject volumes before the system goes to sleep. Default value: true 48 | obj.eject_on_sleep = true 49 | 50 | --- EjectMenu.eject_on_lid_close 51 | --- Variable 52 | --- Boolean, whether to eject volumes when the laptop lid is closed with an external display connected. 53 | --- 54 | --- Notes: 55 | --- * There is no "lid close" event, so we detect when the internal display gets disabled. 56 | --- * This method is somewhat unreliable (e.g. it also triggers when the internal display goes to sleep due to inactivity), so its default value is `false` 57 | obj.eject_on_lid_close = false 58 | 59 | --- EjectMenu.show_in_menubar 60 | --- Variable 61 | --- Boolean, whether to show a menubar button to eject all drives. Default value: true 62 | obj.show_in_menubar = true 63 | 64 | --- EjectMenu.other_eject_events 65 | --- Variable 66 | --- List of additional system events on which the volumes should be ejected. 67 | --- 68 | --- Notes: 69 | --- * The values must be [http://www.hammerspoon.org/docs/hs.caffeinate.watcher.html](`hs.caffeinate.watcher`) constant values. Default value: empty list 70 | obj.other_eject_events = { } 71 | 72 | --- EjectMenu:shouldEject(path, info) 73 | --- Method 74 | --- Determine if a volume should be ejected. 75 | --- 76 | --- Parameters: 77 | --- * path - the mount path of the volume. 78 | --- * info - a table containing a data structure as returned by `hs.fs.volume.allVolumes()`. 79 | --- 80 | --- Returns: 81 | --- * A boolean indicating whether the volume should be ejected. 82 | function obj:shouldEject(path, info) 83 | self.logger.df("Checking whether volume %s should be ejected", path) 84 | return not (hs.fnutils.contains(self.never_eject, path) or info["NSURLVolumeIsInternalKey"]) 85 | end 86 | 87 | --- EjectMenu:volumesToEject() 88 | --- Method 89 | --- Return table of volumes to be ejected when "Eject All" is invoked. 90 | --- 91 | --- Parameters: 92 | --- * None 93 | --- 94 | --- Returns: 95 | --- * A table in the same format as returned by `hs.fs.volume.allVolumes()` but containing only those volumes for which `EjectMenu:shouldEject()` returns `true`. 96 | --- * An integer indicating how many volumes are in the table. 97 | function obj:volumesToEject() 98 | local volumes = hs.fs.volume.allVolumes() 99 | local ejectMenuDrives = {} 100 | local count = 0 101 | for path, v in pairs(volumes) do 102 | if self:shouldEject(path, v) then 103 | ejectMenuDrives[path] = v 104 | count = count + 1 105 | end 106 | end 107 | return ejectMenuDrives, count 108 | end 109 | 110 | -- Internal function to display a notification 111 | function obj.showNotification(title, subtitle, msg, persistent) 112 | local withdraw_time = 5 113 | if persistent then 114 | withdraw_time = 0 115 | end 116 | hs.notify.new( 117 | { 118 | title = title, 119 | subTitle = subtitle, 120 | informativeText = msg, 121 | withdrawAfter = withdraw_time 122 | }):send() 123 | end 124 | 125 | --- EjectMenu:ejectVolumes() 126 | --- Method 127 | --- Eject all volumes 128 | --- 129 | --- Parameters: 130 | --- * persistent_notifs: a boolean indicating whether notifications (if shown) should be persistent. 131 | function obj:ejectVolumes(persistent_notifs) 132 | local v, count = self:volumesToEject() 133 | self.logger.df("Ejecting volumes") 134 | local all_ejected = true 135 | for path,info in pairs(v) do 136 | local result,msg = hs.fs.volume.eject(path) 137 | if result then 138 | if self.notify then 139 | self.showNotification("EjectMenu", "Volume " .. path .. " ejected.", "", persistent_notifs) 140 | end 141 | self.logger.df("Volume %s was ejected.", path) 142 | else 143 | self.showNotification("EjectMenu", "Error ejecting " .. path, msg) 144 | self.logger.ef("Error ejecting volume %s: %s", path, msg) 145 | all_ejected = false 146 | end 147 | end 148 | if count > 0 and all_ejected then 149 | self.showNotification("EjectMenu", "All volumes unmounted.", "", persistent_notifs) 150 | end 151 | return self 152 | end 153 | 154 | -- EjectMenu:execMenuItem(mods, table) 155 | -- Method 156 | -- Defines and executes menu item based on which modifiers are held. 157 | -- 158 | -- Parameters 159 | -- * mods: A table containing which modifiers are held in {key = bool} format only if 'bool' is true. Other modifiers are omitted. 160 | -- * table: The menu item being activated. 161 | function obj:execMenuItem (mods, table) 162 | if ( 163 | mods['cmd'] == true and 164 | mods['ctrl'] == false and 165 | mods['alt'] == false and 166 | mods['shift'] == false and 167 | mods['fn'] == false 168 | ) then 169 | hs.osascript.applescript( 170 | 'tell application "Finder"' 171 | .. ' to open ("' .. table['path'] .. '" as POSIX file)' 172 | ) 173 | hs.appfinder.appFromName("Finder"):activate() 174 | else 175 | self.logger.df("Will eject %s", table['path']) 176 | hs.fs.volume.eject(table['path']) 177 | self.showNotification("EjectMenu", "Volume " .. table['path'] .. " ejected.", "", false) 178 | end 179 | end 180 | 181 | -- EjectMenu:initEjectMenu(mods) 182 | -- Method 183 | -- Initializes eject menu when clicked. 184 | -- 185 | -- Parameters 186 | -- * mods: a table containing {mod = bool} for all modifiers, where bool can be be either 'true' or 'false' (unlike execMenuItem). If a modifier is in effect, the given volume is opened in the Finder rather than ejected. 187 | -- 188 | -- Returns 189 | -- * ejectMenuTable: a table containing entries and functions for ejectable drives. 190 | function obj:initEjectMenu (mods) 191 | local ejectMenuDrives, count = self:volumesToEject() 192 | local ejectMenuTable = { 193 | {title = "Eject All", 194 | fn = function () self:ejectVolumes(false) end, 195 | disabled = (count == 0) 196 | }, 197 | {title = '-'} 198 | } 199 | if count > 0 then 200 | for drive, v in pairs(ejectMenuDrives) do 201 | self.logger.d(drive .. " is ejectable.") 202 | table.insert( 203 | ejectMenuTable, 204 | { 205 | title = v['NSURLVolumeLocalizedNameKey'], 206 | path = drive, 207 | fn = function (mods, table) self:execMenuItem(mods, table) end 208 | } 209 | ) 210 | end 211 | else 212 | self.logger.d("No external drives.") 213 | end 214 | return ejectMenuTable 215 | end 216 | 217 | --- EjectMenu:bindHotkeys(mapping, ejectAll) 218 | --- Method 219 | --- Binds hotkeys for EjectMenu 220 | --- 221 | --- Parameters: 222 | --- * mapping - A table containing hotkey objifier/key details for the following items: 223 | --- * ejectAll - eject all volumes. 224 | function obj:bindHotkeys(mapping) 225 | local spec = { ejectAll = hs.fnutils.partial(self.ejectVolumes, self) } 226 | hs.spoons.bindHotkeysToSpec(spec, mapping) 227 | end 228 | 229 | -- EjectMenu:changeEjectMenuIcon(mods) 230 | -- Method 231 | -- Changes eject menu icon depending on which modifiers are held. 232 | -- 233 | -- Parameters 234 | -- * mods: A table containing for which the keys are the modifiers being held and the values are 'true'. 235 | function obj:changeEjectMenuIcon (mods) 236 | if mods:containExactly({'cmd'}) then 237 | self.menubar:setTitle('⮑') 238 | elseif mods:containExactly({}) then 239 | self.menubar:setTitle('⏏') 240 | end 241 | end 242 | 243 | --- EjectMenu:start() 244 | --- Method 245 | --- Start the watchers for power events and screen changes, to trigger volume ejection. 246 | --- 247 | --- Parameters: 248 | --- * None 249 | function obj:start() 250 | if self.eject_on_sleep then 251 | self.caff_watcher = hs.caffeinate.watcher.new( 252 | function (e) 253 | self.logger.df("Received hs.caffeinate.watcher event %d", e) 254 | if (e == hs.caffeinate.watcher.systemWillSleep) or hs.fnutils.contains(self.other_eject_events, e) then 255 | self.logger.df(" About to go to sleep") 256 | self:ejectVolumes(true) 257 | end 258 | end):start() 259 | end 260 | if self.eject_on_lid_close then 261 | self.screen_watcher = hs.screen.watcher.new( 262 | function () 263 | self.logger.df("Received hs.screen.watcher event") 264 | local screens = hs.screen.allScreens() 265 | self.logger.df(" Screens: %s", hs.inspect(screens)) 266 | if #screens > 0 and hs.fnutils.every(screens, 267 | function (s) return s:name() ~= "Color LCD" end) then 268 | self.logger.df(" 'Color LCD' display is gone but other screens remain - detecting this as 'lid close'") 269 | self:ejectVolumes(true) 270 | end 271 | end 272 | ):start() 273 | end 274 | if self.show_in_menubar then 275 | self.menubar = hs.menubar.new():setTitle("⏏"): 276 | setMenu(function (mods) return self:initEjectMenu(mods) end) 277 | self.flags_watcher = hs.eventtap.new( 278 | {hs.eventtap.event.types.flagsChanged}, 279 | function (event) self:changeEjectMenuIcon(event:getFlags()) end 280 | ):start() 281 | end 282 | return self 283 | end 284 | 285 | --- EjectMenu:stop() 286 | --- Method 287 | --- Stop the watchers 288 | --- 289 | --- Parameters: 290 | --- * None 291 | function obj:stop() 292 | if self.caff_watcher then 293 | self.caff_watcher:stop() 294 | self.caff_watcher = nil 295 | end 296 | if self.screen_watcher then 297 | self.screen_watcher:stop() 298 | self.screen_watcher = nil 299 | end 300 | if self.menubar then 301 | self.menubar:delete() 302 | self.menubar = nil 303 | end 304 | if self.flags_watcher then 305 | self.flags_watcher:stop() 306 | self.flags_watcher = nil 307 | end 308 | return self 309 | end 310 | 311 | return obj 312 | -------------------------------------------------------------------------------- /sublime/User/SublimeLinter/Monokai Bright (SL).tmTheme: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | name 6 | Monokai Bright 7 | settings 8 | 9 | 10 | settings 11 | 12 | background 13 | #272822 14 | caret 15 | #F8F8F0 16 | foreground 17 | #F8F8F2 18 | invisibles 19 | #3B3A32 20 | lineHighlight 21 | #3E3D32 22 | selection 23 | #9D550F 24 | selectionForeground 25 | #fffff8 26 | inactiveSelection 27 | #bbbbbb 28 | inactiveSelectionForeground 29 | #222222 30 | findHighlight 31 | #FFE792 32 | findHighlightForeground 33 | #000000 34 | activeGuide 35 | #9D550FB0 36 | 37 | bracketsForeground 38 | #F8F8F2A5 39 | bracketsOptions 40 | underline 41 | 42 | bracketContentsForeground 43 | #F8F8F2A5 44 | bracketContentsOptions 45 | underline 46 | 47 | tagsOptions 48 | stippled_underline 49 | 50 | 51 | 52 | name 53 | Comment 54 | scope 55 | comment 56 | settings 57 | 58 | foreground 59 | #75715E 60 | 61 | 62 | 63 | name 64 | String 65 | scope 66 | string 67 | settings 68 | 69 | foreground 70 | #E6DB74 71 | 72 | 73 | 74 | name 75 | Number 76 | scope 77 | constant.numeric 78 | settings 79 | 80 | foreground 81 | #AE81FF 82 | 83 | 84 | 85 | name 86 | Built-in constant 87 | scope 88 | constant.language 89 | settings 90 | 91 | foreground 92 | #AE81FF 93 | 94 | 95 | 96 | name 97 | User-defined constant 98 | scope 99 | constant.character, constant.other 100 | settings 101 | 102 | foreground 103 | #AE81FF 104 | 105 | 106 | 107 | name 108 | Variable 109 | scope 110 | variable 111 | settings 112 | 113 | fontStyle 114 | 115 | 116 | 117 | 118 | name 119 | Keyword 120 | scope 121 | keyword 122 | settings 123 | 124 | foreground 125 | #F92672 126 | 127 | 128 | 129 | name 130 | Storage 131 | scope 132 | storage 133 | settings 134 | 135 | fontStyle 136 | 137 | foreground 138 | #F92672 139 | 140 | 141 | 142 | name 143 | Storage type 144 | scope 145 | storage.type 146 | settings 147 | 148 | fontStyle 149 | italic 150 | foreground 151 | #66D9EF 152 | 153 | 154 | 155 | name 156 | Class name 157 | scope 158 | entity.name.class 159 | settings 160 | 161 | fontStyle 162 | underline 163 | foreground 164 | #A6E22E 165 | 166 | 167 | 168 | name 169 | Inherited class 170 | scope 171 | entity.other.inherited-class 172 | settings 173 | 174 | fontStyle 175 | italic underline 176 | foreground 177 | #A6E22E 178 | 179 | 180 | 181 | name 182 | Function name 183 | scope 184 | entity.name.function 185 | settings 186 | 187 | fontStyle 188 | 189 | foreground 190 | #A6E22E 191 | 192 | 193 | 194 | name 195 | Function argument 196 | scope 197 | variable.parameter 198 | settings 199 | 200 | fontStyle 201 | italic 202 | foreground 203 | #FD971F 204 | 205 | 206 | 207 | name 208 | Tag name 209 | scope 210 | entity.name.tag 211 | settings 212 | 213 | fontStyle 214 | 215 | foreground 216 | #F92672 217 | 218 | 219 | 220 | name 221 | Tag attribute 222 | scope 223 | entity.other.attribute-name 224 | settings 225 | 226 | fontStyle 227 | 228 | foreground 229 | #A6E22E 230 | 231 | 232 | 233 | name 234 | Library function 235 | scope 236 | support.function 237 | settings 238 | 239 | fontStyle 240 | 241 | foreground 242 | #66D9EF 243 | 244 | 245 | 246 | name 247 | Library constant 248 | scope 249 | support.constant 250 | settings 251 | 252 | fontStyle 253 | 254 | foreground 255 | #66D9EF 256 | 257 | 258 | 259 | name 260 | Library class/type 261 | scope 262 | support.type, support.class 263 | settings 264 | 265 | fontStyle 266 | italic 267 | foreground 268 | #66D9EF 269 | 270 | 271 | 272 | name 273 | Library variable 274 | scope 275 | support.other.variable 276 | settings 277 | 278 | fontStyle 279 | 280 | 281 | 282 | 283 | name 284 | Invalid 285 | scope 286 | invalid 287 | settings 288 | 289 | background 290 | #F92672 291 | fontStyle 292 | 293 | foreground 294 | #F8F8F0 295 | 296 | 297 | 298 | name 299 | Invalid deprecated 300 | scope 301 | invalid.deprecated 302 | settings 303 | 304 | background 305 | #AE81FF 306 | foreground 307 | #F8F8F0 308 | 309 | 310 | 311 | name 312 | JSON String 313 | scope 314 | meta.structure.dictionary.json string.quoted.double.json 315 | settings 316 | 317 | foreground 318 | #CFCFC2 319 | 320 | 321 | 322 | 323 | name 324 | diff.header 325 | scope 326 | meta.diff, meta.diff.header 327 | settings 328 | 329 | foreground 330 | #75715E 331 | 332 | 333 | 334 | name 335 | diff.deleted 336 | scope 337 | markup.deleted 338 | settings 339 | 340 | foreground 341 | #F92672 342 | 343 | 344 | 345 | name 346 | diff.inserted 347 | scope 348 | markup.inserted 349 | settings 350 | 351 | foreground 352 | #A6E22E 353 | 354 | 355 | 356 | name 357 | diff.changed 358 | scope 359 | markup.changed 360 | settings 361 | 362 | foreground 363 | #E6DB74 364 | 365 | 366 | 367 | 368 | scope 369 | constant.numeric.line-number.find-in-files - match 370 | settings 371 | 372 | foreground 373 | #AE81FFA0 374 | 375 | 376 | 377 | scope 378 | entity.name.filename.find-in-files 379 | settings 380 | 381 | foreground 382 | #E6DB74 383 | 384 | 385 | 386 | 387 | name 388 | SublimeLinter Warning 389 | scope 390 | sublimelinter.mark.warning 391 | settings 392 | 393 | foreground 394 | #DDB700 395 | 396 | 397 | name 398 | SublimeLinter Error 399 | scope 400 | sublimelinter.mark.error 401 | settings 402 | 403 | foreground 404 | #D02000 405 | 406 | 407 | name 408 | SublimeLinter Gutter Mark 409 | scope 410 | sublimelinter.gutter-mark 411 | settings 412 | 413 | foreground 414 | #FFFFFF 415 | 416 | 417 | uuid 418 | D8D5E82E-3D5B-46B5-B38E-8C841C21347E 419 | 420 | -------------------------------------------------------------------------------- /sublime/User/SublimeLinter/Monokai (SL).tmTheme: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | name 6 | Monokai 7 | settings 8 | 9 | 10 | settings 11 | 12 | background 13 | #272822 14 | caret 15 | #F8F8F0 16 | foreground 17 | #F8F8F2 18 | invisibles 19 | #3B3A32 20 | lineHighlight 21 | #3E3D32 22 | selection 23 | #49483E 24 | findHighlight 25 | #FFE792 26 | findHighlightForeground 27 | #000000 28 | selectionBorder 29 | #222218 30 | activeGuide 31 | #9D550FB0 32 | 33 | bracketsForeground 34 | #F8F8F2A5 35 | bracketsOptions 36 | underline 37 | 38 | bracketContentsForeground 39 | #F8F8F2A5 40 | bracketContentsOptions 41 | underline 42 | 43 | tagsOptions 44 | stippled_underline 45 | 46 | 47 | 48 | name 49 | Comment 50 | scope 51 | comment 52 | settings 53 | 54 | foreground 55 | #75715E 56 | 57 | 58 | 59 | name 60 | String 61 | scope 62 | string 63 | settings 64 | 65 | foreground 66 | #E6DB74 67 | 68 | 69 | 70 | name 71 | Number 72 | scope 73 | constant.numeric 74 | settings 75 | 76 | foreground 77 | #AE81FF 78 | 79 | 80 | 81 | 82 | name 83 | Built-in constant 84 | scope 85 | constant.language 86 | settings 87 | 88 | foreground 89 | #AE81FF 90 | 91 | 92 | 93 | name 94 | User-defined constant 95 | scope 96 | constant.character, constant.other 97 | settings 98 | 99 | foreground 100 | #AE81FF 101 | 102 | 103 | 104 | name 105 | Variable 106 | scope 107 | variable 108 | settings 109 | 110 | fontStyle 111 | 112 | 113 | 114 | 115 | name 116 | Keyword 117 | scope 118 | keyword 119 | settings 120 | 121 | foreground 122 | #F92672 123 | 124 | 125 | 126 | name 127 | Storage 128 | scope 129 | storage 130 | settings 131 | 132 | fontStyle 133 | 134 | foreground 135 | #F92672 136 | 137 | 138 | 139 | name 140 | Storage type 141 | scope 142 | storage.type 143 | settings 144 | 145 | fontStyle 146 | italic 147 | foreground 148 | #66D9EF 149 | 150 | 151 | 152 | name 153 | Class name 154 | scope 155 | entity.name.class 156 | settings 157 | 158 | fontStyle 159 | underline 160 | foreground 161 | #A6E22E 162 | 163 | 164 | 165 | name 166 | Inherited class 167 | scope 168 | entity.other.inherited-class 169 | settings 170 | 171 | fontStyle 172 | italic underline 173 | foreground 174 | #A6E22E 175 | 176 | 177 | 178 | name 179 | Function name 180 | scope 181 | entity.name.function 182 | settings 183 | 184 | fontStyle 185 | 186 | foreground 187 | #A6E22E 188 | 189 | 190 | 191 | name 192 | Function argument 193 | scope 194 | variable.parameter 195 | settings 196 | 197 | fontStyle 198 | italic 199 | foreground 200 | #FD971F 201 | 202 | 203 | 204 | name 205 | Tag name 206 | scope 207 | entity.name.tag 208 | settings 209 | 210 | fontStyle 211 | 212 | foreground 213 | #F92672 214 | 215 | 216 | 217 | name 218 | Tag attribute 219 | scope 220 | entity.other.attribute-name 221 | settings 222 | 223 | fontStyle 224 | 225 | foreground 226 | #A6E22E 227 | 228 | 229 | 230 | name 231 | Library function 232 | scope 233 | support.function 234 | settings 235 | 236 | fontStyle 237 | 238 | foreground 239 | #66D9EF 240 | 241 | 242 | 243 | name 244 | Library constant 245 | scope 246 | support.constant 247 | settings 248 | 249 | fontStyle 250 | 251 | foreground 252 | #66D9EF 253 | 254 | 255 | 256 | name 257 | Library class/type 258 | scope 259 | support.type, support.class 260 | settings 261 | 262 | fontStyle 263 | italic 264 | foreground 265 | #66D9EF 266 | 267 | 268 | 269 | name 270 | Library variable 271 | scope 272 | support.other.variable 273 | settings 274 | 275 | fontStyle 276 | 277 | 278 | 279 | 280 | name 281 | Invalid 282 | scope 283 | invalid 284 | settings 285 | 286 | background 287 | #F92672 288 | fontStyle 289 | 290 | foreground 291 | #F8F8F0 292 | 293 | 294 | 295 | name 296 | Invalid deprecated 297 | scope 298 | invalid.deprecated 299 | settings 300 | 301 | background 302 | #AE81FF 303 | foreground 304 | #F8F8F0 305 | 306 | 307 | 308 | name 309 | JSON String 310 | scope 311 | meta.structure.dictionary.json string.quoted.double.json 312 | settings 313 | 314 | foreground 315 | #CFCFC2 316 | 317 | 318 | 319 | 320 | name 321 | diff.header 322 | scope 323 | meta.diff, meta.diff.header 324 | settings 325 | 326 | foreground 327 | #75715E 328 | 329 | 330 | 331 | name 332 | diff.deleted 333 | scope 334 | markup.deleted 335 | settings 336 | 337 | foreground 338 | #F92672 339 | 340 | 341 | 342 | name 343 | diff.inserted 344 | scope 345 | markup.inserted 346 | settings 347 | 348 | foreground 349 | #A6E22E 350 | 351 | 352 | 353 | name 354 | diff.changed 355 | scope 356 | markup.changed 357 | settings 358 | 359 | foreground 360 | #E6DB74 361 | 362 | 363 | 364 | 365 | scope 366 | constant.numeric.line-number.find-in-files - match 367 | settings 368 | 369 | foreground 370 | #AE81FFA0 371 | 372 | 373 | 374 | scope 375 | entity.name.filename 376 | settings 377 | 378 | foreground 379 | #E6DB74 380 | 381 | 382 | 383 | 384 | scope 385 | message.error 386 | settings 387 | 388 | foreground 389 | #F83333 390 | 391 | 392 | 393 | 394 | name 395 | SublimeLinter Warning 396 | scope 397 | sublimelinter.mark.warning 398 | settings 399 | 400 | foreground 401 | #DDB700 402 | 403 | 404 | name 405 | SublimeLinter Error 406 | scope 407 | sublimelinter.mark.error 408 | settings 409 | 410 | foreground 411 | #D02000 412 | 413 | 414 | name 415 | SublimeLinter Gutter Mark 416 | scope 417 | sublimelinter.gutter-mark 418 | settings 419 | 420 | foreground 421 | #FFFFFF 422 | 423 | 424 | uuid 425 | D8D5E82E-3D5B-46B5-B38E-8C841C21347D 426 | 427 | -------------------------------------------------------------------------------- /sublime/User/SublimeLinter/Espresso Libre (SL).tmTheme: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | author 6 | Chris Thomas 7 | name 8 | Espresso Libre 9 | settings 10 | 11 | 12 | settings 13 | 14 | background 15 | #2A211C 16 | caret 17 | #889AFF 18 | foreground 19 | #BDAE9D 20 | invisibles 21 | #BFBFBF 22 | lineHighlight 23 | #3A312C 24 | selection 25 | #C3DCFF 26 | 27 | 28 | 29 | name 30 | Comment 31 | scope 32 | comment 33 | settings 34 | 35 | fontStyle 36 | italic 37 | foreground 38 | #0066FF 39 | 40 | 41 | 42 | name 43 | Keyword 44 | scope 45 | keyword, storage 46 | settings 47 | 48 | fontStyle 49 | bold 50 | foreground 51 | #43A8ED 52 | 53 | 54 | 55 | name 56 | Number 57 | scope 58 | constant.numeric 59 | settings 60 | 61 | fontStyle 62 | 63 | foreground 64 | #44AA43 65 | 66 | 67 | 68 | name 69 | User-defined constant 70 | scope 71 | constant 72 | settings 73 | 74 | fontStyle 75 | bold 76 | foreground 77 | #C5656B 78 | 79 | 80 | 81 | name 82 | Built-in constant 83 | scope 84 | constant.language 85 | settings 86 | 87 | fontStyle 88 | bold 89 | foreground 90 | #585CF6 91 | 92 | 93 | 94 | name 95 | Variable 96 | scope 97 | variable.language, variable.other 98 | settings 99 | 100 | fontStyle 101 | 102 | foreground 103 | #318495 104 | 105 | 106 | 107 | name 108 | String 109 | scope 110 | string 111 | settings 112 | 113 | fontStyle 114 | 115 | foreground 116 | #049B0A 117 | 118 | 119 | 120 | name 121 | String interpolation 122 | scope 123 | constant.character.escape, string source 124 | settings 125 | 126 | fontStyle 127 | 128 | foreground 129 | #2FE420 130 | 131 | 132 | 133 | name 134 | Preprocessor line 135 | scope 136 | meta.preprocessor 137 | settings 138 | 139 | fontStyle 140 | 141 | foreground 142 | #1A921C 143 | 144 | 145 | 146 | name 147 | Preprocessor directive 148 | scope 149 | keyword.control.import 150 | settings 151 | 152 | fontStyle 153 | bold 154 | foreground 155 | #9AFF87 156 | 157 | 158 | 159 | name 160 | Function name 161 | scope 162 | entity.name.function, keyword.other.name-of-parameter.objc 163 | settings 164 | 165 | fontStyle 166 | bold 167 | foreground 168 | #FF9358 169 | 170 | 171 | 172 | name 173 | Type name 174 | scope 175 | entity.name.type 176 | settings 177 | 178 | fontStyle 179 | underline 180 | 181 | 182 | 183 | name 184 | Inherited class name 185 | scope 186 | entity.other.inherited-class 187 | settings 188 | 189 | fontStyle 190 | italic 191 | 192 | 193 | 194 | name 195 | Function parameter 196 | scope 197 | variable.parameter 198 | settings 199 | 200 | fontStyle 201 | italic 202 | 203 | 204 | 205 | name 206 | Function argument and result types 207 | scope 208 | storage.type.method 209 | settings 210 | 211 | fontStyle 212 | 213 | foreground 214 | #8B8E9C 215 | 216 | 217 | 218 | name 219 | Section 220 | scope 221 | meta.section entity.name.section, declaration.section entity.name.section 222 | settings 223 | 224 | fontStyle 225 | italic 226 | 227 | 228 | 229 | name 230 | Library function 231 | scope 232 | support.function 233 | settings 234 | 235 | fontStyle 236 | bold 237 | foreground 238 | #7290D9 239 | 240 | 241 | 242 | name 243 | Library object 244 | scope 245 | support.class, support.type 246 | settings 247 | 248 | fontStyle 249 | bold 250 | foreground 251 | #6D79DE 252 | 253 | 254 | 255 | name 256 | Library constant 257 | scope 258 | support.constant 259 | settings 260 | 261 | fontStyle 262 | bold 263 | foreground 264 | #00AF0E 265 | 266 | 267 | 268 | name 269 | Library variable 270 | scope 271 | support.variable 272 | settings 273 | 274 | fontStyle 275 | bold 276 | foreground 277 | #2F5FE0 278 | 279 | 280 | 281 | name 282 | JS: Operator 283 | scope 284 | keyword.operator.js 285 | settings 286 | 287 | foreground 288 | #687687 289 | 290 | 291 | 292 | name 293 | Invalid 294 | scope 295 | invalid 296 | settings 297 | 298 | background 299 | #990000 300 | foreground 301 | #FFFFFF 302 | 303 | 304 | 305 | name 306 | Invalid trailing whitespace 307 | scope 308 | invalid.deprecated.trailing-whitespace 309 | settings 310 | 311 | background 312 | #FFD0D0 313 | 314 | 315 | 316 | name 317 | Embedded source 318 | scope 319 | text source, string.unquoted 320 | settings 321 | 322 | background 323 | #F5AA7730 324 | 325 | 326 | 327 | name 328 | Markup XML declaration 329 | scope 330 | meta.tag.preprocessor.xml 331 | settings 332 | 333 | fontStyle 334 | 335 | foreground 336 | #8F7E65 337 | 338 | 339 | 340 | name 341 | Markup DOCTYPE 342 | scope 343 | meta.tag.sgml.doctype 344 | settings 345 | 346 | fontStyle 347 | 348 | foreground 349 | #888888 350 | 351 | 352 | 353 | name 354 | Markup DTD 355 | scope 356 | string.quoted.docinfo.doctype.DTD 357 | settings 358 | 359 | fontStyle 360 | italic 361 | 362 | 363 | 364 | name 365 | Markup tag 366 | scope 367 | meta.tag, declaration.tag 368 | settings 369 | 370 | fontStyle 371 | 372 | foreground 373 | #43A8ED 374 | 375 | 376 | 377 | name 378 | Markup name of tag 379 | scope 380 | entity.name.tag 381 | settings 382 | 383 | fontStyle 384 | bold 385 | 386 | 387 | 388 | name 389 | Markup tag attribute 390 | scope 391 | entity.other.attribute-name 392 | settings 393 | 394 | fontStyle 395 | italic 396 | 397 | 398 | 399 | name 400 | SublimeLinter Warning 401 | scope 402 | sublimelinter.mark.warning 403 | settings 404 | 405 | foreground 406 | #DDB700 407 | 408 | 409 | name 410 | SublimeLinter Error 411 | scope 412 | sublimelinter.mark.error 413 | settings 414 | 415 | foreground 416 | #D02000 417 | 418 | 419 | name 420 | SublimeLinter Gutter Mark 421 | scope 422 | sublimelinter.gutter-mark 423 | settings 424 | 425 | foreground 426 | #FFFFFF 427 | 428 | 429 | uuid 430 | 6B90703E-4E4B-43C8-9D32-921BEDF6D725 431 | 432 | -------------------------------------------------------------------------------- /sublime/User/SublimeLinter/Dawn (SL).tmTheme: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | author 6 | David Powers 7 | comment 8 | Dawn 9 | name 10 | Dawn 11 | settings 12 | 13 | 14 | settings 15 | 16 | background 17 | #F9F9F9 18 | caret 19 | #000000 20 | foreground 21 | #080808 22 | invisibles 23 | #4B4B7E80 24 | lineHighlight 25 | #2463B41F 26 | selection 27 | #275FFF4D 28 | shadow 29 | #808080 30 | shadowWidth 31 | 6 32 | 33 | 34 | 35 | name 36 | Comment 37 | scope 38 | comment 39 | settings 40 | 41 | fontStyle 42 | italic 43 | foreground 44 | #5A525F 45 | 46 | 47 | 48 | name 49 | Constant 50 | scope 51 | constant 52 | settings 53 | 54 | fontStyle 55 | bold 56 | foreground 57 | #811F24 58 | 59 | 60 | 61 | name 62 | Entity 63 | scope 64 | entity 65 | settings 66 | 67 | fontStyle 68 | 69 | foreground 70 | #BF4F24 71 | 72 | 73 | 74 | name 75 | Keyword 76 | scope 77 | keyword 78 | settings 79 | 80 | fontStyle 81 | 82 | foreground 83 | #794938 84 | 85 | 86 | 87 | name 88 | Storage 89 | scope 90 | storage 91 | settings 92 | 93 | fontStyle 94 | italic 95 | foreground 96 | #A71D5D 97 | 98 | 99 | 100 | name 101 | String 102 | scope 103 | string | punctuation.definition.string 104 | settings 105 | 106 | fontStyle 107 | 108 | foreground 109 | #0B6125 110 | 111 | 112 | 113 | name 114 | Support 115 | scope 116 | support 117 | settings 118 | 119 | fontStyle 120 | 121 | foreground 122 | #691C97 123 | 124 | 125 | 126 | name 127 | Variable 128 | scope 129 | variable 130 | settings 131 | 132 | fontStyle 133 | 134 | foreground 135 | #234A97 136 | 137 | 138 | 139 | name 140 | Punctuation.separator 141 | scope 142 | punctuation.separator 143 | settings 144 | 145 | foreground 146 | #794938 147 | 148 | 149 | 150 | name 151 | Invalid – Deprecated 152 | scope 153 | invalid.deprecated 154 | settings 155 | 156 | fontStyle 157 | bold italic underline 158 | foreground 159 | #B52A1D 160 | 161 | 162 | 163 | name 164 | Invalid – Illegal 165 | scope 166 | invalid.illegal 167 | settings 168 | 169 | background 170 | #B52A1D 171 | fontStyle 172 | italic underline 173 | foreground 174 | #F8F8F8 175 | 176 | 177 | 178 | name 179 | String embedded-source 180 | scope 181 | string source 182 | settings 183 | 184 | background 185 | #6F8BBA26 186 | fontStyle 187 | 188 | foreground 189 | #080808 190 | 191 | 192 | 193 | name 194 | String constant 195 | scope 196 | string constant 197 | settings 198 | 199 | fontStyle 200 | bold 201 | foreground 202 | #696969 203 | 204 | 205 | 206 | name 207 | String variable 208 | scope 209 | string variable 210 | settings 211 | 212 | fontStyle 213 | 214 | foreground 215 | #234A97 216 | 217 | 218 | 219 | name 220 | String.regexp 221 | scope 222 | string.regexp 223 | settings 224 | 225 | fontStyle 226 | 227 | foreground 228 | #CF5628 229 | 230 | 231 | 232 | name 233 | String.regexp.«special» 234 | scope 235 | string.regexp.character-class, string.regexp constant.character.escaped, string.regexp source.ruby.embedded, string.regexp string.regexp.arbitrary-repitition 236 | settings 237 | 238 | fontStyle 239 | bold italic 240 | foreground 241 | #CF5628 242 | 243 | 244 | 245 | name 246 | String.regexp constant.character.escape 247 | scope 248 | string.regexp constant.character.escape 249 | settings 250 | 251 | fontStyle 252 | bold 253 | foreground 254 | #811F24 255 | 256 | 257 | 258 | name 259 | Embedded Source 260 | scope 261 | text source 262 | settings 263 | 264 | background 265 | #6F8BBA26 266 | 267 | 268 | 269 | name 270 | Support.function 271 | scope 272 | support.function 273 | settings 274 | 275 | fontStyle 276 | 277 | foreground 278 | #693A17 279 | 280 | 281 | 282 | name 283 | Support.constant 284 | scope 285 | support.constant 286 | settings 287 | 288 | fontStyle 289 | 290 | foreground 291 | #B4371F 292 | 293 | 294 | 295 | name 296 | Support.variable 297 | scope 298 | support.variable 299 | settings 300 | 301 | foreground 302 | #234A97 303 | 304 | 305 | 306 | name 307 | Markup.list 308 | scope 309 | markup.list 310 | settings 311 | 312 | foreground 313 | #693A17 314 | 315 | 316 | 317 | name 318 | Markup.heading 319 | scope 320 | markup.heading | markup.heading entity.name 321 | settings 322 | 323 | fontStyle 324 | bold 325 | foreground 326 | #19356D 327 | 328 | 329 | 330 | name 331 | Markup.quote 332 | scope 333 | markup.quote 334 | settings 335 | 336 | background 337 | #BBBBBB30 338 | fontStyle 339 | italic 340 | foreground 341 | #0B6125 342 | 343 | 344 | 345 | name 346 | Markup.italic 347 | scope 348 | markup.italic 349 | settings 350 | 351 | fontStyle 352 | italic 353 | foreground 354 | #080808 355 | 356 | 357 | 358 | name 359 | Markup.bold 360 | scope 361 | markup.bold 362 | settings 363 | 364 | fontStyle 365 | bold 366 | foreground 367 | #080808 368 | 369 | 370 | 371 | name 372 | Markup.underline 373 | scope 374 | markup.underline 375 | settings 376 | 377 | fontStyle 378 | underline 379 | foreground 380 | #080808 381 | 382 | 383 | 384 | name 385 | Markup.link 386 | scope 387 | markup.link 388 | settings 389 | 390 | fontStyle 391 | italic underline 392 | foreground 393 | #234A97 394 | 395 | 396 | 397 | name 398 | Markup.raw 399 | scope 400 | markup.raw 401 | settings 402 | 403 | background 404 | #BBBBBB30 405 | fontStyle 406 | 407 | foreground 408 | #234A97 409 | 410 | 411 | 412 | name 413 | Markup.deleted 414 | scope 415 | markup.deleted 416 | settings 417 | 418 | foreground 419 | #B52A1D 420 | 421 | 422 | 423 | name 424 | Meta.separator 425 | scope 426 | meta.separator 427 | settings 428 | 429 | background 430 | #DCDCDC 431 | fontStyle 432 | bold 433 | foreground 434 | #19356D 435 | 436 | 437 | 438 | name 439 | SublimeLinter Warning 440 | scope 441 | sublimelinter.mark.warning 442 | settings 443 | 444 | foreground 445 | #DDB700 446 | 447 | 448 | name 449 | SublimeLinter Error 450 | scope 451 | sublimelinter.mark.error 452 | settings 453 | 454 | foreground 455 | #D02000 456 | 457 | 458 | name 459 | SublimeLinter Gutter Mark 460 | scope 461 | sublimelinter.gutter-mark 462 | settings 463 | 464 | foreground 465 | #FFFFFF 466 | 467 | 468 | uuid 469 | E7E82498-F9EA-49A6-A0D8-12327EA46B01 470 | 471 | -------------------------------------------------------------------------------- /bin/git-wtf: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | 3 | HELP = < 54 | .git-wtfrc" and edit it. The config file is a YAML file that specifies the 55 | integration branches, any branches to ignore, and the max number of commits to 56 | display when --all-commits isn't used. git-wtf will look for a .git-wtfrc file 57 | starting in the current directory, and recursively up to the root. 58 | 59 | IMPORTANT NOTE: all local branches referenced in .git-wtfrc must be prefixed 60 | with heads/, e.g. "heads/master". Remote branches must be of the form 61 | remotes//. 62 | EOS 63 | 64 | COPYRIGHT = <. 66 | This program is free software: you can redistribute it and/or modify it 67 | under the terms of the GNU General Public License as published by the Free 68 | Software Foundation, either version 3 of the License, or (at your option) 69 | any later version. 70 | 71 | This program is distributed in the hope that it will be useful, but WITHOUT 72 | ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 73 | FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for 74 | more details. 75 | 76 | You can find the GNU General Public License at: http://www.gnu.org/licenses/ 77 | EOS 78 | 79 | require 'yaml' 80 | CONFIG_FN = ".git-wtfrc" 81 | 82 | class Numeric; def pluralize s; "#{to_s} #{s}" + (self != 1 ? "s" : "") end end 83 | 84 | if ARGV.delete("--help") || ARGV.delete("-h") 85 | puts USAGE 86 | exit 87 | end 88 | 89 | ## poor man's trollop 90 | $long = ARGV.delete("--long") || ARGV.delete("-l") 91 | $short = ARGV.delete("--short") || ARGV.delete("-s") 92 | $all = ARGV.delete("--all") || ARGV.delete("-a") 93 | $all_commits = ARGV.delete("--all-commits") || ARGV.delete("-A") 94 | $dump_config = ARGV.delete("--dump-config") 95 | $key = ARGV.delete("--key") || ARGV.delete("-k") 96 | $show_relations = ARGV.delete("--relations") || ARGV.delete("-r") 97 | ARGV.each { |a| abort "Error: unknown argument #{a}." if a =~ /^--/ } 98 | 99 | ## search up the path for a file 100 | def find_file fn 101 | while true 102 | return fn if File.exist? fn 103 | fn2 = File.join("..", fn) 104 | return nil if File.expand_path(fn2) == File.expand_path(fn) 105 | fn = fn2 106 | end 107 | end 108 | 109 | want_color = `git config color.wtf` 110 | want_color = `git config color.ui` if want_color.empty? 111 | $color = case want_color.chomp 112 | when "true"; true 113 | when "auto"; $stdout.tty? 114 | end 115 | 116 | def red s; $color ? "\033[31m#{s}\033[0m" : s end 117 | def green s; $color ? "\033[32m#{s}\033[0m" : s end 118 | def yellow s; $color ? "\033[33m#{s}\033[0m" : s end 119 | def cyan s; $color ? "\033[36m#{s}\033[0m" : s end 120 | def grey s; $color ? "\033[1;30m#{s}\033[0m" : s end 121 | def purple s; $color ? "\033[35m#{s}\033[0m" : s end 122 | 123 | ## the set of commits in 'to' that aren't in 'from'. 124 | ## if empty, 'to' has been merged into 'from'. 125 | def commits_between from, to 126 | if $long 127 | `git log --pretty=format:"- %s [#{yellow "%h"}] (#{purple "%ae"}; %ar)" #{from}..#{to}` 128 | else 129 | `git log --pretty=format:"- %s [#{yellow "%h"}]" #{from}..#{to}` 130 | end.split(/[\r\n]+/) 131 | end 132 | 133 | def show_commits commits, prefix=" " 134 | if commits.empty? 135 | puts "#{prefix} none" 136 | else 137 | max = $all_commits ? commits.size : $config["max_commits"] 138 | max -= 1 if max == commits.size - 1 # never show "and 1 more" 139 | commits[0 ... max].each { |c| puts "#{prefix}#{c}" } 140 | puts grey("#{prefix}... and #{commits.size - max} more (use -A to see all).") if commits.size > max 141 | end 142 | end 143 | 144 | def ahead_behind_string ahead, behind 145 | [ahead.empty? ? nil : "#{ahead.size.pluralize 'commit'} ahead", 146 | behind.empty? ? nil : "#{behind.size.pluralize 'commit'} behind"]. 147 | compact.join("; ") 148 | end 149 | 150 | def widget merged_in, remote_only=false, local_only=false, local_only_merge=false 151 | left, right = case 152 | when remote_only; %w({ }) 153 | when local_only; %w{( )} 154 | else %w([ ]) 155 | end 156 | middle = case 157 | when merged_in && local_only_merge; green("~") 158 | when merged_in; green("x") 159 | else " " 160 | end 161 | print left, middle, right 162 | end 163 | 164 | def show b 165 | have_both = b[:local_branch] && b[:remote_branch] 166 | 167 | pushc, pullc, oosync = if have_both 168 | [x = commits_between(b[:remote_branch], b[:local_branch]), 169 | y = commits_between(b[:local_branch], b[:remote_branch]), 170 | !x.empty? && !y.empty?] 171 | end 172 | 173 | if b[:local_branch] 174 | puts "Local branch: " + green(b[:local_branch].sub(/^heads\//, "")) 175 | 176 | if have_both 177 | if pushc.empty? 178 | puts "#{widget true} in sync with remote" 179 | else 180 | action = oosync ? "push after rebase / merge" : "push" 181 | puts "#{widget false} NOT in sync with remote (you should #{action})" 182 | show_commits pushc unless $short 183 | end 184 | end 185 | end 186 | 187 | if b[:remote_branch] 188 | puts "Remote branch: #{cyan b[:remote_branch]} (#{b[:remote_url]})" 189 | 190 | if have_both 191 | if pullc.empty? 192 | puts "#{widget true} in sync with local" 193 | else 194 | action = pushc.empty? ? "merge" : "rebase / merge" 195 | puts "#{widget false} NOT in sync with local (you should #{action})" 196 | show_commits pullc unless $short 197 | end 198 | end 199 | end 200 | 201 | puts "\n#{red "WARNING"}: local and remote branches have diverged. A merge will occur unless you rebase." if oosync 202 | end 203 | 204 | def show_relations b, all_branches 205 | ibs, fbs = all_branches.partition { |name, br| $config["integration-branches"].include?(br[:local_branch]) || $config["integration-branches"].include?(br[:remote_branch]) } 206 | if $config["integration-branches"].include? b[:local_branch] 207 | puts "\nFeature branches:" unless fbs.empty? 208 | fbs.each do |name, br| 209 | next if $config["ignore"].member?(br[:local_branch]) || $config["ignore"].member?(br[:remote_branch]) 210 | next if br[:ignore] 211 | local_only = br[:remote_branch].nil? 212 | remote_only = br[:local_branch].nil? 213 | name = if local_only 214 | purple br[:name] 215 | elsif remote_only 216 | cyan br[:name] 217 | else 218 | green br[:name] 219 | end 220 | 221 | ## for remote_only branches, we'll compute wrt the remote branch head. otherwise, we'll 222 | ## use the local branch head. 223 | head = remote_only ? br[:remote_branch] : br[:local_branch] 224 | 225 | remote_ahead = b[:remote_branch] ? commits_between(b[:remote_branch], head) : [] 226 | local_ahead = b[:local_branch] ? commits_between(b[:local_branch], head) : [] 227 | 228 | if local_ahead.empty? && remote_ahead.empty? 229 | puts "#{widget true, remote_only, local_only} #{name} #{local_only ? "(local-only) " : ""}is merged in" 230 | elsif local_ahead.empty? 231 | puts "#{widget true, remote_only, local_only, true} #{name} merged in (only locally)" 232 | else 233 | behind = commits_between head, (br[:local_branch] || br[:remote_branch]) 234 | ahead = remote_only ? remote_ahead : local_ahead 235 | puts "#{widget false, remote_only, local_only} #{name} #{local_only ? "(local-only) " : ""}is NOT merged in (#{ahead_behind_string ahead, behind})" 236 | show_commits ahead unless $short 237 | end 238 | end 239 | else 240 | puts "\nIntegration branches:" unless ibs.empty? # unlikely 241 | ibs.sort_by { |v, br| v }.each do |v, br| 242 | next if $config["ignore"].member?(br[:local_branch]) || $config["ignore"].member?(br[:remote_branch]) 243 | next if br[:ignore] 244 | local_only = br[:remote_branch].nil? 245 | remote_only = br[:local_branch].nil? 246 | name = remote_only ? cyan(br[:name]) : green(br[:name]) 247 | 248 | ahead = commits_between v, (b[:local_branch] || b[:remote_branch]) 249 | if ahead.empty? 250 | puts "#{widget true, local_only} merged into #{name}" 251 | else 252 | #behind = commits_between b[:local_branch], v 253 | puts "#{widget false, local_only} NOT merged into #{name} (#{ahead.size.pluralize 'commit'} ahead)" 254 | show_commits ahead unless $short 255 | end 256 | end 257 | end 258 | end 259 | 260 | #### EXECUTION STARTS HERE #### 261 | 262 | ## find config file and load it 263 | $config = { "integration-branches" => %w(heads/master heads/next heads/edge), "ignore" => [], "max_commits" => 5 }.merge begin 264 | fn = find_file CONFIG_FN 265 | if fn && (h = YAML::load_file(fn)) # yaml turns empty files into false 266 | h["integration-branches"] ||= h["versions"] # support old nomenclature 267 | h 268 | else 269 | {} 270 | end 271 | end 272 | 273 | if $dump_config 274 | puts $config.to_yaml 275 | exit 276 | end 277 | 278 | ## first, index registered remotes 279 | remotes = `git config --get-regexp ^remote\.\*\.url`.split(/[\r\n]+/).inject({}) do |hash, l| 280 | l =~ /^remote\.(.+?)\.url (.+)$/ or next hash 281 | hash[$1] ||= $2 282 | hash 283 | end 284 | 285 | ## next, index followed branches 286 | branches = `git config --get-regexp ^branch\.`.split(/[\r\n]+/).inject({}) do |hash, l| 287 | case l 288 | when /branch\.(.*?)\.remote (.+)/ 289 | name, remote = $1, $2 290 | 291 | hash[name] ||= {} 292 | hash[name].merge! :remote => remote, :remote_url => remotes[remote] 293 | when /branch\.(.*?)\.merge ((refs\/)?heads\/)?(.+)/ 294 | name, remote_branch = $1, $4 295 | hash[name] ||= {} 296 | hash[name].merge! :remote_mergepoint => remote_branch 297 | end 298 | hash 299 | end 300 | 301 | ## finally, index all branches 302 | remote_branches = {} 303 | `git show-ref`.split(/[\r\n]+/).each do |l| 304 | sha1, ref = l.chomp.split " refs/" 305 | 306 | if ref =~ /^heads\/(.+)$/ # local branch 307 | name = $1 308 | next if name == "HEAD" 309 | branches[name] ||= {} 310 | branches[name].merge! :name => name, :local_branch => ref 311 | elsif ref =~ /^remotes\/(.+?)\/(.+)$/ # remote branch 312 | remote, name = $1, $2 313 | remote_branches["#{remote}/#{name}"] = true 314 | next if name == "HEAD" 315 | ignore = !($all || remote == "origin") 316 | 317 | branch = name 318 | if branches[name] && branches[name][:remote] == remote 319 | # nothing 320 | else 321 | name = "#{remote}/#{branch}" 322 | end 323 | 324 | branches[name] ||= {} 325 | branches[name].merge! :name => name, :remote => remote, :remote_branch => "#{remote}/#{branch}", :remote_url => remotes[remote], :ignore => ignore 326 | end 327 | end 328 | 329 | ## assemble remotes 330 | branches.each do |k, b| 331 | next unless b[:remote] && b[:remote_mergepoint] 332 | b[:remote_branch] = if b[:remote] == "." 333 | b[:remote_mergepoint] 334 | else 335 | t = "#{b[:remote]}/#{b[:remote_mergepoint]}" 336 | remote_branches[t] && t # only if it's still alive 337 | end 338 | end 339 | 340 | show_dirty = ARGV.empty? 341 | targets = if ARGV.empty? 342 | [`git symbolic-ref HEAD`.chomp.sub(/^refs\/heads\//, "")] 343 | else 344 | ARGV.map { |x| x.sub(/^heads\//, "") } 345 | end.map { |t| branches[t] or abort "Error: can't find branch #{t.inspect}." } 346 | 347 | targets.each do |t| 348 | show t 349 | show_relations t, branches if $show_relations || t[:remote_branch].nil? 350 | end 351 | 352 | modified = show_dirty && `git ls-files -m` != "" 353 | uncommitted = show_dirty && `git diff-index --cached HEAD` != "" 354 | 355 | if $key 356 | puts 357 | puts KEY 358 | end 359 | 360 | puts if modified || uncommitted 361 | puts "#{red "NOTE"}: working directory contains modified files." if modified 362 | puts "#{red "NOTE"}: staging area contains staged but uncommitted files." if uncommitted 363 | 364 | # the end! -------------------------------------------------------------------------------- /sublime/User/SublimeLinter/Twilight (SL).tmTheme: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | author 6 | Michael Sheets 7 | name 8 | Twilight 9 | settings 10 | 11 | 12 | settings 13 | 14 | background 15 | #141414 16 | caret 17 | #A7A7A7 18 | foreground 19 | #F8F8F8 20 | invisibles 21 | #FFFFFF40 22 | lineHighlight 23 | #FFFFFF08 24 | selection 25 | #DDF0FF33 26 | 27 | 28 | 29 | name 30 | Comment 31 | scope 32 | comment 33 | settings 34 | 35 | fontStyle 36 | italic 37 | foreground 38 | #5F5A60 39 | 40 | 41 | 42 | name 43 | Constant 44 | scope 45 | constant 46 | settings 47 | 48 | foreground 49 | #CF6A4C 50 | 51 | 52 | 53 | name 54 | Entity 55 | scope 56 | entity 57 | settings 58 | 59 | fontStyle 60 | 61 | foreground 62 | #9B703F 63 | 64 | 65 | 66 | name 67 | Keyword 68 | scope 69 | keyword 70 | settings 71 | 72 | fontStyle 73 | 74 | foreground 75 | #CDA869 76 | 77 | 78 | 79 | name 80 | Storage 81 | scope 82 | storage 83 | settings 84 | 85 | fontStyle 86 | 87 | foreground 88 | #F9EE98 89 | 90 | 91 | 92 | name 93 | String 94 | scope 95 | string 96 | settings 97 | 98 | fontStyle 99 | 100 | foreground 101 | #8F9D6A 102 | 103 | 104 | 105 | name 106 | Support 107 | scope 108 | support 109 | settings 110 | 111 | fontStyle 112 | 113 | foreground 114 | #9B859D 115 | 116 | 117 | 118 | name 119 | Variable 120 | scope 121 | variable 122 | settings 123 | 124 | foreground 125 | #7587A6 126 | 127 | 128 | 129 | name 130 | Invalid – Deprecated 131 | scope 132 | invalid.deprecated 133 | settings 134 | 135 | fontStyle 136 | italic underline 137 | foreground 138 | #D2A8A1 139 | 140 | 141 | 142 | name 143 | Invalid – Illegal 144 | scope 145 | invalid.illegal 146 | settings 147 | 148 | background 149 | #562D56BF 150 | foreground 151 | #F8F8F8 152 | 153 | 154 | 155 | name 156 | ----------------------------------- 157 | settings 158 | 159 | 160 | 161 | name 162 | ♦ Embedded Source 163 | scope 164 | text source 165 | settings 166 | 167 | background 168 | #B0B3BA14 169 | 170 | 171 | 172 | name 173 | ♦ Embedded Source (Bright) 174 | scope 175 | text.html.ruby source 176 | settings 177 | 178 | background 179 | #B1B3BA21 180 | 181 | 182 | 183 | name 184 | ♦ Entity inherited-class 185 | scope 186 | entity.other.inherited-class 187 | settings 188 | 189 | fontStyle 190 | italic 191 | foreground 192 | #9B5C2E 193 | 194 | 195 | 196 | name 197 | ♦ String embedded-source 198 | scope 199 | string source 200 | settings 201 | 202 | fontStyle 203 | 204 | foreground 205 | #DAEFA3 206 | 207 | 208 | 209 | name 210 | ♦ String constant 211 | scope 212 | string constant 213 | settings 214 | 215 | foreground 216 | #DDF2A4 217 | 218 | 219 | 220 | name 221 | ♦ String.regexp 222 | scope 223 | string.regexp 224 | settings 225 | 226 | fontStyle 227 | 228 | foreground 229 | #E9C062 230 | 231 | 232 | 233 | name 234 | ♦ String.regexp.«special» 235 | scope 236 | string.regexp constant.character.escape, string.regexp source.ruby.embedded, string.regexp string.regexp.arbitrary-repitition 237 | settings 238 | 239 | foreground 240 | #CF7D34 241 | 242 | 243 | 244 | name 245 | ♦ String variable 246 | scope 247 | string variable 248 | settings 249 | 250 | foreground 251 | #8A9A95 252 | 253 | 254 | 255 | name 256 | ♦ Support.function 257 | scope 258 | support.function 259 | settings 260 | 261 | fontStyle 262 | 263 | foreground 264 | #DAD085 265 | 266 | 267 | 268 | name 269 | ♦ Support.constant 270 | scope 271 | support.constant 272 | settings 273 | 274 | fontStyle 275 | 276 | foreground 277 | #CF6A4C 278 | 279 | 280 | 281 | name 282 | c C/C++ Preprocessor Line 283 | scope 284 | meta.preprocessor.c 285 | settings 286 | 287 | foreground 288 | #8996A8 289 | 290 | 291 | 292 | name 293 | c C/C++ Preprocessor Directive 294 | scope 295 | meta.preprocessor.c keyword 296 | settings 297 | 298 | foreground 299 | #AFC4DB 300 | 301 | 302 | 303 | name 304 | ✘ Doctype/XML Processing 305 | scope 306 | meta.tag.sgml.doctype, meta.tag.sgml.doctype entity, meta.tag.sgml.doctype string, meta.tag.preprocessor.xml, meta.tag.preprocessor.xml entity, meta.tag.preprocessor.xml string 307 | settings 308 | 309 | foreground 310 | #494949 311 | 312 | 313 | 314 | name 315 | ✘ Meta.tag.«all» 316 | scope 317 | declaration.tag, declaration.tag entity, meta.tag, meta.tag entity 318 | settings 319 | 320 | foreground 321 | #AC885B 322 | 323 | 324 | 325 | name 326 | ✘ Meta.tag.inline 327 | scope 328 | declaration.tag.inline, declaration.tag.inline entity, source entity.name.tag, source entity.other.attribute-name, meta.tag.inline, meta.tag.inline entity 329 | settings 330 | 331 | foreground 332 | #E0C589 333 | 334 | 335 | 336 | name 337 | § css tag-name 338 | scope 339 | meta.selector.css entity.name.tag 340 | settings 341 | 342 | foreground 343 | #CDA869 344 | 345 | 346 | 347 | name 348 | § css:pseudo-class 349 | scope 350 | meta.selector.css entity.other.attribute-name.tag.pseudo-class 351 | settings 352 | 353 | foreground 354 | #8F9D6A 355 | 356 | 357 | 358 | name 359 | § css#id 360 | scope 361 | meta.selector.css entity.other.attribute-name.id 362 | settings 363 | 364 | foreground 365 | #8B98AB 366 | 367 | 368 | 369 | name 370 | § css.class 371 | scope 372 | meta.selector.css entity.other.attribute-name.class 373 | settings 374 | 375 | foreground 376 | #9B703F 377 | 378 | 379 | 380 | name 381 | § css property-name: 382 | scope 383 | support.type.property-name.css 384 | settings 385 | 386 | foreground 387 | #C5AF75 388 | 389 | 390 | 391 | name 392 | § css property-value; 393 | scope 394 | meta.property-group support.constant.property-value.css, meta.property-value support.constant.property-value.css 395 | settings 396 | 397 | foreground 398 | #F9EE98 399 | 400 | 401 | 402 | name 403 | § css @at-rule 404 | scope 405 | meta.preprocessor.at-rule keyword.control.at-rule 406 | settings 407 | 408 | foreground 409 | #8693A5 410 | 411 | 412 | 413 | name 414 | § css additional-constants 415 | scope 416 | meta.property-value support.constant.named-color.css, meta.property-value constant 417 | settings 418 | 419 | foreground 420 | #CA7840 421 | 422 | 423 | 424 | name 425 | § css constructor.argument 426 | scope 427 | meta.constructor.argument.css 428 | settings 429 | 430 | foreground 431 | #8F9D6A 432 | 433 | 434 | 435 | name 436 | ⎇ diff.header 437 | scope 438 | meta.diff, meta.diff.header, meta.separator 439 | settings 440 | 441 | background 442 | #0E2231 443 | fontStyle 444 | italic 445 | foreground 446 | #F8F8F8 447 | 448 | 449 | 450 | name 451 | ⎇ diff.deleted 452 | scope 453 | markup.deleted 454 | settings 455 | 456 | background 457 | #420E09 458 | foreground 459 | #F8F8F8 460 | 461 | 462 | 463 | name 464 | ⎇ diff.changed 465 | scope 466 | markup.changed 467 | settings 468 | 469 | background 470 | #4A410D 471 | foreground 472 | #F8F8F8 473 | 474 | 475 | 476 | name 477 | ⎇ diff.inserted 478 | scope 479 | markup.inserted 480 | settings 481 | 482 | background 483 | #253B22 484 | foreground 485 | #F8F8F8 486 | 487 | 488 | 489 | name 490 | Markup: List 491 | scope 492 | markup.list 493 | settings 494 | 495 | foreground 496 | #F9EE98 497 | 498 | 499 | 500 | name 501 | Markup: Heading 502 | scope 503 | markup.heading 504 | settings 505 | 506 | foreground 507 | #CF6A4C 508 | 509 | 510 | 511 | name 512 | SublimeLinter Warning 513 | scope 514 | sublimelinter.mark.warning 515 | settings 516 | 517 | foreground 518 | #DDB700 519 | 520 | 521 | name 522 | SublimeLinter Error 523 | scope 524 | sublimelinter.mark.error 525 | settings 526 | 527 | foreground 528 | #D02000 529 | 530 | 531 | name 532 | SublimeLinter Gutter Mark 533 | scope 534 | sublimelinter.gutter-mark 535 | settings 536 | 537 | foreground 538 | #FFFFFF 539 | 540 | 541 | uuid 542 | 766026CB-703D-4610-B070-8DE07D967C5F 543 | 544 | -------------------------------------------------------------------------------- /sublime/User/SublimeLinter/Cobalt (SL).tmTheme: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | comment 6 | Created by Jacob Rus. Based on ‘Slate’ by Wilson Miner 7 | author 8 | Jacob Rus 9 | name 10 | Cobalt 11 | settings 12 | 13 | 14 | settings 15 | 16 | background 17 | #002240 18 | caret 19 | #FFFFFF 20 | foreground 21 | #FFFFFF 22 | invisibles 23 | #FFFFFF26 24 | lineHighlight 25 | #00000059 26 | selection 27 | #B36539BF 28 | 29 | 30 | 31 | name 32 | Punctuation 33 | scope 34 | punctuation - (punctuation.definition.string || punctuation.definition.comment) 35 | settings 36 | 37 | fontStyle 38 | 39 | foreground 40 | #E1EFFF 41 | 42 | 43 | 44 | name 45 | Constant 46 | scope 47 | constant 48 | settings 49 | 50 | fontStyle 51 | 52 | foreground 53 | #FF628C 54 | 55 | 56 | 57 | name 58 | Entity 59 | scope 60 | entity 61 | settings 62 | 63 | fontStyle 64 | 65 | foreground 66 | #FFDD00 67 | 68 | 69 | 70 | name 71 | Keyword 72 | scope 73 | keyword 74 | settings 75 | 76 | fontStyle 77 | 78 | foreground 79 | #FF9D00 80 | 81 | 82 | 83 | name 84 | Storage 85 | scope 86 | storage 87 | settings 88 | 89 | fontStyle 90 | 91 | foreground 92 | #FFEE80 93 | 94 | 95 | 96 | name 97 | String 98 | scope 99 | string -string.unquoted.old-plist -string.unquoted.heredoc, string.unquoted.heredoc string 100 | settings 101 | 102 | fontStyle 103 | 104 | foreground 105 | #3AD900 106 | 107 | 108 | 109 | name 110 | Comment 111 | scope 112 | comment 113 | settings 114 | 115 | fontStyle 116 | italic 117 | foreground 118 | #0088FF 119 | 120 | 121 | 122 | name 123 | Support 124 | scope 125 | support 126 | settings 127 | 128 | fontStyle 129 | 130 | foreground 131 | #80FFBB 132 | 133 | 134 | 135 | name 136 | Variable 137 | scope 138 | variable 139 | settings 140 | 141 | fontStyle 142 | 143 | foreground 144 | #CCCCCC 145 | 146 | 147 | 148 | name 149 | Lang Variable 150 | scope 151 | variable.language 152 | settings 153 | 154 | fontStyle 155 | 156 | foreground 157 | #FF80E1 158 | 159 | 160 | 161 | name 162 | Function Call 163 | scope 164 | meta.function-call 165 | settings 166 | 167 | foreground 168 | #FFEE80 169 | 170 | 171 | 172 | name 173 | Invalid 174 | scope 175 | invalid 176 | settings 177 | 178 | background 179 | #800F00 180 | foreground 181 | #F8F8F8 182 | 183 | 184 | 185 | name 186 | Embedded Source 187 | scope 188 | text source, string.unquoted.heredoc, source source 189 | settings 190 | 191 | background 192 | #223545 193 | fontStyle 194 | 195 | foreground 196 | #FFFFFF 197 | 198 | 199 | 200 | name 201 | Entity inherited-class 202 | scope 203 | entity.other.inherited-class 204 | settings 205 | 206 | fontStyle 207 | italic 208 | foreground 209 | #80FCFF 210 | 211 | 212 | 213 | name 214 | String embedded-source 215 | scope 216 | string.quoted source 217 | settings 218 | 219 | fontStyle 220 | 221 | foreground 222 | #9EFF80 223 | 224 | 225 | 226 | name 227 | String constant 228 | scope 229 | string constant 230 | settings 231 | 232 | foreground 233 | #80FF82 234 | 235 | 236 | 237 | name 238 | String.regexp 239 | scope 240 | string.regexp 241 | settings 242 | 243 | foreground 244 | #80FFC2 245 | 246 | 247 | 248 | name 249 | String variable 250 | scope 251 | string variable 252 | settings 253 | 254 | foreground 255 | #EDEF7D 256 | 257 | 258 | 259 | name 260 | Support.function 261 | scope 262 | support.function 263 | settings 264 | 265 | fontStyle 266 | 267 | foreground 268 | #FFB054 269 | 270 | 271 | 272 | name 273 | Support.constant 274 | scope 275 | support.constant 276 | settings 277 | 278 | fontStyle 279 | 280 | foreground 281 | #EB939A 282 | 283 | 284 | 285 | name 286 | Exception 287 | scope 288 | support.type.exception 289 | settings 290 | 291 | foreground 292 | #FF1E00 293 | 294 | 295 | 296 | name 297 | C/C++ Preprocessor Line 298 | scope 299 | meta.preprocessor.c 300 | settings 301 | 302 | foreground 303 | #8996A8 304 | 305 | 306 | 307 | name 308 | C/C++ Preprocessor Directive 309 | scope 310 | meta.preprocessor.c keyword 311 | settings 312 | 313 | foreground 314 | #AFC4DB 315 | 316 | 317 | 318 | name 319 | Doctype/XML Processing 320 | scope 321 | meta.sgml.html meta.doctype, meta.sgml.html meta.doctype entity, meta.sgml.html meta.doctype string, meta.xml-processing, meta.xml-processing entity, meta.xml-processing string 322 | settings 323 | 324 | foreground 325 | #73817D 326 | 327 | 328 | 329 | name 330 | Meta.tag.A 331 | scope 332 | meta.tag, meta.tag entity 333 | settings 334 | 335 | foreground 336 | #9EFFFF 337 | 338 | 339 | 340 | name 341 | css tag-name 342 | scope 343 | meta.selector.css entity.name.tag 344 | settings 345 | 346 | foreground 347 | #9EFFFF 348 | 349 | 350 | 351 | name 352 | css#id 353 | scope 354 | meta.selector.css entity.other.attribute-name.id 355 | settings 356 | 357 | foreground 358 | #FFB454 359 | 360 | 361 | 362 | name 363 | css.class 364 | scope 365 | meta.selector.css entity.other.attribute-name.class 366 | settings 367 | 368 | foreground 369 | #5FE461 370 | 371 | 372 | 373 | name 374 | css property-name: 375 | scope 376 | support.type.property-name.css 377 | settings 378 | 379 | foreground 380 | #9DF39F 381 | 382 | 383 | 384 | name 385 | css property-value; 386 | scope 387 | meta.property-group support.constant.property-value.css, meta.property-value support.constant.property-value.css 388 | settings 389 | 390 | foreground 391 | #F6F080 392 | 393 | 394 | 395 | name 396 | css @at-rule 397 | scope 398 | meta.preprocessor.at-rule keyword.control.at-rule 399 | settings 400 | 401 | foreground 402 | #F6AA11 403 | 404 | 405 | 406 | name 407 | css additional-constants 408 | scope 409 | meta.property-value support.constant.named-color.css, meta.property-value constant 410 | settings 411 | 412 | foreground 413 | #EDF080 414 | 415 | 416 | 417 | name 418 | css constructor.argument 419 | scope 420 | meta.constructor.argument.css 421 | settings 422 | 423 | foreground 424 | #EB939A 425 | 426 | 427 | 428 | name 429 | diff.header 430 | scope 431 | meta.diff, meta.diff.header 432 | settings 433 | 434 | background 435 | #000E1A 436 | fontStyle 437 | 438 | foreground 439 | #F8F8F8 440 | 441 | 442 | 443 | name 444 | diff.deleted 445 | scope 446 | markup.deleted 447 | settings 448 | 449 | background 450 | #4C0900 451 | foreground 452 | #F8F8F8 453 | 454 | 455 | 456 | name 457 | diff.changed 458 | scope 459 | markup.changed 460 | settings 461 | 462 | background 463 | #806F00 464 | foreground 465 | #F8F8F8 466 | 467 | 468 | 469 | name 470 | diff.inserted 471 | scope 472 | markup.inserted 473 | settings 474 | 475 | background 476 | #154F00 477 | foreground 478 | #F8F8F8 479 | 480 | 481 | 482 | name 483 | Raw Markup 484 | scope 485 | markup.raw 486 | settings 487 | 488 | background 489 | #8FDDF630 490 | 491 | 492 | 493 | name 494 | Block Quote 495 | scope 496 | markup.quote 497 | settings 498 | 499 | background 500 | #004480 501 | 502 | 503 | 504 | name 505 | List 506 | scope 507 | markup.list 508 | settings 509 | 510 | background 511 | #130D26 512 | 513 | 514 | 515 | name 516 | Bold Markup 517 | scope 518 | markup.bold 519 | settings 520 | 521 | fontStyle 522 | bold 523 | foreground 524 | #C1AFFF 525 | 526 | 527 | 528 | name 529 | Italic Markup 530 | scope 531 | markup.italic 532 | settings 533 | 534 | fontStyle 535 | italic 536 | foreground 537 | #B8FFD9 538 | 539 | 540 | 541 | name 542 | Heading Markup 543 | scope 544 | markup.heading 545 | settings 546 | 547 | background 548 | #001221 549 | fontStyle 550 | bold 551 | foreground 552 | #C8E4FD 553 | 554 | 555 | 556 | name 557 | SublimeLinter Warning 558 | scope 559 | sublimelinter.mark.warning 560 | settings 561 | 562 | foreground 563 | #DDB700 564 | 565 | 566 | name 567 | SublimeLinter Error 568 | scope 569 | sublimelinter.mark.error 570 | settings 571 | 572 | foreground 573 | #D02000 574 | 575 | 576 | name 577 | SublimeLinter Gutter Mark 578 | scope 579 | sublimelinter.gutter-mark 580 | settings 581 | 582 | foreground 583 | #FFFFFF 584 | 585 | 586 | uuid 587 | 06CD1FB2-A00A-4F8C-97B2-60E131980454 588 | 589 | --------------------------------------------------------------------------------