diff --git a/.gitignore b/.gitignore index 31c49e7..ea12c4f 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ -/janus/go +/janus/* +byobu/.ssh-agent diff --git a/.gitmodules b/.gitmodules index 87b7de7..e69de29 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,3 +0,0 @@ -[submodule "janus/aspen"] - path = janus/aspen - url = git://github.com/patcoll/aspen.vim.git diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 0000000..14f571b --- /dev/null +++ b/.travis.yml @@ -0,0 +1,4 @@ +--- +language: generic +sudo: false +script: make diff --git a/Makefile b/Makefile index 3e71321..0d594bf 100644 --- a/Makefile +++ b/Makefile @@ -1,21 +1,13 @@ -SOURCES := $(shell ls | egrep -v 'README|Makefile') +SOURCES := $(shell ls | grep -E -v 'README|Makefile') TARGETS := $(patsubst %,$(HOME)/.%,$(SOURCES)) - $(HOME)/.%: % - ln -sv $(PWD)/'$^' '$@' - - -all: $(TARGETS) $(HOME)/.janus/go + $(RM) '$@' && ln -svf '$(PWD)/$^' '$@' +.PHONY: all +all: $(TARGETS) +.PHONY: echo echo: @echo SOURCES=$(SOURCES) @echo TARGETS=$(TARGETS) - - -$(HOME)/.janus/go: - test -n "$$GOROOT" && ln -sv $$GOROOT/misc/vim ~/.janus/go ; true - - -.PHONY: all echo diff --git a/ackrc b/ackrc index 4c9eb88..e69de29 100644 --- a/ackrc +++ b/ackrc @@ -1 +0,0 @@ ---all-types diff --git a/bash_aliases b/bash_aliases index 024210f..0c43b11 100644 --- a/bash_aliases +++ b/bash_aliases @@ -17,6 +17,7 @@ alias s="cat $HOME/.ssh/config | grep '^Host ' | sed \"s/Host //\" | sort | uniq alias sS='TERM=xterm screen -Rd -S ' alias scr='TERM=xterm screen -Rd' alias sl="screen -ls" +alias tmux='TERM=xterm-256color tmux -2' case "$(uname | tr '[:upper:]' '[:lower:]')" in darwin) diff --git a/bash_profile b/bash_profile index dd89c14..144e7ff 100644 --- a/bash_profile +++ b/bash_profile @@ -70,9 +70,9 @@ _bash_profile_main() { get_ssh_agent which gpg-agent && test -d ~/.gnupg && get_gpg_agent - _source_if_exists "$HOME/.gvm/scripts/gvm" - _source_if_exists "$HOME/.gvmrc" - _source_if_exists "$HOME/src/gocode/src/.env" + #_source_if_exists "$HOME/.gvm/scripts/gvm" + #_source_if_exists "$HOME/.gvmrc" + #_source_if_exists "$HOME/src/gocode/src/.env" unset _get_hostname unset _source_host_specific_rcfile @@ -83,4 +83,7 @@ _bash_profile_main() { _bash_profile_main +# added by travis gem +[[ -f ~/.travis/travis.sh ]] && source ~/.travis/travis.sh + # vim:filetype=sh diff --git a/bashrc b/bashrc index b48afa3..21c5690 100644 --- a/bashrc +++ b/bashrc @@ -12,3 +12,9 @@ then fi # vim:filetype=sh + +### Added by the Heroku Toolbelt +export PATH="/usr/local/heroku/bin:$PATH" + +# added by travis gem +[ -f /Users/me/.travis/travis.sh ] && source /Users/me/.travis/travis.sh diff --git a/byobu/.tmux.conf b/byobu/.tmux.conf new file mode 100644 index 0000000..e69de29 diff --git a/byobu/color.tmux b/byobu/color.tmux new file mode 100644 index 0000000..a1e60dd --- /dev/null +++ b/byobu/color.tmux @@ -0,0 +1,5 @@ +BYOBU_DARK=black +BYOBU_LIGHT=white +BYOBU_ACCENT=magenta +BYOBU_HIGHLIGHT=red +MONOCHROME=0 \ No newline at end of file diff --git a/byobu/keybindings.tmux b/byobu/keybindings.tmux new file mode 100644 index 0000000..e69de29 diff --git a/byobu/prompt b/byobu/prompt new file mode 100644 index 0000000..c0a7eeb --- /dev/null +++ b/byobu/prompt @@ -0,0 +1 @@ +[ -r /usr/share/byobu/profiles/bashrc ] && . /usr/share/byobu/profiles/bashrc #byobu-prompt# diff --git a/gemrc b/gemrc index 4635fc5..882316e 100644 --- a/gemrc +++ b/gemrc @@ -1 +1 @@ -gem: --no-rdoc --ri +gem: --no-rdoc --no-ri diff --git a/git-global-ignores b/git-global-ignores index 0995b1d..1905e5c 100644 --- a/git-global-ignores +++ b/git-global-ignores @@ -5,3 +5,7 @@ tags TAGS *.rbc *.class +.vagrant +*.swp +.DS_Store +.~lock* diff --git a/gitconfig b/gitconfig index dccc496..6de28c9 100644 --- a/gitconfig +++ b/gitconfig @@ -1,80 +1,96 @@ [user] - name = Dan Buch - email = daniel.buch@gmail.com + name = Dan Buch + email = daniel.buch@gmail.com + +[github] + user = meatballhat [core] - excludesfile = ~/.git-global-ignores - autocrlf = false + excludesfile = ~/.git-global-ignores + editor = vim + filemode = true + autocrlf = false + pager = less -FRXx2 + +[clean] + requireForce = false + +[branch] + autosetuprebase = remote + autosetupmerge = true + mergeoptions = --no-commit --no-ff [daemon] - uploadpack = true - uploadarch = true - receivepack = true + uploadpack = true + uploadarch = true + receivepack = true [push] - default = matching + default = current [color] - ui = auto + ui = auto [color "branch"] - current = yellow reverse - local = yellow - remote = green + current = yellow reverse + local = yellow + remote = green [color "diff"] - meta = yellow bold - frag = magenta bold - old = red bold - new = green bold + meta = yellow bold + frag = magenta bold + old = red bold + new = green bold [color "status"] - added = yellow - changed = green - untracked = cyan + added = yellow + changed = green + untracked = cyan [alias] - a = add - ad = add - addd = add - br = branch - bra = branch -a - brr = branch -r - ci = commit - co = checkout - d = diff - dc = diff --cached - di = diff - dif = diff - l = ls-files - ls = ls-files - nuke = clean -dfx - pr = pull --rebase - s = status --short - st = status - sta = stash - stcq = diff --cached --name-only - stq = diff --name-only - t = tag - ta = tag - tags = tag - - slog = log git-svn.. - sup = svn fetch --all - spush = svn dcommit - srb = rebase git-svn - - cm = checkout master - lm = log master.. - - rt = rebase trunk - lt = log trunk.. - ct = checkout svn/trunk - - logv = log --name-status + a = add + ad = add + addd = add + br = branch + bra = branch -a + brr = branch -r + ci = commit + co = checkout + d = diff + dc = diff --cached + di = diff + dif = diff + l = ls-files + ls = ls-files + nuke = clean -dfx + pr = pull --rebase + s = status --short + st = status + sta = stash + stcq = diff --cached --name-only + stq = diff --name-only + t = tag + ta = tag + tags = tag + slog = log git-svn.. + sup = svn fetch --all + spush = svn dcommit + srb = rebase git-svn -[clean] - requireForce = false + rpo = remote prune origin + + cm = checkout master + lm = log master.. + + rt = rebase trunk + lt = log trunk.. + ct = checkout svn/trunk + + logv = log --name-status + hug = blame + lg = log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit -# vim:filetype=cfg +# vim: set filetype=cfg noexpandtab: +[commit] + template = /Users/me/.gittemplate diff --git a/gittemplate b/gittemplate new file mode 100644 index 0000000..8818fed --- /dev/null +++ b/gittemplate @@ -0,0 +1,11 @@ + + +# 50-character subject line +# +# 72-character wrapped longer description. This should answer: +# +# - Why was this change necessary? +# - How does it address the problem? +# - Are there any side effects? +# +# Include a link to the ticket, if any. diff --git a/janus/aspen b/janus/aspen deleted file mode 160000 index 7225b21..0000000 --- a/janus/aspen +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 7225b212474c2add040259114061ec1d9a7721d7 diff --git a/janus/protobuf/ftdetect/proto.vim b/janus/protobuf/ftdetect/proto.vim deleted file mode 100644 index 19c0d4c..0000000 --- a/janus/protobuf/ftdetect/proto.vim +++ /dev/null @@ -1,91 +0,0 @@ -" Protocol Buffers - Google's data interchange format -" Copyright 2008 Google Inc. -" -" Licensed under the Apache License, Version 2.0 (the "License"); -" you may not use this file except in compliance with the License. -" You may obtain a copy of the License at -" -" http:"www.apache.org/licenses/LICENSE-2.0 -" -" Unless required by applicable law or agreed to in writing, software -" distributed under the License is distributed on an "AS IS" BASIS, -" WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -" See the License for the specific language governing permissions and -" limitations under the License. - -" This is the Vim syntax file for Google Protocol Buffers. -" -" Usage: -" -" 1. cp proto.vim ~/.vim/syntax/ -" 2. Add the following to ~/.vimrc: -" -" augroup filetype -" au! BufRead,BufNewFile *.proto setfiletype proto -" augroup end -" -" Or just create a new file called ~/.vim/ftdetect/proto.vim with the -" previous lines on it. - -if version < 600 - syntax clear -elseif exists("b:current_syntax") - finish -endif - -syn case match - -syn keyword pbTodo contained TODO FIXME XXX -syn cluster pbCommentGrp contains=pbTodo - -syn keyword pbSyntax syntax import option -syn keyword pbStructure package message group -syn keyword pbRepeat optional required repeated -syn keyword pbDefault default -syn keyword pbExtend extend extensions to max -syn keyword pbRPC service rpc returns - -syn keyword pbType int32 int64 uint32 uint64 sint32 sint64 -syn keyword pbType fixed32 fixed64 sfixed32 sfixed64 -syn keyword pbType float double bool string bytes -syn keyword pbTypedef enum -syn keyword pbBool true false - -syn match pbInt /-\?\<\d\+\>/ -syn match pbInt /\<0[xX]\x+\>/ -syn match pbFloat /\<-\?\d*\(\.\d*\)\?/ -" TODO: .proto also supports C-style block comments; -" see /usr/share/vim/vim70/syntax/c.vim for how it's done. -syn region pbComment start="//" skip="\\$" end="$" keepend contains=@pbCommentGrp -syn region pbString start=/"/ skip=/\\"/ end=/"/ -syn region pbString start=/'/ skip=/\\'/ end=/'/ - -if version >= 508 || !exists("did_proto_syn_inits") - if version < 508 - let did_proto_syn_inits = 1 - command -nargs=+ HiLink hi link - else - command -nargs=+ HiLink hi def link - endif - - HiLink pbTodo Todo - - HiLink pbSyntax Include - HiLink pbStructure Structure - HiLink pbRepeat Repeat - HiLink pbDefault Keyword - HiLink pbExtend Keyword - HiLink pbRPC Keyword - HiLink pbType Type - HiLink pbTypedef Typedef - HiLink pbBool Boolean - - HiLink pbInt Number - HiLink pbFloat Float - HiLink pbComment Comment - HiLink pbString String - - delcommand HiLink -endif - -let b:current_syntax = "proto" diff --git a/janus/syntastic-syntax-checkers-scala.vim.patch b/janus/syntastic-syntax-checkers-scala.vim.patch deleted file mode 100644 index a819af5..0000000 --- a/janus/syntastic-syntax-checkers-scala.vim.patch +++ /dev/null @@ -1,42 +0,0 @@ -From 7a9d955c0141d4adb148ba0b128d302b82f2f307 Mon Sep 17 00:00:00 2001 -From: Spencer Deinum -Date: Thu, 30 Aug 2012 00:43:12 -0400 -Subject: [PATCH] Edited scala checker to use scalac, with the - -Ystop-after:refchecks option. - -This means syntax checking is done via the compiler instead of the -interpreter, so it won't choke on things like package definitions. - -The -Ystop-after:refchecks option will stop before code is actually -generated, so we don't emit any class files. - -Signed-off-by: Spencer Deinum ---- - syntax_checkers/scala.vim | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/syntax_checkers/scala.vim b/syntax_checkers/scala.vim -index f6f05af..d603246 100644 ---- a/syntax_checkers/scala.vim -+++ b/syntax_checkers/scala.vim -@@ -15,7 +15,7 @@ endif - let loaded_scala_syntax_checker = 1 - - "bail if the user doesnt have the scala binary installed --if !executable("scala") -+if !executable("scalac") - finish - endif - -@@ -24,7 +24,7 @@ if !exists("g:syntastic_scala_options") - endif - - function! SyntaxCheckers_scala_GetLocList() -- let makeprg = 'scala '. g:syntastic_scala_options .' '. shellescape(expand('%')) . ' /dev/null' -+ let makeprg = 'scalac -Ystop-after:refchecks '. g:syntastic_scala_options .' '. shellescape(expand('%')) - - let errorformat = '%f\:%l: %trror: %m' - --- -1.7.10 - diff --git a/meatballhat.zsh-theme b/meatballhat.zsh-theme new file mode 100644 index 0000000..283563e --- /dev/null +++ b/meatballhat.zsh-theme @@ -0,0 +1,7 @@ +local ret_status="%(?:%{$fg_bold[green]%}➜ :%{$fg_bold[red]%}➜ %s)" +PROMPT='$(date -u +%Y-%m-%dT%H:%M:%S) ${ret_status}%{$fg_bold[green]%}%p %{$fg[cyan]%}%c %{$fg_bold[blue]%}$(git_prompt_info)%{$fg_bold[blue]%} % %{$reset_color%}' + +ZSH_THEME_GIT_PROMPT_PREFIX="git:(%{$fg[red]%}" +ZSH_THEME_GIT_PROMPT_SUFFIX="%{$reset_color%}" +ZSH_THEME_GIT_PROMPT_DIRTY="%{$fg[blue]%}) %{$fg[yellow]%}🙀 %{$reset_color%}" +ZSH_THEME_GIT_PROMPT_CLEAN="%{$fg[blue]%})" diff --git a/tmux.conf b/tmux.conf index 5ac5965..4eb6cbf 100644 --- a/tmux.conf +++ b/tmux.conf @@ -1,8 +1,9 @@ # need me some vi mode setw -g mode-keys vi -set -g default-command /usr/bin/zsh -set -g default-shell /usr/bin/zsh +# note to self: learn ye a zsh +set -g default-command /bin/zsh +set -g default-shell /bin/zsh # copy-pasta in a vi-like way unbind [ @@ -23,3 +24,6 @@ set -s escape-time 0 # i forget easily set -g history-limit 100000 + +# colors! +set -g default-terminal 'screen-256color' diff --git a/todo.cfg b/todo.cfg index 10c89fe..ca65303 100644 --- a/todo.cfg +++ b/todo.cfg @@ -1,8 +1,7 @@ # === EDIT FILE LOCATIONS BELOW === # Your todo.txt directory -#export TODO_DIR="/Users/gina/Documents/todo" -export TODO_DIR="$HOME/Dropbox/buchfam/todo" +export TODO_DIR="$HOME/Dropbox/dan/todo" # Your todo/done/report.txt locations export TODO_FILE="$TODO_DIR/todo.txt" diff --git a/vimrc b/vimrc new file mode 100644 index 0000000..2f9d28c --- /dev/null +++ b/vimrc @@ -0,0 +1,27 @@ +syntax on + +filetype on +filetype indent on +filetype plugin on + +set backspace=indent,eol,start +set directory^=~/.vim/_temp// +set hlsearch +set ignorecase +set incsearch +set laststatus=2 +set nowrap +set number +set smartcase +set tabstop=4 +set textwidth=67 + +map ,t :w +map ,- :nohl +map ,w :%s/ *$// + +let g:go_fmt_command = "goimports" + +call pathogen#infect() + +colo summerfruit256 diff --git a/vimrc.after b/vimrc.after index 8384cb4..fe8d9bf 100644 --- a/vimrc.after +++ b/vimrc.after @@ -4,7 +4,7 @@ set tabstop=4 set shiftwidth=4 set softtabstop=4 -map ,t :w +autocmd FileType * map ,t :w map ,m :w\|:make map ,- :nohl @@ -13,12 +13,30 @@ autocmd BufNew,BufRead *.feature,*.rb,*.ru,*.xml,*.html,*.htm,Gemfile,Rakefile,P \| set tabstop=2 \| set softtabstop=2 +autocmd FileType ruby set shiftwidth=2 + \| set tabstop=2 + \| set softtabstop=2 + \| map ,t :RuboCop:w + +autocmd FileType ruby map ,r :RuboCop + +autocmd BufNew,BufRead *.ino,*.pde setf arduino + +autocmd FileType arduino set tabstop=4 + \| set softtabstop=4 + \| let g:syntastic_cpp_check_header=0 + \| map ,t :w:execute '!astyle' shellescape(expand('%'), 1):e:make + " Set up some sane java compilation bits autocmd BufNew,BufRead *.java set efm=%A\ %#[javac]\ %f:%l:\ %m,%-Z\ %#[javac]\ %p^,%-C%.%# \| set makeprg=ant\ -find\ build.xml -" remap ',t' in Go buffers to do :Fmt first -autocmd BufNew,BufRead *.go map ,t :Fmt:w +" never expand tabs (multiline-strings) and remap ',t' to do :Fmt first in Go +autocmd FileType go set noexpandtab + \| map ,t :Fmt:w + +" add color column for a few file types +autocmd FileType go,python,ruby set colorcolumn=80 " highlighting sbt as scala, too autocmd BufNew,BufRead *.sbt set syn=scala @@ -39,7 +57,7 @@ endfunction " MyNext() and MyPrev(): Movement between tabs OR buffers function! MyNext() - if exists( '*tabpagenr' ) && tabpagenr('$') != 1 + if exists('*tabpagenr') && tabpagenr('$') != 1 " Tab support && tabs open normal gt else @@ -48,7 +66,7 @@ function! MyNext() endif endfunction function! MyPrev() - if exists( '*tabpagenr' ) && tabpagenr('$') != '1' + if exists('*tabpagenr') && tabpagenr('$') != '1' " Tab support && tabs open normal gT else @@ -61,6 +79,9 @@ endfunction nnoremap L :call MyNext() nnoremap H :call MyPrev() +" astyle the whole thing +map ,a :execute '!astyle' shellescape(expand('%'), 1):e + " easy indentation in visual mode " This keeps the visual selection active after indenting. " Usually the visual selection is lost after you indent it. @@ -92,6 +113,7 @@ endfun " call it right away for certain files autocmd FileType python call LambastOver80Wide() autocmd FileType moin call LambastOver80Wide() +" autocmd FileType go call LambastOver80Wide() " autocmd FileType javascript call LambastOver80Wide() " autocmd FileType actionscript call LambastOver80Wide() autocmd FileType mail call LambastOver80Wide() @@ -120,7 +142,7 @@ if !has('gui_running') set t_Co=256 "colorscheme gardener "colorscheme inkpot - colorscheme delek + colorscheme molokai endif let g:valgrind_arguments='--leak-check=yes --num-callers=50' diff --git a/xinitrc b/xinitrc deleted file mode 100644 index 5197462..0000000 --- a/xinitrc +++ /dev/null @@ -1,36 +0,0 @@ -test -f /etc/rc.conf && source /etc/rc.conf -setxkbmap ${KEYMAP-dvorak} - - -DEFAULT="ratpoison" - - -case "$1" in - awe*) - exec awesome - ;; - evil*) - exec evilwm - ;; - open*) - exec openbox-session - ;; - win*) - exec wmaker - ;; - flux*) - exec startfluxbox - ;; - gno*) - exec gnome-session - ;; - rat*) - exec ratpoison - ;; - *) - exec $DEFAULT - ;; -esac - - -# vim:filetype=sh diff --git a/zshrc b/zshrc index 480edbc..aecce74 100644 --- a/zshrc +++ b/zshrc @@ -1,13 +1,125 @@ -HISTFILE=~/.zsh-histfile -HISTSIZE=10000 -SAVEHIST=100000 -setopt appendhistory extendedglob nomatch -unsetopt autocd beep notify -bindkey -v -autoload -Uz compinit -compinit - -export PS1="\$ " -function precmd() { - echo "$USER@$HOST:$(truncpwd)" +ZSH=$HOME/.oh-my-zsh +ZSH_THEME=meatballhat + +CASE_SENSITIVE="true" + +# Comment this out to disable bi-weekly auto-update checks +# DISABLE_AUTO_UPDATE="true" + +# Uncomment to change how often before auto-updates occur? (in days) +export UPDATE_ZSH_DAYS=3 + +# Uncomment following line if you want to disable colors in ls +# DISABLE_LS_COLORS="true" + +# Uncomment following line if you want to disable autosetting terminal title. +DISABLE_AUTO_TITLE="true" + +# Uncomment following line if you want to disable command autocorrection +DISABLE_CORRECTION="true" + +# Uncomment following line if you want red dots to be displayed while waiting +# for completion +COMPLETION_WAITING_DOTS="true" + +# Uncomment following line if you want to disable marking untracked files under +# VCS as dirty. This makes repository status check for large repositories much, +# much faster. +# DISABLE_UNTRACKED_FILES_DIRTY="true" + +plugins=( + autoenv + aws + bundler + cabal + command-not-found + cp + docker + gem + git + git-hubflow + golang + heroku + hk + knife + osx + pip + postgres + python + rails + rake-fast + rbenv + redis-cli + rsync + ruby + tmux + vagrant + vi-mode +) + +fpath=(/usr/local/share/zsh/site-functions $fpath) + +source $ZSH/oh-my-zsh.sh + +unalias gb + +# The completion for aws is not compatible with $fpath :scream_cat: +if [[ -f /usr/local/share/zsh/site-functions/_aws ]] ; then + source /usr/local/share/zsh/site-functions/_aws +fi + +unsetopt correct_all +bindkey '^R' history-incremental-search-backward + +path=( + $HOME/bin + $HOME/gopath/bin + $HOME/.rbenv/bin + $HOME/.rbenv/shims + $HOME/.phpenv/bin + /usr/local/sbin + /usr/local/bin + /usr/sbin + /usr/bin + /sbin + /bin + /usr/games + /usr/local/games +) + +if which pyenv > /dev/null ; then + eval "$(pyenv init -)" +fi +export PYENV_ROOT='/usr/local/var/pyenv' + +eval "$(phpenv init -)" + +eval "$(gimme 1.4.2)" 2>/dev/null +export GOPATH="$HOME/gopath" + +CDPATH="$HOME/workspace:$HOME/src:$HOME/Development/src:$HOME/repos" +for prefix in github.com github.com/travis-ci github.com/meatballhat code.google.com/p ; do + CDPATH="$HOME/gopath/src/$prefix:$CDPATH" +done + +export GPG_TTY=$(tty) + +source ~/.bash_aliases + +function dump-ssh-agent() { + env | awk '/SSH/ { + sub(/=/, "=\"", $1) + sub(/$/, "\"", $1) + print "export " $1 + }' | tee ~/.ssh/agent.out +} + +function load-ssh-agent() { + source ~/.ssh/agent.out } + +[[ -e ~/.zshenv ]] && source ~/.zshenv + +[ -f ~/.travis/travis.sh ] && source ~/.travis/travis.sh +[ -f ~/google-cloud-sdk/path.zsh.inc ] && source ~/google-cloud-sdk/path.zsh.inc +[ -f ~/google-cloud-sdk/completion.zsh.inc ] && source ~/google-cloud-sdk/completion.zsh.inc