Skip to content

Instantly share code, notes, and snippets.

@idoleat
Last active July 16, 2022 11:24
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save idoleat/87e718ffa3a02e579f6321a12f4ee8ec to your computer and use it in GitHub Desktop.
Save idoleat/87e718ffa3a02e579f6321a12f4ee8ec to your computer and use it in GitHub Desktop.
My .vimrc with lovely theme
" Auto install VimPlug
let data_dir = has('nvim') ? stdpath('data') . '/site' : '~/.vim'
if empty(glob(data_dir . '/autoload/plug.vim'))
silent execute '!curl -fLo '.data_dir.'/autoload/plug.vim --create-dirs https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim'
autocmd VimEnter * PlugInstall --sync | source $MYVIMRC
endif
"======= VimPlug Section ==========
call plug#begin('~/.vim/plugged')
" That status bar la
Plug 'vim-airline/vim-airline'
Plug 'vim-airline/vim-airline-themes'
" File manager
Plug 'scrooloose/nerdtree'
Plug 'Xuyuanp/nerdtree-git-plugin'
Plug 'tiagofumo/vim-nerdtree-syntax-highlight'
Plug 'ryanoasis/vim-devicons'
" An illigal Git plugin ?????
Plug 'tpope/vim-fugitive'
" My first love
" Plug 'morhetz/gruvbox'
Plug 'sainnhe/gruvbox-material'
" Show icons in NERDTree, airline, and more
Plug 'ryanoasis/vim-devicons'
" A fancy start screen for Vim
Plug 'mhinz/vim-startify'
call plug#end()
"==================================
"====Nerd Tree======
" auto open everytime
autocmd VimEnter * NERDTree | wincmd p
" auto close if is the last
autocmd BufEnter * if tabpagenr('$') == 1 && winnr('$') == 1 && exists('b:NERDTree') && b:NERDTree.isTabTree() |
\ quit | endif
"===================
"===========gruvbox==========
if has('termguicolors')
set termguicolors
endif
set background=dark
colorscheme gruvbox-material
let g:airline_theme = 'gruvbox_material'
"============================
set mouse=a
set encoding=UTF-8
set nocompatible
filetype off
syntax on
filetype plugin indent on
set modelines=0
set number
set ruler
set visualbell
set wrap
set hlsearch
set incsearch
set ignorecase
set smartcase
set showmatch
@idoleat
Copy link
Author

idoleat commented Jul 16, 2022

Reminder: You need to :PlugInstall after placing .vimrc and reloading vim

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment