This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
vnoremap <leader>q :<c-u>call <SID>QuoteLines()<cr> | |
vnoremap <leader>j :<c-u>call <SID>JoinLines()<cr> | |
vmap <leader>s <leader>qgv<leader>j | |
function! s:JoinLines() | |
silent! execute "normal! gv:\<c-u>'<,'>-1s/\\v$/,/g\<cr>gvJ" | |
endfunction | |
function! s:QuoteLines() | |
silent! execute "normal! gv:s/\\v(^\\s*)([^[:space:]].{-})(\\s*$)/\\1'\\2'\\3/\<CR>" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* A few assumptions: | |
* * School is immutable (otherwise, implementing hashCode/equals doesn't really make sense) | |
* * The problem is incompletely specified, with respect to how to handle missing values: | |
* * What do you do when both name and nickname are null? | |
* * What if one School has a name + nickname and the other has just a name, but the names match? | |
* My decision (and I think this is reasonable) is: Both must match. If a value is null in one, | |
* it must be null in the other to be considered equal | |
*/ | |
class School { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDDw8vdRpf7ZpKf+eA3+Ify8ZMzFbUb0DoOZkRYHT9rQ7Rtjs3sB6bl5GgfKGX4y0cj8EiGmiPpsIylASEWeZKpf28stPDulc+pcr8we+A6XIuXPo1z8D4MLKXwg79XcHpa+Jr7OWef3JtkF5lv0z8Tpfr/nNyM/XcB9Opzawmz7sbtTVbEYnIMzPFvz5PgGFdm4yWO242yTuBMD5eLvldCpfeHQFRmohTkjVKJtDbjybVA2o6Mc8LS2K8E0mWTdo/V/fyR2MM/ekBfBXwLFkRusxQSC+3lpoFyQM++95f3DkID4HUUJTGUuDTEUZOr1u98HLtDTkucrgnLkfbC2Kvj abatkin@alpha.batkin.net |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
call pathogen#infect() | |
syntax enable | |
filetype plugin indent on | |
set nocompatible | |
"if filereadable("$VIMRUNTIME/mswin.vim") | |
:so $VIMRUNTIME/mswin.vim | |
"endif | |
:behave mswin |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
alias ant='ant -logger org.apache.tools.ant.listener.AnsiColorLogger' | |
alias ll='ls --color=tty -lrt' | |
alias kde=". ~/kde/env.sh && cd ~/kde/src" | |
alias vi=vim |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export EDITOR=vim | |
export VISUAL=vim | |
export PAGER=less | |
# Also setup JAVA_HOME, ANT_HOME, PATH |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bindkey '^[[B' down-line-or-history | |
bindkey '^[[A' up-line-or-history |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
setopt nocorrectall | |
setopt correct |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
local return_code='%(?..%{$fg[red]%}%? ↵%{$reset_color%})' | |
local git_branch='$(git_prompt_status)%{$reset_color%}$(git_prompt_info)$(git_prompt_short_sha)' | |
ZSH_THEME_GIT_PROMPT_SHA_BEFORE=" %{$fg[red]%}(" | |
ZSH_THEME_GIT_PROMPT_SHA_AFTER=")%{$reset_color%}" | |
ZSH_THEME_GIT_PROMPT_PREFIX="%{$fg[green]%}" | |
ZSH_THEME_GIT_PROMPT_SUFFIX="%{$reset_color%}" | |
ZSH_THEME_GIT_PROMPT_DIRTY="" | |
ZSH_THEME_GIT_PROMPT_CLEAN="" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Path to your oh-my-zsh configuration. | |
ZSH=$HOME/.oh-my-zsh | |
# Set name of the theme to load. | |
# Look in ~/.oh-my-zsh/themes/ | |
# Optionally, if you set this to "random", it'll load a random theme each | |
# time that oh-my-zsh is loaded. | |
ZSH_THEME="adambatkin" | |
# Example aliases |