71a377e
if v:lang =~ "utf8$" || v:lang =~ "UTF-8$"
71a377e
   set fileencodings=ucs-bom,utf-8,latin1
71a377e
endif
71a377e
71a377e
set nocompatible	" Use Vim defaults (much better!)
71a377e
set bs=indent,eol,start		" allow backspacing over everything in insert mode
71a377e
"set ai			" always set autoindenting on
71a377e
"set backup		" keep a backup file
71a377e
set history=50		" keep 50 lines of command line history
71a377e
set ruler		" show the cursor position all the time
71a377e
71a377e
" Only do this part when compiled with support for autocommands
71a377e
if has("autocmd")
71a377e
  augroup fedora
71a377e
  autocmd!
71a377e
  " In text files, always limit the width of text to 78 characters
71a377e
  " autocmd BufRead *.txt set tw=78
71a377e
  " When editing a file, always jump to the last cursor position
71a377e
  autocmd BufReadPost *
71a377e
  \ if line("'\"") > 0 && line ("'\"") <= line("$") |
71a377e
  \   exe "normal! g'\"" |
71a377e
  \ endif
71a377e
  " don't write swapfile on most commonly used directories for NFS mounts or USB sticks
71a377e
  autocmd BufNewFile,BufReadPre /media/*,/run/media/*,/mnt/* set directory=~/tmp,/var/tmp,/tmp
71a377e
  " start with spec file template
71a377e
  autocmd BufNewFile *.spec 0r /usr/share/vim/vimfiles/template.spec
71a377e
  augroup END
71a377e
endif
71a377e
71a377e
if &term=="xterm"
71a377e
     set t_Co=8
71a377e
     set t_Sb=?[4%dm
71a377e
     set t_Sf=?[3%dm
71a377e
endif