From ffbebb7365eb83217b5edaa9ed2d8849e3686706 Mon Sep 17 00:00:00 2001 From: shmibs Date: Sat, 20 Dec 2014 21:23:27 -0700 Subject: custom vim colourscheme --- .Xresources | 2 +- .vim/colors/shmibs.vim | 38 ++++++++++++++++++++++++++++++ .vimrc | 64 ++++++++++++++++++++++++++++++++++++++------------ .zshrc | 24 +++++++++++++++++++ 4 files changed, 112 insertions(+), 16 deletions(-) create mode 100644 .vim/colors/shmibs.vim diff --git a/.Xresources b/.Xresources index 5560163..25595c9 100644 --- a/.Xresources +++ b/.Xresources @@ -67,7 +67,7 @@ URxvt*color11: #faff66 ! blue URxvt*color4: #00a1e4 ! light blue -URxvt*color12: #00b4ff +URxvt*color12: #00d7ff ! magenta URxvt*color5: #d0758b ! light magenta diff --git a/.vim/colors/shmibs.vim b/.vim/colors/shmibs.vim new file mode 100644 index 0000000..0cf6e02 --- /dev/null +++ b/.vim/colors/shmibs.vim @@ -0,0 +1,38 @@ +"Vim color file +"intended for 256 colour term + +hi clear + +let g:colors_name="shmibs" + +hi! Comment ctermfg=12 +hi! Constant ctermfg=1 +hi! CursorLine ctermbg=234 +hi! Directory ctermfg=6 +hi! Folded ctermbg=NONE ctermfg=240 +hi! Identifier cterm=bold ctermfg=6 +hi! NonText ctermbg=234 ctermfg=3 cterm=bold +hi! PreProc ctermfg=5 +hi! Statement ctermfg=3 +hi! Special ctermfg=9 +hi! SpecialKey ctermfg=2 +hi! SpellBad ctermbg=9 +hi! Title ctermfg=5 +hi! Todo ctermbg=11 ctermfg=0 +hi! Type ctermfg=2 +hi! Underlined ctermfg=5 cterm=underline + + +"A => B +hi! link Boolean Constant +hi! link Character Constant +hi! link Function Identifier +hi! link Keyword Statement +hi! link LineNr NonText +hi! link Number Constant +hi! link PreProc Define +hi! link SpecialChar Special +hi! link SpecialComment Special +hi! link String Constant +hi! link StorageClass Type +hi! link Tag Special diff --git a/.vimrc b/.vimrc index ce89dcb..4bc3d4d 100644 --- a/.vimrc +++ b/.vimrc @@ -1,10 +1,13 @@ +"""""""""""""" +" SETTINGS " +"""""""""""""" + syntax on filetype plugin indent on set autoindent "colours! -colorscheme anotherdark -set background=dark +colorscheme shmibs "enable status-line set laststatus=2 @@ -19,12 +22,42 @@ set hidden set guifont=Tamsyn\ 11 set guioptions=aegimt +"visual marker for 80th column +highlight Column80 ctermbg=black +call matchadd('Column80', '\%81v', 100) + + +""""""""""""" +" ALIASES " +""""""""""""" + "i keep accidentally typing these over and over -command W w +command W w command Wq wq command WQ wq -command Q q -command E e +command Q q +command E e + + +""""""""""""""""""" +" PLUGIN THINGS " +""""""""""""""""""" + +"Start interactive EasyAlign in visual mode (e.g. vip) +vmap (EasyAlign) + +"Start interactive EasyAlign for a motion/text object (e.g. gaip) +nmap ga (EasyAlign) + +"lightline things +"let g:lightline = { +" \ 'colorscheme': 'shmibsline' +" \ } + + +"""""""""""""" +" MAPPINGS " +"""""""""""""" "buffer / tab controls nnoremap :bn @@ -68,23 +101,32 @@ if &term != "linux" xnoremap P (v:register ==# '"' ? '"+' : '') . 'P' end + +""""""""""""""""""""""" +" FILETYPE SETTINGS " +""""""""""""""""""""""" + +"always use rust instead of hercules +au BufNewFile,BufRead *.rs set filetype=rust + "annoying syntax-related values that need to be set before files are "opened let g:c_no_comment_fold = 1 let g:c_no_if0_fold = 1 "other filetype-specific settings. i can't figure out how to stick all -"the FileTypes in one list (mostly because i have no idea what i'm +"the FileTypes in one dict (mostly because i have no idea what i'm "doing with viml), so separate lines it is. autocmd FileType asm call Settings_asm() autocmd FileType c call Settings_c() -autocmd FileType cpp call Settings_cpp() +autocmd FileType cpp call Settings_c() autocmd FileType tex call Settings_tex() autocmd FileType haskell call Settings_haskell() autocmd FileType make call Settings_script() autocmd FileType matlab call Settings_matlab() autocmd FileType perl call Settings_script() autocmd FileType python call Settings_script() +autocmd FileType rust call Settings_c() autocmd FileType sh call Settings_script() autocmd FileType vim call Settings_vim() autocmd FileType zsh call Settings_script() @@ -97,14 +139,6 @@ function! Settings_asm() endfunction function! Settings_c() - "settings - setlocal foldmethod=syntax - "mappings - nnoremap c :!make - nnoremap -- O*/hhi/* -endfunction - -function! Settings_cpp() "settings setlocal foldmethod=syntax setlocal shiftwidth=4 diff --git a/.zshrc b/.zshrc index 7da1ec7..d20508c 100644 --- a/.zshrc +++ b/.zshrc @@ -1,6 +1,7 @@ zstyle ':completion:*' completer _complete _ignored zstyle :compinstall filename '/home/shmibs/.zshrc' setopt completealiases +setopt interactivecomments autoload -U compinit compinit @@ -21,6 +22,21 @@ unsetopt beep PROMPT="%{%B$fg[white]%}[%{%(!.$fg[red].$fg[magenta])%}%n@%M %{$fg[blue]%}%c%{$fg[white]%}]: %{%b$reset_color%}" +################# HIGHLIGHTING ################ +source /usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh +ZSH_HIGHLIGHT_HIGHLIGHTERS=(main brackets pattern) + +#ZSH_HIGHLIGHT_STYLES[alias]="fg=yellow" +#ZSH_HIGHLIGHT_STYLES[builtin]="fg=yellow" +#ZSH_HIGHLIGHT_STYLES[function]="fg=yellow" +#ZSH_HIGHLIGHT_STYLES[command]="fg=yellow" + +ZSH_HIGHLIGHT_STYLES[single-quoted-argument]="fg=red" +ZSH_HIGHLIGHT_STYLES[double-quoted-argument]="fg=red" + +# highlight comments +ZSH_HIGHLIGHT_PATTERNS+=('\#*' 'fg=cyan') + ################# KEYBINDINGS ################# typeset -g -A key @@ -97,6 +113,14 @@ b2h() { echo "${val}${suffixes[$sindex]}" } +scap() { + archey3 + sleep .1 + rm /tmp/out.webm + ffmpeg -video_size 1920x1080 -framerate 30 -f x11grab -i :0.0 \ + -c:v libvpx -b:v 4M -threads 4 /tmp/out.webm > /dev/null 2>&1 +} + send() { if [ "$1" ]; then scp $@ shmibbles.me:/srv/http/tmp/ -- cgit v1.2.3