""" rjbs: Ricardo SIGNES """ vimrc """ $Id$ "" set vim options set autoindent " carry over indenting from previous line set backspace=2 " allow backspace beyond insertion point set background=dark " console bg is dark set cinkeys-=0# " don't unindent cpp stuff (perl comments!) set clipboard+=unnamed " put yanks/etc on the clipboard set comments=b://,b:# " by default allow C++ (JS) and generic unixy comments set com+=s1:/*,mb:*,ex:*/ " ...and also C-style comments set copyindent " make autoindent use the same characters to indent set directory-=. " don't store temp files in cwd set encoding=utf-8 " unicode set expandtab " spaces, not tabs! (this decision: 2005-06-02) set foldlevelstart=99 " start with all folds open set foldopen-=search " don't open folds when you search into them set foldopen-=undo " don't open folds when you undo stuff set formatoptions=tcqr2l " t - autowrap normal text " c - autowrap comments and re-insert comment leader " q - allow gq to reformat comments " r - re-insert comment leader on newline " 2 - indent based on second line of para, not first " l - don't break long lines that were long before ins set guioptions+=f " don't fork if run under X11! sheesh. set guioptions-=T " do not show the toolbar by default set hidden " hide, don't close, undisplayed buffers set laststatus=2 " always show status line set path=.,$HOME,, " for editing with :find set pastetoggle= " F2 to toggle paste set popt=paper:letter " better default paper size for my purposes set ruler " display cursor position set showcmd " show command-in-progress set shortmess=at " shortens messages to avoid 'press a key' prompt set shiftwidth=2 " two spaces per sw set softtabstop=2 " make two spaces act like tabs set timeout " allow keys to timeout set title " do set the xterm title (see 'titleold', set below) set tabstop=2 " The One True Tab (as of latest revision) set textwidth=79 " set normal border; can unset for coding set wildignore+=*/CVS/ " don't try to descend into CVS directories set wildmenu " enable menu of completions set wildmode=longest:full,full " complete only as much as is common, " then show menu colorscheme manxome " use my phat color scheme filetype plugin on " use ftplugins, mostly for those in ~ runtime macros/matchit.vim " pulled from macros dir to avoid requiring install syntax on " enable syntax highlighting if has("win32") let Tlist_Ctags_Cmd='C:\Progra~1\ctags\ctags.exe' map :simalt ~ elseif has("macunix") " the Carbon clipboard is screwed up, and messes up newlines set cb= endif " exec'd because ... could it work otherwise? exec "set titleold=" . matchstr(hostname(), "^[^.]\\+") """ use a UTF-8 term if you can if $TERM_PROGRAM == "Apple_Terminal" set tenc=utf-8 endif """ use fonts that don't make my eyes bleed if has("gui_running") if has("macunix") set guifont=Monaco:h13 set noanti elseif has("win32") set guifont=ProFontWindows:h11:b:cANSI,Lucida_Console:h11:b:cANSI elseif has("x11") set guifont=-jmk-neep-bold-r-normal--15-*-*-*-*-*-*-* endif endif """ act more like a pager when invoked as one if ((v:progname == "view") || ($RJBS_IN_MAN == "1")) nmap nmap b nmap q :q endif """ configure status line function ModifiedFlag() if (&modified) return "*" else return " " endif endfunc set statusline=[%n]\ %{ModifiedFlag()}%f\ %=%h%r%w\ (%v,%l)\ %P\ """ set various script options " perl syntax "let perl_fold=1 " allow perl folding let perl_include_pod = 1 let perl_extended_vars = 1 " perl_synwrite silent call system("perl -e0 -MVi::QuickFix=silent") let perl_synwrite_qf = ! v:shell_error " use Vi::QuickFix if it can be used " see changes " diffthis | vs | enew | set buftype=nofile | r # | 1d | diffthis iabbr --r -- rjbs, =strftime("%Y-%m-%d") " version 7 things if v:version >= 700 nnoremap @ :set cursorcolumn! cursorline! let loaded_matchparen = 1 endif