Created
January 31, 2021 12:34
-
-
Save TitouanT/4d819baaeb0f732ad7ae5af8ea3e9d6c to your computer and use it in GitHub Desktop.
This is beginner vimrc, I recommend to read it, and use :help command to understand it. Instructions to get started are at the top of the file.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
" curl -fLo ~/.vim/autoload/plug.vim --create-dirs https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim | |
" save in ~/.vim/vimrc | |
" open vim and type `:PlugInstall<cr>` | |
" your leader key, useful to add your own mappings. ',' is an example, use | |
" what you want | |
let g:mapleader = ',' | |
call plug#begin('~/.vim/plugged') | |
" themes | |
Plug 'fatih/molokai' | |
Plug 'joshdick/onedark.vim' | |
Plug 'morhetz/gruvbox' | |
" syntax highlighting for more lgges | |
Plug 'sheerun/vim-polyglot' | |
" a status line | |
Plug 'itchyny/lightline.vim' | |
" comment a line with `gcc` in normal mode, and with `gc` in visual mode | |
Plug 'tpope/vim-commentary' | |
call plug#end() | |
" colors and theme | |
syntax enable | |
set t_Co=256 | |
set background=dark | |
" colorscheme molokai | |
" colorscheme onedark | |
colorscheme gruvbox | |
" search | |
set ignorecase | |
set smartcase | |
set incsearch | |
set hlsearch | |
" remove search highlight by pressing '<leader> ' | |
nnoremap <silent> <leader><space> :nohlsearch<cr> | |
"settings | |
filetype on | |
filetype plugin on | |
filetype indent on | |
" makes backspace sane | |
set backspace=indent,eol,start | |
" mouse support | |
set mouse=a | |
" give access to system clipboard | |
set clipboard=unnamedplus | |
" indentation | |
set tabstop=4 | |
set shiftwidth=4 | |
set noerrorbells | |
set novisualbell | |
set number | |
set autoindent | |
" split | |
set splitbelow | |
set splitright | |
"status line | |
set laststatus=2 " always show the status line | |
set showcmd |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment