Merge remote-tracking branch 'origin/master'
This commit is contained in:
commit
fc777ac549
10 changed files with 99 additions and 27 deletions
5
.gitignore
vendored
5
.gitignore
vendored
|
@ -1,2 +1,7 @@
|
|||
.DS_Store
|
||||
|
||||
zsh/cache/
|
||||
vim/view/
|
||||
vim/spelling*
|
||||
|
||||
irssi/away.log
|
||||
|
|
|
@ -60,8 +60,6 @@
|
|||
prompt = false
|
||||
[difftool]
|
||||
prompt = false
|
||||
[difftool "Kaleidoscope"]
|
||||
cmd = ksdiff --partial-changeset --relative-path \"$MERGED\" -- \"$LOCAL\" \"$REMOTE\"
|
||||
[mergetool "Kaleidoscope"]
|
||||
cmd = ksdiff --merge --output \"$MERGED\" --base \"$BASE\" -- \"$LOCAL\" --snapshot \"$REMOTE\" --snapshot
|
||||
trustExitCode = true
|
||||
|
|
4
gvimrc
4
gvimrc
|
@ -5,7 +5,7 @@ if has('win32') || has('win64') || has('win32unix')
|
|||
set guifont=Inconsolata:h18
|
||||
elseif has('mac')
|
||||
try
|
||||
set guifont=Source\ Code\ Pro:h13
|
||||
set guifont=Source\ Code\ Pro\ Light:h13
|
||||
catch
|
||||
set guifont=Menlo:h11
|
||||
endtry
|
||||
|
@ -15,3 +15,5 @@ endif
|
|||
|
||||
set guioptions-=T " turn off toolbar
|
||||
set guioptions-=m " turn off menubar
|
||||
|
||||
call togglebg#map("<F10>")
|
||||
|
|
|
@ -118,7 +118,7 @@ abstracts = {
|
|||
##
|
||||
|
||||
# the basic styling of how to print message, $0 = nick mode, $1 = nick
|
||||
msgnick = "%K<%n$0$1-%K>%n %|";
|
||||
msgnick = " %n$0$1-%k>%n %|";
|
||||
|
||||
# message from you is printed. "msgownnick" specifies the styling of the
|
||||
# nick ($0 part in msgnick) and "ownmsgnick" specifies the styling of the
|
||||
|
@ -250,7 +250,7 @@ abstracts = {
|
|||
|
||||
# default background for all statusbars. You can also give
|
||||
# the default foreground color for statusbar items.
|
||||
sb_background = "%4%w";
|
||||
sb_background = "%n%0";
|
||||
|
||||
# default backround for "default" statusbar group
|
||||
#sb_default_bg = "%4";
|
||||
|
@ -266,14 +266,14 @@ abstracts = {
|
|||
sbstart = "";
|
||||
# text at the end of statusbars. Use space so that it's never
|
||||
# used for anything.
|
||||
sbend = " ";
|
||||
sbend = "";
|
||||
|
||||
topicsbstart = "{sbstart $*}";
|
||||
topicsbend = "{sbend $*}";
|
||||
|
||||
prompt = "[$*] ";
|
||||
prompt = "[%n$*] ";
|
||||
|
||||
sb = " %c[%n$*%c]%n";
|
||||
sb = "%c[%n$*%c]%n ";
|
||||
sbmode = "(%c+%n$*)";
|
||||
sbaway = " (%GzZzZ%n)";
|
||||
sbservertag = ":$0 (change with ^X)";
|
||||
|
@ -286,9 +286,9 @@ abstracts = {
|
|||
# normal text
|
||||
sb_act_text = "%c$*";
|
||||
# public message
|
||||
sb_act_msg = "%W$*";
|
||||
sb_act_msg = "%w$*";
|
||||
# hilight
|
||||
sb_act_hilight = "%M$*";
|
||||
sb_act_hilight = "%m$*";
|
||||
# hilight with specified color, $0 = color, $1 = text
|
||||
sb_act_hilight_color = "$0$1-%n";
|
||||
};
|
||||
|
|
11
rc
11
rc
|
@ -10,7 +10,6 @@ print_info -l 2 'Creating aliases'
|
|||
alias h='history'
|
||||
alias df='df -h'
|
||||
alias du='du -h'
|
||||
alias g='git'
|
||||
alias v='vim'
|
||||
|
||||
binary_exists ledger && alias l='ledger'
|
||||
|
@ -27,6 +26,16 @@ alias addkey="ssh-agent ~/.ssh/id_rsa"
|
|||
alias pprint="python -c 'import sys,pprint; pprint.pprint(eval(sys.stdin.read()))'"
|
||||
alias pprint-json="python -c 'import sys,json;print json.dumps(json.load(sys.stdin), indent=2)'"
|
||||
|
||||
function g
|
||||
{
|
||||
if [[ $# -gt 0 ]]; then
|
||||
git $@
|
||||
else
|
||||
git status --short --branch
|
||||
fi
|
||||
return $?
|
||||
}
|
||||
|
||||
|
||||
print_info -l 2 "Sourcing ${SYS}-specific settings"
|
||||
case $SYS in
|
||||
|
|
22
tmux.conf
22
tmux.conf
|
@ -22,20 +22,32 @@ set -g mode-keys vi
|
|||
set -g repeat-time 0
|
||||
|
||||
# No left status; right status bar is session name
|
||||
set -g status-bg green
|
||||
set -g status-bg black
|
||||
set -g status-left ""
|
||||
set -g status-left-bg black
|
||||
set -g status-left-fg brightblue
|
||||
set -g status-left-attr none
|
||||
|
||||
set -g status-right "| #S "
|
||||
set -g status-right-bg black
|
||||
set -g status-right-fg brightblue
|
||||
set -g status-right-attr none
|
||||
|
||||
# Start window and pane indexing from 1 instead of 0
|
||||
set-option -g base-index 1
|
||||
set-option -g pane-base-index 1
|
||||
|
||||
# Tabs like this: " <index>:<window_name>(<pane_number>) "
|
||||
setw -g window-status-format " #I:#W(#P) "
|
||||
setw -g window-status-current-bg yellow
|
||||
setw -g window-status-current-format " #I:#W(#P) "
|
||||
# Tabs like this: "(<index>:<window_name>)"
|
||||
setw -g window-status-bg black
|
||||
setw -g window-status-fg brightgreen
|
||||
setw -g window-status-format "(#I:#W)"
|
||||
setw -g window-status-current-bg black
|
||||
setw -g window-status-current-fg yellow
|
||||
setw -g window-status-current-format "(#I:#W)"
|
||||
|
||||
setw -g window-status-bell-fg red
|
||||
setw -g window-status-content-fg brightred
|
||||
setw -g window-status-activity-fg brightred
|
||||
|
||||
setw -g alternate-screen on
|
||||
|
||||
|
|
17
vimrc
17
vimrc
|
@ -126,8 +126,6 @@ endif
|
|||
|
||||
set bg=dark
|
||||
|
||||
call togglebg#map("<F10>")
|
||||
|
||||
" use solarized colorscheme if the terminal can support it (or we're in a GUI)
|
||||
let g:solarized_termtrans = 1
|
||||
let g:solarized_visibility = 'low'
|
||||
|
@ -163,6 +161,11 @@ nnoremap <C-j> <C-w>j
|
|||
nnoremap <C-k> <C-w>k
|
||||
nnoremap <C-l> <C-w>l
|
||||
|
||||
" Usual EMACS (oh the horror!) begin-line and end-line keys for first and last
|
||||
" buffer.
|
||||
"nnoremap <silent> <C-a> :bfirst<CR>
|
||||
"nnoremap <silent> <C-e> :blast<CR>
|
||||
" Move between buffers with <C-n> and <C-p>
|
||||
nnoremap <silent> <C-n> :bn<CR>
|
||||
nnoremap <silent> <C-p> :bp<CR>
|
||||
|
||||
|
@ -180,6 +183,7 @@ function! <SID>strip_trailing_whitespace()
|
|||
call cursor(l, c)
|
||||
endfunction
|
||||
|
||||
|
||||
function! <SID>FindProjectFileOrDirectory(fod)
|
||||
let l:dir = getcwd()
|
||||
" Search up the path, starting at the current working directory, for the
|
||||
|
@ -194,14 +198,17 @@ function! <SID>FindProjectFileOrDirectory(fod)
|
|||
return ""
|
||||
endfunction
|
||||
|
||||
|
||||
function! GetProjectRuntimeDirectory()
|
||||
return <SID>FindProjectFileOrDirectory("vim")
|
||||
endfunction
|
||||
|
||||
|
||||
function! GetProjectFile()
|
||||
return <SID>FindProjectFileOrDirectory("project.vim")
|
||||
endfunction
|
||||
|
||||
|
||||
function! <SID>SourceProjectFile()
|
||||
let l:project_file = GetProjectFile()
|
||||
if l:project_file != ""
|
||||
|
@ -209,6 +216,7 @@ function! <SID>SourceProjectFile()
|
|||
endif
|
||||
endfunction
|
||||
|
||||
|
||||
function! <SID>AddProjectRuntimeDirectory()
|
||||
let l:project_rtp = GetProjectRuntimeDirectory()
|
||||
if isdirectory(l:project_rtp)
|
||||
|
@ -259,6 +267,11 @@ nmap gV `[v`]
|
|||
"let g:CommandTAcceptSelectionMap='<C-b>'
|
||||
"let g:CommandTAcceptSelectionTabMap='<CR>'
|
||||
|
||||
" GitGutter shows changed lines in files.
|
||||
let g:gitgutter_enabled = 0
|
||||
highlight clear SignColumn
|
||||
nmap <silent> <leader>gg :ToggleGitGutter<CR>
|
||||
|
||||
if has('autocmd')
|
||||
filetype plugin indent on
|
||||
|
||||
|
|
2
zprofile
2
zprofile
|
@ -12,7 +12,7 @@ print_heading -l 1 'Initializing login shell'
|
|||
list_tmux_sessions()
|
||||
{
|
||||
tmux_out=`tmux list-sessions 2>/dev/null`
|
||||
[[ -z "$tmux_out" ]] && return
|
||||
[[ -z "$tmux_out" || -n "$TMUX" ]] && return
|
||||
|
||||
echo "You have the following active tmux sessions:"
|
||||
for session in ${(f)tmux_out}; do
|
||||
|
|
|
@ -1,5 +1,8 @@
|
|||
#!/usr/bin/zsh
|
||||
# vim:sw=4:sts=4:
|
||||
#
|
||||
# A wordy prompt theme.
|
||||
#
|
||||
# Eryn Wells <eryn@erynwells.me>
|
||||
|
||||
|
||||
|
@ -74,6 +77,7 @@ function print_newline
|
|||
|
||||
function set_prompt_info
|
||||
{
|
||||
PS1_HISTORY="`prompt_colorize -b -f 'green' '%h'`"
|
||||
PS1_NAME="`prompt_colorize -f 'magenta' '%n'` "
|
||||
PS1_CWD="in `prompt_colorize -f 'green' '%~'` "
|
||||
|
||||
|
@ -83,13 +87,23 @@ function set_prompt_info
|
|||
PS1_HOST=''
|
||||
fi
|
||||
|
||||
# Get git repo information, if it exists. See setup function for
|
||||
# configuration details.
|
||||
vcs_info loquacious
|
||||
if [[ -n "$vcs_info_msg_0_" ]]; then
|
||||
PS1_REPO="on $vcs_info_msg_0_ "
|
||||
PS1_REPO="on $vcs_info_msg_0_ "
|
||||
else
|
||||
PS1_REPO=""
|
||||
PS1_REPO=""
|
||||
fi
|
||||
|
||||
# Show background jobs, if any.
|
||||
if [[ `jobs | wc -l` -ge 1 ]]; then
|
||||
PS1_JOBS='%j'
|
||||
fi
|
||||
|
||||
# Show background job count if any exist.
|
||||
RPS1="%(1j.[`prompt_colorize -f 'magenta' '%j'`].)"
|
||||
|
||||
PS1_LINE='%# '
|
||||
}
|
||||
|
||||
|
|
31
zshrc
31
zshrc
|
@ -1,5 +1,5 @@
|
|||
# .zshrc
|
||||
# vim: ft=zsh fdm=marker
|
||||
# vim:ft=zsh:fdm=marker:sw=4:sts=4:
|
||||
#
|
||||
# ZSH init for interactive shells
|
||||
#
|
||||
|
@ -45,7 +45,7 @@ function configure_omz #{{{
|
|||
DISABLE_AUTO_UPDATE="true"
|
||||
COMPLETION_WAITING_DOTS="true"
|
||||
|
||||
plugins=(autojump brew encode64 fasd git gnu-utils history osx python)
|
||||
plugins=(autojump brew encode64 fasd gnu-utils history osx python)
|
||||
|
||||
source $ZSH/oh-my-zsh.sh
|
||||
|
||||
|
@ -83,10 +83,6 @@ function configure_modules_and_functions #{{{
|
|||
print_info_sub -l 2 "Adding $myfpath to fpath"
|
||||
fpath=($myfpath/makers $myfpath $fpath)
|
||||
|
||||
print_info -l 3 'Loading vcs_info'
|
||||
autoload -Uz vcs_info
|
||||
zstyle ':vcs_info:*' enable git
|
||||
|
||||
load_module 'makers'
|
||||
|
||||
print_info -l 3 "Loading pw module"
|
||||
|
@ -174,6 +170,28 @@ function configure_completion #{{{
|
|||
} #}}}
|
||||
|
||||
|
||||
function configure_vcs_info #{{{
|
||||
{
|
||||
print_info -l 3 'Loading vcs_info'
|
||||
|
||||
autoload -U add-zsh-hook
|
||||
autoload -Uz vcs_info
|
||||
|
||||
zstyle ':vcs_info:*' disable bzr cdv darcs mtn svk tla cvs svn
|
||||
zstyle ':vcs_info:*' enable git p4
|
||||
|
||||
zstyle ':vcs_info:git:general:*' formats '%b'
|
||||
|
||||
# Export the current Git branch before every prompt.
|
||||
function export_gitbranch {
|
||||
vcs_info general
|
||||
export gitbranch=${vcs_info_msg_0_}
|
||||
}
|
||||
|
||||
add-zsh-hook precmd export_gitbranch
|
||||
} #}}}
|
||||
|
||||
|
||||
configure_general
|
||||
configure_omz
|
||||
configure_zle
|
||||
|
@ -181,6 +199,7 @@ configure_modules_and_functions
|
|||
configure_zsh_aliases
|
||||
configure_history
|
||||
configure_completion
|
||||
configure_vcs_info
|
||||
configure_prompt
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue