From 6a080b638180eb1eb0629544d67dd1344f1afe2d Mon Sep 17 00:00:00 2001 From: Thomas Ruoff Date: Sun, 18 May 2014 00:01:44 +0200 Subject: [PATCH 1/9] add some bundles to vim --- vimrc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/vimrc b/vimrc index 2d14743..703f673 100644 --- a/vimrc +++ b/vimrc @@ -19,6 +19,9 @@ Bundle 'scrooloose/syntastic.git' Bundle 'kien/ctrlp.vim' Bundle 'Lokaltog/powerline' Bundle 'flazz/vim-colorschemes' +Bundle 'mileszs/ack.vim' +Bundle 'airblade/vim-gitgutter' +Bundle 'editorconfig/editorconfig-vim' filetype plugin indent on From ecb5fcbedca1d90b969be8c6836f70d721c134b5 Mon Sep 17 00:00:00 2001 From: Thomas Ruoff Date: Sun, 18 May 2014 00:02:53 +0200 Subject: [PATCH 2/9] turn off mouse support for now --- vimrc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vimrc b/vimrc index 703f673..8b83601 100644 --- a/vimrc +++ b/vimrc @@ -37,7 +37,7 @@ let mapleader = "," " CONFIGURATION MAPPING set scrolloff=3 " show 3 lines of context around the cursor set autoread " set to auto read when a file is changed from the outside -set mouse=a " allow for full mouse support +"set mouse=a " allow for full mouse support set autowrite set showcmd " show typed commands From 842c289cd79c9e7460ed6199609cf69d01c3fe44 Mon Sep 17 00:00:00 2001 From: Thomas Ruoff Date: Sun, 18 May 2014 00:03:16 +0200 Subject: [PATCH 3/9] fix fast saving --- vimrc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vimrc b/vimrc index 8b83601..6b2d3d7 100644 --- a/vimrc +++ b/vimrc @@ -124,7 +124,7 @@ set foldlevel=99 " ADDITIONAL KEY MAPPINGS " fast saving -nmap w :up +nmap w :update " fast escaping imap jj " prevent accidental striking of F1 key From b536816ab7e327b87abfd3e92e1fd172675233d1 Mon Sep 17 00:00:00 2001 From: Thomas Ruoff Date: Sun, 18 May 2014 00:09:56 +0200 Subject: [PATCH 4/9] make xinitrc hostname specific --- xinitrc | 62 +++++++++++++++++++++++++++++++-------------------------- 1 file changed, 34 insertions(+), 28 deletions(-) diff --git a/xinitrc b/xinitrc index d4cabab..0cc6954 100755 --- a/xinitrc +++ b/xinitrc @@ -4,36 +4,42 @@ # # Executed by startx (run your window manager from here) -if [ -d /etc/X11/xinit/xinitrc.d ]; then - for f in /etc/X11/xinit/xinitrc.d/*; do - [ -x "$f" ] && . "$f" - done - unset f -fi +case $((hostname)) in + t430s-arch) + if [ -d /etc/X11/xinit/xinitrc.d ]; then + for f in /etc/X11/xinit/xinitrc.d/*; do + [ -x "$f" ] && . "$f" + done + unset f + fi -start-pulseaudio-x11 -eval $(gpg-agent --daemon) & + pulseaudio --start -xrdb $HOME/.Xresources + eval $(gpg-agent --daemon) & -# add additional fonts -xset +fp /usr/share/fonts/local -xset fp rehash + xrdb $HOME/.Xresources -case $1 in - enlightenment) - exec enlightenment_start - ;; - xterm) - exec xterm - ;; - bspwm) - sxhkd & - exec bspwm - ;; - hlwm|*) # default is herbstluftwm - /usr/bin/xscreensaver -no-splash & - xbindkeys & - exec herbstluftwm --locked - ;; + # add additional fonts + xset +fp /usr/share/fonts/local + xset fp rehash + + case $1 in + enlightenment) + exec enlightenment_start + ;; + xterm) + exec xterm + ;; + bspwm) + sxhkd & + exec bspwm + ;; + hlwm|*) # default is herbstluftwm + /usr/bin/xscreensaver -no-splash & + xbindkeys & + exec herbstluftwm --locked + ;; + esac + ;; esac + From a73a0cb523bd497fbf0838cd500490fc6336b1d5 Mon Sep 17 00:00:00 2001 From: Thomas Ruoff Date: Sun, 18 May 2014 00:29:00 +0200 Subject: [PATCH 5/9] add npm completion, weirdly not found otherwise anymore --- zsh/bundle/npm/init.zsh | 53 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 zsh/bundle/npm/init.zsh diff --git a/zsh/bundle/npm/init.zsh b/zsh/bundle/npm/init.zsh new file mode 100644 index 0000000..da9818d --- /dev/null +++ b/zsh/bundle/npm/init.zsh @@ -0,0 +1,53 @@ +###-begin-npm-completion-### +# +# npm command completion script +# +# Installation: npm completion >> ~/.bashrc (or ~/.zshrc) +# Or, maybe: npm completion > /usr/local/etc/bash_completion.d/npm +# + +COMP_WORDBREAKS=${COMP_WORDBREAKS/=/} +COMP_WORDBREAKS=${COMP_WORDBREAKS/@/} +export COMP_WORDBREAKS + +if type complete &>/dev/null; then + _npm_completion () { + local si="$IFS" + IFS=$'\n' COMPREPLY=($(COMP_CWORD="$COMP_CWORD" \ + COMP_LINE="$COMP_LINE" \ + COMP_POINT="$COMP_POINT" \ + npm completion -- "${COMP_WORDS[@]}" \ + 2>/dev/null)) || return $? + IFS="$si" + } + complete -F _npm_completion npm +elif type compdef &>/dev/null; then + _npm_completion() { + si=$IFS + compadd -- $(COMP_CWORD=$((CURRENT-1)) \ + COMP_LINE=$BUFFER \ + COMP_POINT=0 \ + npm completion -- "${words[@]}" \ + 2>/dev/null) + IFS=$si + } + compdef _npm_completion npm +elif type compctl &>/dev/null; then + _npm_completion () { + local cword line point words si + read -Ac words + read -cn cword + let cword-=1 + read -l line + read -ln point + si="$IFS" + IFS=$'\n' reply=($(COMP_CWORD="$cword" \ + COMP_LINE="$line" \ + COMP_POINT="$point" \ + npm completion -- "${words[@]}" \ + 2>/dev/null)) || return $? + IFS="$si" + } + compctl -K _npm_completion npm +fi +###-end-npm-completion-### From 0e12806f355e947c58a896f2a39a091e922ac8ba Mon Sep 17 00:00:00 2001 From: Thomas Ruoff Date: Sun, 18 May 2014 00:29:30 +0200 Subject: [PATCH 6/9] update zilsh, oh-my-zsh --- zsh/bundle/oh-my-zilsh | 2 +- zsh/zilsh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/zsh/bundle/oh-my-zilsh b/zsh/bundle/oh-my-zilsh index e5fdf78..22016bd 160000 --- a/zsh/bundle/oh-my-zilsh +++ b/zsh/bundle/oh-my-zilsh @@ -1 +1 @@ -Subproject commit e5fdf78509d41f2549335961a78f02d5146b6fe3 +Subproject commit 22016bd5512a09ef310ed5a56eaf03f660d83387 diff --git a/zsh/zilsh b/zsh/zilsh index 1120c71..7b1881d 160000 --- a/zsh/zilsh +++ b/zsh/zilsh @@ -1 +1 @@ -Subproject commit 1120c7175c0c47b36f54751016f61695dbd10c51 +Subproject commit 7b1881de4b77c52dfabe3278d2add6d9e3d8ccda From 54f6f5558249b427a31a278508df670cab64a187 Mon Sep 17 00:00:00 2001 From: Thomas Ruoff Date: Sun, 18 May 2014 00:30:41 +0200 Subject: [PATCH 7/9] update vundle --- vim/bundle/vundle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vim/bundle/vundle b/vim/bundle/vundle index f31aa52..8db3bcb 160000 --- a/vim/bundle/vundle +++ b/vim/bundle/vundle @@ -1 +1 @@ -Subproject commit f31aa52552ceb40240e56e475e6df89cc756507e +Subproject commit 8db3bcb5921103f0eb6de361c8b25cc03cb350b5 From 71017e7fe851f9e64417abac4e22a23e928b42d1 Mon Sep 17 00:00:00 2001 From: Thomas Ruoff Date: Sun, 15 Jun 2014 23:25:01 +0200 Subject: [PATCH 8/9] Update vundle for vim --- .gitignore | 2 +- .gitmodules | 6 ++-- vim/bundle/{vundle => Vundle.vim} | 0 vimrc | 52 ++++++++++++++++++++----------- 4 files changed, 37 insertions(+), 23 deletions(-) rename vim/bundle/{vundle => Vundle.vim} (100%) diff --git a/.gitignore b/.gitignore index 9132d67..ebee737 100644 --- a/.gitignore +++ b/.gitignore @@ -1,6 +1,6 @@ irssi vim/bundle/* -!vim/bundle/vundle +!vim/bundle/Vundle.vim vim/spell .netrwhist diff --git a/.gitmodules b/.gitmodules index 19c1f6d..7fe50f7 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,9 +1,9 @@ -[submodule "vim/bundle/vundle"] - path = vim/bundle/vundle - url = git://github.com/gmarik/vundle.git [submodule "zsh/zilsh"] path = zsh/zilsh url = git@github.com:zilsh/zilsh.git [submodule "zsh/bundle/oh-my-zilsh"] path = zsh/bundle/oh-my-zilsh url = git@github.com:zilsh/oh-my-zilsh.git +[submodule "vim/bundle/Vundle.vim"] + path = vim/bundle/Vundle.vim + url = https://github.com/gmarik/Vundle.vim.git diff --git a/vim/bundle/vundle b/vim/bundle/Vundle.vim similarity index 100% rename from vim/bundle/vundle rename to vim/bundle/Vundle.vim diff --git a/vimrc b/vimrc index 6b2d3d7..8adc014 100644 --- a/vimrc +++ b/vimrc @@ -3,28 +3,38 @@ set nocompatible " Vundle filetype off " required! -set rtp+=~/.vim/bundle/vundle/ -call vundle#rc() +" set the runtime path to include Vundle and initialize +set rtp+=~/.vim/bundle/Vundle.vim +call vundle#begin() -" My Bundles here: -" -" original repos on github -Bundle 'gmarik/vundle' -Bundle 'scrooloose/nerdtree' -Bundle 'pangloss/vim-javascript' -Bundle 'tpope/vim-fugitive' -Bundle 'clones/vim-l9' -Bundle 'clones/vim-fuzzyfinder' -Bundle 'scrooloose/syntastic.git' -Bundle 'kien/ctrlp.vim' -Bundle 'Lokaltog/powerline' -Bundle 'flazz/vim-colorschemes' -Bundle 'mileszs/ack.vim' -Bundle 'airblade/vim-gitgutter' -Bundle 'editorconfig/editorconfig-vim' +" let Vundle manage Vundle, required +Plugin 'gmarik/Vundle.vim' + +Plugin 'L9' + +Plugin 'clones/vim-fuzzyfinder' +Plugin 'scrooloose/nerdtree' +Plugin 'kien/ctrlp.vim' +Plugin 'maxbrunsfeld/vim-yankstack', {'name': 'yankstack'} + +Plugin 'editorconfig/editorconfig-vim' + +Plugin 'pangloss/vim-javascript' +Plugin 'scrooloose/syntastic.git' + +Plugin 'mileszs/ack.vim' + +Plugin 'tpope/vim-fugitive' +Plugin 'airblade/vim-gitgutter' + +Plugin 'Lokaltog/powerline' +Plugin 'flazz/vim-colorschemes' -filetype plugin indent on +" All of your Plugins must be added before the following line +call vundle#end() " required +filetype plugin indent on " required + " enable 256 color !!1! set t_Co=256 @@ -229,6 +239,10 @@ nmap ]e vmap [egv vmap ]egv +" yankstack +nmap p yankstack_substitute_older_paste +nmap P yankstack_substitute_newer_paste + " MAIL HUMAN TEX au BufNewFile,BufRead *.txt set filetype=human au FileType human,mail,tex set expandtab textwidth=78 nocindent From 20768e1ed56721b5838ace5a0f3dba64801e6f22 Mon Sep 17 00:00:00 2001 From: Thomas Ruoff Date: Mon, 16 Jun 2014 00:21:35 +0200 Subject: [PATCH 9/9] replace powerline with airline --- vimrc | 29 ++++++++++------------------- 1 file changed, 10 insertions(+), 19 deletions(-) diff --git a/vimrc b/vimrc index 8adc014..a520f2c 100644 --- a/vimrc +++ b/vimrc @@ -27,7 +27,7 @@ Plugin 'mileszs/ack.vim' Plugin 'tpope/vim-fugitive' Plugin 'airblade/vim-gitgutter' -Plugin 'Lokaltog/powerline' +Plugin 'vim-airline', {'name': 'airline'} Plugin 'flazz/vim-colorschemes' @@ -95,23 +95,10 @@ au GUIEnter * set vb t_vb= syntax enable " enable syntax highlighting -" Statusline - if has('statusline') set laststatus=2 - - " Broken down into easily includeable segments - set statusline=%<%f\ " Filename - set statusline+=%w%h%m%r " Options - set statusline+=%{fugitive#statusline()} " Git Hotness - set statusline+=\ [%{&ff}/%Y] " filetype - set statusline+=\ [%{getcwd()}] " current dir - "set statusline+=\ [A=\%03.3b/H=\%02.2B] " ASCII / Hexadecimal value of char - set statusline+=%=%-14.(%l,%c%V%)\ %p%% " Right aligned file nav info endif -" Powerline -set rtp+=~/.vim/bundle/powerline/powerline/bindings/vim " VIM 7.3 FEATURES @@ -184,11 +171,15 @@ map sp [s map sa zg map s? z= -" numbers -set number -set relativenumber -nnoremap :set nonumber! -nnoremap :set relativenumber! +nmap hh :set invhlsearch +nmap ll :set invlist +nmap nn :set invnumber +nmap pp :set invpaste +nmap ii :set invrelativenumber + +if exists('+relativenumber') + set relativenumber +endif "" ADDITIONAL AUTOCOMMANDS