set nocompatible """""""""""""""""""""""""""""""""""""""""""""""""" func! XXX() s/^/XXX/ endfunc func! Ae2U() %s/Ae/Ä/g %s/Oe/Ö/g %s/Ue/Ü/g %s/ae/ä/g %s/ue/ü/g %s/oe/ö/g endfunc func! Ae2Latex() %s/Ae/"A/g %s/Oe/"O/g %s/Ue/"U/g %s/ae/"a/g %s/ue/"u/g %s/oe/"o/g endfunc func! U2Ae() %s/Ä/Ae/g %s/Ö/Oe/g %s/Ü/Ue/g %s/ä/ae/g %s/ü/ue/g %s/ö/oe/g endfunc func! U2Latex() %s/Ä/"A/g %s/Ö/"O/g %s/Ü/"U/g %s/ä/"a/g %s/ü/"u/g %s/ö/"o/g endfunc func! Latex2U() %s/"A/Ä/g %s/"O/Ö/g %s/"U/Ü/g %s/"a/ä/g %s/"u/ü/g %s/"o/ö/g endfunc func! LatexUAe() %s/"A/Ae/g %s/"O/Oe/g %s/"U/Ue/g %s/"a/ae/g %s/"u/ue/g %s/"o/oe/g endfunc func! Nzz() "" remove not belonging stuff normal V/ABB\C kd/UBS\C }VGdgg0 " join according lines and remove nonessential ones normal JjddJjddJjddJjddJjddJ0kkkkkkkkkk " get time and date into a and b normal /..\...\. "ayaW0 normal /..:..:.. "byaW0 " UBS fix normal G/IMG BdWxxgg0 " remove blocks normal jjjjjf]dllljjjjjlllwhhdwWhjjjjj normal WWhdeljjjjjwwWWhhd normal Ellljjjjj$d0 " normal wWbeljjjjjDjjjjjd0 "" add time and date normal 0Go"ap"bp0:s/ / /g " replace BAY with BMW normal 2G:s/BAY/BWM/ normal  "" put into "* normal ggVG"*y " for nr in range(1, line("$")) " call setline(nr, substitute(getline(nr), "\\s*$", "", "")) " endfor endfunc "map :update:colorscheme calmar256-dark-trans "map vaw"py/p map ,e :w:!% <<< "bogus" set spelllang=de "set spellfile=us "set sps=fast,20 set diffopt=horizontal set laststatus=2 set statusline=%-3.3n\ %f\ %h%m%r%w[%{strlen(&ft)?&ft:'none'},%{strlen(&fenc)?&fenc:&enc},%{&fileformat}]\ %{synIDattr(synID(line('.'),col('.'),1),'name')}\ %=0x%-8B\%-14.(%l,%c%V%)\ %<%P set writebackup set backup backupdir=$HOME/.vim/backup set number ruler set viminfo=!,'50,\"1000,:150,n~/.vim/viminfo set fileformat=unix history=50 "set digraph set formatoptions=croq set hlsearch set incsearch set ignorecase set smartcase set nocursorline set nocursorcolumn set virtualedit=block set magic set wildmenu set wildmode=longest,list " bash like completion set showmatch set modeline set tabstop=4 set expandtab set shiftwidth=2 " or whatever "set nosmartindent "set smarttab autoindent set backspace=2 "allow backspacing over everything in insert mode set mouse=a " allows marking/pasting with the mouse also on 'not gui vim' set foldmethod=manual set foldcolumn=2 set grepprg=grep\ -nH\ $* " latex suite wants that let xml_use_xhtml = 1 " xml.vim option let g:calendar_monday = 1 " calendar option syntax on " syntax highlighting syntax sync fromstart filetype on " try to set the filetype automatically filetype plugin on " try loading plugins automatically filetype indent on " indent " for the command-line "cnoremap "cnoremap "cnoremap "cnoremap b "cnoremap f nnoremap Q gqap vnoremap Q gq "nmap v "nmap V " map F12 to change the pwd of vim to the cwd of the current file " noremap :cd =expand("%:p:h") " let NERDDefaultNesting = 1 "for the NERD Commenter let NERDMapleader = '\c' let NERDAltComMap = '\ca' let NERDAppendComMap = '\ce' let NERDComAlignLeftMap = '\cl' let NERDComAlignBothMap = '\cb' let NERDComAlignRightMap = '\cr' let NERDComInInsertMap = '\' let NERDComLineInvertMap = '\ci' let NERDComLineToggleMap = '\cc' let NERDComLineNestMap = '\cn' let NERDComLineSexyMap = '\cs' let NERDComLineMap = '\c' let NERDComLineMinimalMap = '\cm' let NERDComToEOLMap = '\c$' let NERDComLineYankMap = '\cy' let NERDUncomLineMap = '\cu' let NERDCompactSexyComs = 1 set background=dark if $DISPLAY != '' set t_Co=256 colorscheme calmar256-dark else colorscheme peachpuff endif autocmd FileType c,cpp,slang set cindent "autocmd FileType tex set tw=80 sw=2 fo=rcql autocmd BufNewFile,BufRead /tmp/mutt-* set filetype=mail autocmd BufNewFile,BufRead .awesomerc set filetype=perl autocmd BufNewFile,BufRead /tmp/vimperator-* set filetype=asciidoc " au BufReadPost * if line("'\"") > 0 && line("'\"") <= line("$") | exe "normal g`\"" | endif autocmd FileType python set nosmartindent autoindent tabstop=8 expandtab shiftwidth=4 softtabstop=4 autocmd FileType python nmap :wall:!./% "autocmd FileType python nmap :wall:!./% "autocmd FileType python nmap :wall:!/home/calmar/bin/mkcalmgallery.py autocmd FileType python,c,javascript nmap :Tlist autocmd FileType python set foldmethod=marker foldnestmax=1 au FileType mail source ~/.vim/mail_settings " generally LATIN1 au! BufRead,BufNewFile *.php,*.html,*part set ft=xhtml au! FileType xhtml,html,php,css set fileencoding=latin1 " LATIN1 au! BufRead,BufNewFile /home/calmar/multimedia/www/b-c-b.ch/** set fileencoding=latin1 au! BufRead,BufNewFile /home/calmar/multimedia/www/sini.li/** set fileencoding=latin1 au! BufRead,BufNewFile /home/calmar/multimedia/www/bonazuens.ch/** set fileencoding=latin1 au! BufRead,BufNewFile /home/calmar/multimedia/www/flying-pins-rheintal.ch/** set fileencoding=latin1 au! BufRead,BufNewFile /home/calmar/multimedia/www/narrenschiff.ch/** set fileencoding=latin1 au! BufRead,BufNewFile /home/calmar/multimedia/www/candrian.org/** set fileencoding=latin1 " UTF-8 " ok if upload and new entries work " ok au! BufRead,BufNewFile /home/calmar/multimedia/www/calmar.ws/** set fileencoding=utf-8 encoding=utf-8 au! BufRead,BufNewFile /home/calmar/multimedia/www/narrenschiffdbase/** set fileencoding=utf-8 encoding=utf-8 au! BufRead,BufNewFile /home/calmar/multimedia/www/narrenschiffdbase/** nmap ,v mz:%!tidy_utf8.tidy.conf -asxhtml "au BufWinLeave *.tex,*.c,*.h mkview "au BufWinEnter *.tex,*.c,*.h silent loadview "au BufWinEnter *.tex,*.c,*.h set foldmethod=manual "au BufWinLeave *vimrc,*gvimrc set nolist au BufWinEnter *vimrc,*gvimrc set list au FileType xml nmap ,v mz:%!tidy.tidy.conf au FileType xhtml,html,php,css nmap :update:!aap au FileType xhtml,html,php,css nmap ,a :update:!aap au FileType xhtml,html,php nmap ,v mz:%!tidy.tidy.conf -asxhtml au FileType xhtml,html,php nmap ,d 1G/ndggG?bodydG'z "au FileType xhtml,html,php nmap ,d 1GV/ndGV?bodyd:w'z au FileType xhtml,html,php set tw=80 wrapmargin=64 "au FileType tex,plaintex setlocal spell " au FileType xhtml,html,php nmap ,V mz:%!tidy_utf8.tidy.conf -asxhtml "au VimLeave * echo "bye bye" | sleep 1 " au FileType asciidoc set tw=60 spelllang=en spell formatoptions=tcroq au FileType asciidoc nmap :update:!asciidoc % "nmap :update :source /home/calmar/.vimrc "nmap :sp ~/.vimrc " map c :CMiniBufExplorer map u :UMiniBufExplorer map t :TMiniBufExplorer " some showmarks plugin settings let g:showmarks_textlower="\t" let g:showmarks_textupper="\t" let g:showmarks_textother="\t" " let g:showmarks_hlline_lower=1 " " see the file in Firefox (ffox is a scripts what itself starts firefox) " an /home/calmar/vim/firefox.xpm ToolBar.Ffox :call Ffox() " map b1 :!boxes -d ca--tl-n map b2 :!boxes -d ca--tlb-n map g2 :!boxes -d ca--tlb-tf[llR map b3 :!boxes -d ca--tlbr-n map g3 :!boxes -d ca--tlbr-tf[llR map b4 :!boxes -d ca-3tl-n map b5 :!boxes -d ca-3tlb-n map g5 :!boxes -d ca-3tlb-tf[llR map b6 :!boxes -d ca-3tlbr-n map g6 :!boxes -d ca-3tlbr-tf[llR map b7 :!boxes -d ada-box map b8 :!boxes -d html map b9 :!boxes -d html-cmt map b0 :!boxes -d vim-cmt map bq :!boxes -d peek map bw :!boxes -d c-cmt2 map be :!boxes -d java-cmt map br :!boxes -d pount-cmt map gt :!boxes -d parchment map g7 :!boxes -d columns map g8 :!boxes -d whirly map g9 :!boxes -d scroll map g0 :!boxes -d nuke map gq :!boxes -d mouse map gw :!boxes -d boy map ge :!boxes -d cat map gr :!boxes -d ca-congrats map gt :!boxes -d ca-bigtux map gt :!boxes -d ca-diamonds "function! Indent() " let oldLine=line('.') " normal gg=G " execute ':' . oldLine "endfun "map -- :call Indent() "map b1 vip:!boxes -d ca-half-left-ntf[llR "highlight CursorLine ctermbg=16 "function! Ffox() " let s:corrected=substitute(expand("%:p"),"\\","/","g") " execute "silent! !ffox file://" . s:corrected "endfunc "function! Opera() " let s:corrected=substitute(expand("%:p"),"\\","/","g") " execute "silent! !opera file://" . s:corrected "endfunc "map :call Opera() "ap :call Ffox() " "highlight ShowMarksHLl guifg=red guibg=green cterm=bold ctermfg=yellow ctermbg=black "ighlight ShowMarksHLu guifg=red guibg=green cterm=bold ctermfg=yellow ctermbg=black "ighlight ShowMarksHLo guifg=red guibg=green cterm=bold ctermfg=yellow ctermbg=black "ighlight ShowMarksHLm guifg=red guibg=green cterm=bold ctermfg=yellow ctermbg=black "func! Foobar() " let char = getline(".")[col(".")-1] " if char == "(" " normal la " else " normal a) " endif "endfunc " "inoremap ) :call Foobar() "inoremap ( ()i "function! Site() " normal /.php< /0\..000 llr8 "endfunc " au! BufRead sitemap.xml* map ,p :call Site()