--- a/.gitconfig Thu Jan 13 00:02:40 2011 -0500
+++ b/.gitconfig Thu Jan 13 00:02:54 2011 -0500
@@ -10,6 +10,8 @@
gl = log -10 --color=always --all --graph --topo-order --pretty='format: %Cgreen%h%Creset %s%Cred%d%Creset%n'
gll = log --color=always --all --graph --topo-order --pretty='format: %Cgreen%h%Creset %s%Cred%d%Creset%n'
+pull = pull --ff-only
+
com = commit
cm = commit -m
--- a/.hgignore Thu Jan 13 00:02:40 2011 -0500
+++ b/.hgignore Thu Jan 13 00:02:54 2011 -0500
@@ -15,3 +15,5 @@
mutt/temp
mutt/cache
vim/spell
+fishd*
+fish_history
--- a/.hgrc Thu Jan 13 00:02:40 2011 -0500
+++ b/.hgrc Thu Jan 13 00:02:54 2011 -0500
@@ -54,10 +54,6 @@
opts.dd =
[merge-tools]
-diffuse.priority=-3
-diffuse.args=$local $base $other
-diffuse.gui=True
-diffuse.diffargs=$parent $child
[email]
method = smtp
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/config/fish/config.fish Thu Jan 13 00:02:54 2011 -0500
@@ -0,0 +1,53 @@
+set tacklebox_path ~/lib/tacklebox
+set tacklebox_theme prose
+set tacklebox_plugins directories python django misc web osx
+
+. $tacklebox_path/tacklebox.fish
+
+# Useful aliases -------------------------------------------------------------
+alias j 'z'
+alias fab 'fab -i ~/.ssh/stevelosh'
+alias oldgcc 'set -g CC /usr/bin/gcc-4.0'
+alias tm 'tmux -u2'
+alias c 'clear'
+alias M 'mvim .'
+
+# Environment variables ------------------------------------------------------
+set -g EDITOR vim
+set -g PATH "$HOME/.gem/ruby/1.8/bin:$PATH"
+set -g PATH "/usr/local/bin:/usr/local/sbin:$HOME/bin:/opt/local/bin:$PATH"
+set -g PATH "/opt/subversion/bin:$PATH"
+set -g COMMAND_MODE unix2003
+set -g RUBYOPT rubygems
+set -g CLASSPATH "$CLASSPATH:/usr/local/Cellar/clojure-contrib/1.2.0/clojure-contrib.jar"
+
+# Python variables -----------------------------------------------------------
+set -g PIP_DOWNLOAD_CACHE "$HOME/.pip/cache"
+set -g PYTHONSTARTUP "$HOME/.pythonrc.py"
+set -g WORKON_HOME "$HOME/lib/virtualenvs"
+
+set -g PATH "$PATH:/usr/local/Cellar/PyPi/3.6/bin"
+set -g PATH "$PATH:/usr/local/Cellar/python/2.7.1/bin"
+set -g PATH "$PATH:/usr/local/Cellar/python/2.7/bin"
+set -g PATH "$PATH:/usr/local/Cellar/python/2.6.5/bin"
+
+set -g PYTHONPATH "$PYTHONPATH:/usr/local/lib/python2.7.1/site-packages"
+set -g PYTHONPATH "$PYTHONPATH:/usr/local/lib/python2.7/site-packages"
+set -g PYTHONPATH "$PYTHONPATH:/usr/local/lib/python2.6/site-packages"
+set -g PYTHONPATH "$HOME/lib/python/see:$PYTHONPATH"
+
+# Mercurial variables --------------------------------------------------------
+set -g PATH="$HOME/lib/hg/hg-stable:$PATH"
+set -g PYTHONPATH="$HOME/lib/hg/hg-stable:$PYTHONPATH"
+
+# Extra ----------------------------------------------------------------------
+. ~/src/z-fish/z.sh
+
+# Local Settings -------------------------------------------------------------
+if test -s $HOME/.config/fish/local.fish
+ source $HOME/.config/fish/local.fish
+end
+
+function z_add --on-event prompt
+ z --add "$PWD"
+end
--- a/config/pianobar/config Thu Jan 13 00:02:40 2011 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,4 +0,0 @@
-user = steve@stevelosh.com
-history = 10
-audio_format = aacplus
-download_dir = /Users/sjl/Desktop
--- a/vim/.vimrc Thu Jan 13 00:02:40 2011 -0500
+++ b/vim/.vimrc Thu Jan 13 00:02:54 2011 -0500
@@ -113,7 +113,6 @@
set foldlevelstart=0
nnoremap <Space> za
vnoremap <Space> za
-noremap <leader>ft Vatzf
function! MyFoldText()
let line = getline(v:foldstart)
@@ -135,27 +134,44 @@
" Fuck you, help key.
set fuoptions=maxvert,maxhorz
inoremap <F1> <ESC>:set invfullscreen<CR>a
-nnoremap <F1> :set invfullscreen<CR>
-vnoremap <F1> :set invfullscreen<CR>
+noremap <F1> :set invfullscreen<CR>
" Fuck you too, manual key
nnoremap K <nop>
-" Various syntax stuff
-au BufNewFile,BufRead *.less set filetype=less
-au BufRead,BufNewFile *.scss set filetype=scss
+" Various filetype-specific stuff
+
+au BufNewFile,BufRead *.html setlocal filetype=htmldjango
+au BufNewFile,BufRead *.html setlocal foldmethod=manual
+au BufNewFile,BufRead *.html nnoremap <buffer> <localleader>f Vatzf
-au BufRead,BufNewFile *.confluencewiki set filetype=confluencewiki
-au BufRead,BufNewFile *.confluencewiki set wrap linebreak nolist
+au BufNewFile,BufRead *.less setlocal filetype=less
+au BufNewFile,BufRead *.less setlocal foldmethod=marker
+au BufNewFile,BufRead *.less setlocal foldmarker={,}
+au BufNewFile,BufRead *.less setlocal nocursorline
+
+au BufNewFile,BufRead *.js setlocal foldmethod=marker
+au BufNewFile,BufRead *.js setlocal foldmarker={,}
+
+au BufRead,BufNewFile *.confluencewiki setlocal filetype=confluencewiki
+au BufRead,BufNewFile *.confluencewiki setlocal wrap linebreak nolist
+
+au BufNewFile,BufRead *.fish set filetype=fish
au BufNewFile,BufRead *.m*down set filetype=markdown
-au BufNewFile,BufRead *.m*down nnoremap <leader>1 yypVr=
-au BufNewFile,BufRead *.m*down nnoremap <leader>2 yypVr-
-au BufNewFile,BufRead *.m*down nnoremap <leader>3 I### <ESC>
+au BufNewFile,BufRead *.m*down nnoremap <localleader>1 yypVr=
+au BufNewFile,BufRead *.m*down nnoremap <localleader>2 yypVr-
+au BufNewFile,BufRead *.m*down nnoremap <localleader>3 I### <ESC>
+
+au BufNewFile,BufRead *.vim setlocal foldmethod=marker
-au BufNewFile,BufRead *.vim set foldmethod=marker
+au BufNewFile,BufRead urls.py setlocal nowrap
+au BufNewFile,BufRead settings.py normal! zR
+au BufNewFile,BufRead dashboard.py normal! zR
-au BufNewFile,BufRead urls.py set nowrap
+au BufRead,BufNewFile /etc/nginx/conf/* set ft=nginx
+au BufRead,BufNewFile /etc/nginx/sites-available/* set ft=nginx
+au BufRead,BufNewFile /usr/local/etc/nginx/sites-available/* set ft=nginx
autocmd FileType clojure call TurnOnClojureFolding()
@@ -181,23 +197,9 @@
au BufNewFile,BufRead *.js set errorformat=%-P-----\ FILE\ \ :\ \ %f\ -----,Line\ %l\\,\ E:%n:\ %m,%-Q,%-GFound\ %s,%-GSome\ %s,%-Gfixjsstyle%s,%-Gscript\ can\ %s,%-G
" TESTING GOAT APPROVES OF THESE LINES
-au BufNewFile,BufRead test_*.py set makeprg=nosetests\ --machine-out\ --nocapture
-au BufNewFile,BufRead test_*.py set shellpipe=2>&1\ >/dev/null\ \|\ tee
-au BufNewFile,BufRead test_*.py set errorformat=%f:%l:\ %m
-au BufNewFile,BufRead test_*.py nmap <Leader>N :make<cr>
nmap <leader>fn :cn<cr>
nmap <leader>fp :cp<cr>
-" TODO: Put this in filetype-specific files
-au BufNewFile,BufRead *.less set foldmethod=marker
-au BufNewFile,BufRead *.less set foldmarker={,}
-au BufNewFile,BufRead *.less set nocursorline
-au BufRead,BufNewFile /etc/nginx/conf/* set ft=nginx
-au BufRead,BufNewFile /etc/nginx/sites-available/* set ft=nginx
-au BufRead,BufNewFile /usr/local/etc/nginx/sites-available/* set ft=nginx
-au BufNewFile,BufRead *.js set foldmethod=marker
-au BufNewFile,BufRead *.js set foldmarker={,}
-
" Easier linewise reselection
map <leader>v V`]
@@ -219,9 +221,6 @@
nnoremap Vit vitVkoj
nnoremap Vat vatV
-" Diff
-nmap <leader>d :!hg diff %<cr>
-
" Rainbows!
nmap <leader>R :RainbowParenthesesToggle<CR>
@@ -383,6 +382,56 @@
omap <silent> i∑ <Plug>CamelCaseMotion_iw
xmap <silent> i∑ <Plug>CamelCaseMotion_iw
+" Diff
+let g:HgDiffing = 0
+function! s:HgDiffCurrentFile()
+ if g:HgDiffing == 1
+ if bufwinnr(bufnr('__HGDIFF__')) != -1
+ exe bufwinnr(bufnr('__HGDIFF__')) . "wincmd w"
+ bdelete
+ endif
+
+ diffoff!
+
+ let g:HgDiffing = 0
+
+ return
+ endif
+
+ let fname = bufname('%')
+ let ftype = &ft
+ diffthis
+
+ vnew __HGDIFF__
+
+ setlocal buftype=nofile
+ setlocal bufhidden=hide
+ setlocal noswapfile
+ setlocal nobuflisted
+ exec 'setlocal filetype='.ftype
+
+ setlocal modifiable
+
+ silent normal! ggdG
+ silent exec ':r!hg cat ' . fname
+ silent normal! ggdd
+
+ setlocal nomodifiable
+
+ diffthis
+
+ wincmd l
+
+ let g:HgDiffing = 1
+
+ return
+endfunction
+
+command! HgDiffCurrent call s:HgDiffCurrentFile()
+
+nmap <leader>d :HgDiffCurrent<cr>
+
+" MacVim
if has('gui_running')
set guifont=Menlo:h12
@@ -400,6 +449,9 @@
let g:sparkupExecuteMapping = '<D-e>'
highlight SpellBad term=underline gui=undercurl guisp=Orange
+
+ inoremenu <silent>&Plugin.QuickCursor.CloseBuffer <Esc>:w<cr>:BufClose<cr>
+ nnoremenu <silent>&Plugin.QuickCursor.CloseBuffer :w<cr>:BufClose<cr>
else
set nocursorline
endif
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/vim/plugin/BufClose.vim Thu Jan 13 00:02:54 2011 -0500
@@ -0,0 +1,98 @@
+" BufClose.vim - Close a buffer without closing the window it's in.
+"
+" Copyright February 2003 by Christian J. Robinson <infynity@onewest.net>
+"
+" Distributed under the terms of the Vim license. See ":help license".
+
+" Usage:
+"
+" :BufClose[!] [buffer]
+"
+" Without any arguments the current buffer in the current window is closed.
+" With an argument that buffer is closed if it exists and is currently being
+" displayed in a window.
+"
+" The buffer argument can be a buffer name or number.
+"
+" In both cases if the buffer is modified you have to use ! or an error will
+" be issued and the buffer will be left loaded.
+"
+" Configuration:
+"
+" g:BufClose_AltBuffer
+"
+" Set this variable if you don't want a blank buffer to be loaded in place of
+" the buffer being closed. Examples:
+"
+" :let g:BufClose_AltBuffer = '#'
+"
+" This will cause :BufClose to load the alternate buffer. See ":help :_#".
+"
+" :let g:BufClose_AltBuffer = '.'
+"
+" This will cause :BufClose to load the current directory in the file
+" explorer.
+
+command! -nargs=? -complete=buffer -bang BufClose
+ \ :call BufClose(expand('<args>'), expand('<bang>'))
+
+function! BufClose(buffer, bang)
+ if a:buffer == ''
+ " No buffer provided, use current buffer in the current window.
+ let buffer = bufnr('%')
+ elseif (a:buffer + 0) > 0
+ " A buffer number was provided.
+ let buffer = bufnr(a:buffer + 0)
+ else
+ " A buffer name was provided.
+ let buffer = bufnr(a:buffer)
+ endif
+
+ if buffer == -1
+ echohl ErrorMsg
+ echomsg "No matching buffer for" a:buffer
+ echohl None
+ return
+ endif
+
+ let current_window = winnr()
+ let buffer_window = bufwinnr(buffer)
+
+ if buffer_window == -1
+ echohl ErrorMsg
+ echomsg "Buffer" buffer "isn't open in any windows."
+ echohl None
+ return
+ endif
+
+ if a:bang == '' && getbufvar(buffer, '&modified')
+ echohl ErrorMsg
+ echomsg 'No write since last change for buffer'
+ \ buffer '(add ! to override)'
+ echohl None
+ return
+ endif
+
+ " Move to the proper window if necessary, open a blank buffer,
+ " then move back to the original window...
+ if buffer_window >= 0
+ if current_window == buffer_window
+ if exists('g:BufClose_AltBuffer')
+ exe 'e' . a:bang . ' ' . g:BufClose_AltBuffer
+ else
+ exe 'enew' . a:bang
+ endif
+ else
+ exe 'norm ' . buffer_window . "\<C-w>w"
+ if exists('g:BufClose_AltBuffer')
+ exe 'e' . a:bang . ' ' . g:BufClose_AltBuffer
+ else
+ exe 'enew' . a:bang
+ endif
+ exe 'norm ' . current_window . "\<C-w>w"
+ endif
+ endif
+
+ " ...and delete the specified buffer.
+ silent exe 'bdel' . a:bang . ' ' . buffer
+endfunction
--- a/vim/snippets/javascript.snippets Thu Jan 13 00:02:40 2011 -0500
+++ b/vim/snippets/javascript.snippets Thu Jan 13 00:02:54 2011 -0500
@@ -72,3 +72,5 @@
# Get Element
snippet gett
getElementBy${1:Id}('${2}')${3}
+snippet log
+ console.log(${1});${2}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/vim/syntax/fish.vim Thu Jan 13 00:02:54 2011 -0500
@@ -0,0 +1,138 @@
+" Vim syntax file
+" Language: fish
+" Maintainer: yann monclair <yann@monclair.info>
+" Heavily based on zsh.vim by Felix von Leitner
+" there is still much work to be done, this is just a start, it should get
+" better with time
+" Url: http://monclair.info/~yann/vim
+" Last Change: 2005/11/08
+
+
+
+" For version 5.x: Clear all syntax items
+" For version 6.x: Quit when a syntax file was already loaded
+if version < 600
+ syntax clear
+elseif exists("b:current_syntax")
+ finish
+endif
+
+" String and Character contstants
+" Highlight special characters (those which have a backslash) differently
+syn match fishSpecial "\\\d\d\d\|\\[abcfnrtv\\']"
+syn region fishSinglequote start=+'+ skip=+\\'+ end=+'+
+" A bunch of useful fish keywords
+syn keyword fishFunction function
+syn keyword fishStatement . and bg begin bind break builtin
+syn keyword fishStatement case cd command commandline complete continue count
+syn keyword fishStatement dirh dirs end else eval exec exit
+syn keyword fishStatement fg fishd for function functions
+syn keyword fishStatement help if jobs mimedb nextd not or
+syn keyword fishStatement popd prevd pushd random return read
+syn keyword fishStatement set set_color switch tokenize
+syn keyword fishStatement ulimit umask while
+syn keyword fishInputrc backward-char backward-delete-char backward-kill-line backward-kill-word backward-word
+syn keyword fishInputrc beginning-of-history beginning-of-line complete delete-char delete-line
+syn keyword fishInputrc explain forward-char forward-word history-search-backward history-search-forward
+syn keyword fishInputrc kill-line kill-whole-line kill-word yank yank-pop
+
+syn keyword fishConditional if else case then in
+syn keyword fishRepeat while for done
+
+
+" Following is worth to notice: command substitution, file redirection and functions (so these features turns red)
+syn match fishFunctionName "\h\w*\s*()"
+syn region fishshCommandSub start=+(+ end=+)+ contains=ALLBUT,fishFunction
+syn match fishRedir "\d\=\(<\|<<\|>\|>>\)\(|\|&\d\)\="
+
+syn keyword fishColors black red green brown yellow blue magenta purple cyan white normal
+
+syn keyword fishSpecialCommands fish_on_exit fish_on_exec fish_on_return
+
+syn keyword fishTodo contained TODO
+
+syn keyword fishVariables fish_prompt fish_title history status _ umask
+syn keyword fishShellVariables USER LOGNAME HOME PATH CDPATH SHELL BROWSER
+syn keyword fishVariables fish_color_normal fish_color_command fish_color_substitution fish_color_redirection fish_color_end fish_color_error fish_color_param fish_color_comment fish_color_match fish_color_search_match fish_color_cwd fish_pager_color_prefix fish_pager_color_completion fish_pager_color_description fish_pager_color_progress
+
+"syn keyword fishShellVariables LC_TYPE LC_MESSAGE MAIL MAILCHECK
+"syn keyword fishShellVariables PS1 PS2 IFS EGID EUID ERRNO GID UID
+"syn keyword fishShellVariables HOST LINENO MACHTYPE OLDPWD OPTARG
+"syn keyword fishShellVariables OPTIND OSTYPE PPID PWD RANDOM SECONDS
+"syn keyword fishShellVariables SHLVL TTY signals TTYIDLE USERNAME
+"syn keyword fishShellVariables VENDOR fish_NAME fish_VERSION ARGV0
+"syn keyword fishShellVariables BAUD COLUMNS cdpath DIRSTACKSIZE
+"syn keyword fishShellVariables FCEDIT fignore fpath histchars HISTCHARS
+"syn keyword fishShellVariables HISTFILE HISTSIZE KEYTIMEOUT LANG
+"syn keyword fishShellVariables LC_ALL LC_COLLATE LC_CTYPE LC_MESSAGES
+"syn keyword fishShellVariables LC_TIME LINES LISTMAX LOGCHECK mailpath
+"syn keyword fishShellVariables MAILPATH MANPATH manpath module_path
+"syn keyword fishShellVariables MODULE_PATH NULLCMD path POSTEDIT
+"syn keyword fishShellVariables PS3 PS4 PROMPT PROMPT2 PROMPT3 PROMPT4
+"syn keyword fishShellVariables psvar PSVAR prompt READNULLCMD
+"syn keyword fishShellVariables REPORTTIME RPROMPT RPS1 SAVEHIST
+"syn keyword fishShellVariables SPROMPT STTY TIMEFMT TMOUT TMPPREFIX
+"syn keyword fishShellVariables watch WATCH WATCHFMT WORDCHARS ZDOTDIR
+syn match fishSpecialShellVar "\$[-#@*$?!0-9]"
+syn keyword fishSetVariables ignoreeof noclobber
+syn region fishDerefOpr start="\${" end="}" contains=fishShellVariables
+syn match fishDerefIdentifier "\$[a-zA-Z_][a-zA-Z0-9_]*\>"
+syn match fishOperator "[][}{&;|)(]"
+
+
+
+syn match fishNumber "-\=\<\d\+\>"
+syn match fishComment "#.*$" contains=fishNumber,fishTodo
+
+
+syn match fishTestOpr "-\<[oeaznlg][tfqet]\=\>\|!\==\|-\<[b-gkLprsStuwjxOG]\>"
+syn region fishTest start="\[" skip="\\$" end="\]" contains=fishString,fishTestOpr,fishDerefIdentifier,fishDerefOpr
+syn region fishString start=+"+ skip=+\\"+ end=+"+ contains=fishSpecial,fishOperator,fishDerefIdentifier,fishDerefOpr,fishSpecialShellVar,fishSinglequote,fishCommandSub
+
+syn region fishFunctions start=+function+ end=+end+ contains=fishShellVariables,fishRedir,fishCommandSub,fishVariables, fishConditional,fishRepeat,fishStatement
+
+" Define the default highlighting.
+" For version 5.7 and earlier: only when not done already
+" For version 5.8 and later: only when an item doesn't have highlighting yet
+if version >= 508 || !exists("did_fish_syntax_inits")
+ if version < 508
+ let did_fish_syntax_inits = 1
+ command -nargs=+ HiLink hi link <args>
+ else
+ command -nargs=+ HiLink hi def link <args>
+ endif
+
+ HiLink fishSinglequote fishString
+ HiLink fishConditional fishStatement
+ HiLink fishRepeat fishStatement
+ HiLink fishFunctionName fishFunction
+ HiLink fishFunctions fishFunction
+ HiLink fishCommandSub fishOperator
+ HiLink fishRedir fishOperator
+ HiLink fishSetVariables fishShellVariables
+ HiLink fishSpecialShellVar fishShellVariables
+ HiLink fishColors fishVariables
+ HiLink fishTestOpr fishOperator
+ HiLink fishDerefOpr fishSpecial
+ HiLink fishDerefIdentifier fishShellVariables
+ HiLink fishOperator Operator
+ HiLink fishStatement Statement
+ HiLink fishNumber Number
+ HiLink fishString String
+ HiLink fishComment Comment
+ HiLink fishSpecial Special
+ HiLink fishTodo Todo
+ HiLink fishShellVariables Special
+ hi fishOperator term=underline ctermfg=6 guifg=Purple gui=bold
+ " hi fishShellVariables term=underline ctermfg=2 guifg=SeaGreen gui=bold
+ " hi fishVariables term=underline ctermfg=5 guifg=Blue gui=bold
+ " hi fishFunction guifg=Red gui=bold
+ " hi fishFunctionName guifg=Blue gui=bold
+ "hi fishVariables ctermbg=3 guifg=Blue gui=bold
+
+ delcommand HiLink
+endif
+
+let b:current_syntax = "fish"
+
+" vim: ts=8