ubuntu 에서 vimrc 설정

note

ubuntu 24.04

개인적으로 사용하는 vimrc 설정 기록

setup

sudo apt-get update

sudo apt-get install vim

~/.vimrc

""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" Basic                                                                        "
""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""

" base
set encoding=utf-8                  " set encoding to UTF-8 (default was "latin1")

" action
set mouse=v                         " enable mouse support (might not work well on Mac OS X)
set tabstop=4                       " width that a 
<TAB> character displays as
set expandtab                       " convert 
<TAB> key-presses to spaces
set shiftwidth=4                    " number of spaces to use for each step of (auto)indent
set softtabstop=4                   " backspace after pressing 
<TAB> will remove up to this many spaces
set autoindent                      " copy indent from current line when starting a new line
set smartindent                     " even better autoindent (e.g. add indent after '{')
set backspace=start,eol,indent      " extend backspace serveral behavior

" appearance
set ruler                           " show line and column number of the cursor on right side of statusline
"set number                          " show line numbers
set wildmenu                        " visual autocomplete for command menu
set lazyredraw                      " redraw screen only when we need to
set laststatus=2                    " always show statusline (even with only single window)
set hlsearch                        " highlight matches
set incsearch                       " search as characters are entered
set showmatch                       " highlight matching parentheses / brackets [{()}]
"set cursorline                      " highlight current line
set background=dark                 " configure Vim to use brighter colors
colorscheme murphy                  " put colorscheme files in ~/.vim/colors/ (good colorschemes: murphy, slate, molokai, badwolf, solarized)
syntax enable
filetype plugin indent on
nnoremap 
<CR> :nohlsearch<CR><CR>   " turn off search highlighting with <CR> (carriage-return)

" etc
set wrap                            " wrap lines
set autoread                        " autoreload the file in Vim if it has been changed outside of Vim
set visualbell                      " blink cursor on error, instead of beeping

댓글 남기기

이메일 주소는 공개되지 않습니다. 필수 필드는 *로 표시됩니다