Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/devstein/vim
https://github.com/devstein/vim
Last synced: 4 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/devstein/vim
- Owner: devstein
- Created: 2018-08-18T03:52:27.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2023-10-22T00:51:33.000Z (about 1 year ago)
- Last Synced: 2024-10-12T15:03:41.796Z (about 1 month ago)
- Language: Vim Script
- Size: 19.5 KB
- Stars: 1
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# VIM
## Setup
### 1. Install [`neovim`](https://github.com/neovim/neovim)
```bash
brew install neovim
pip install pynvim
npm install -g neovim
```### 2. Alias `vim` and `vi` to `nvim`
```bash
# Add these lines to your ~/.bashrc or ~/.zshrc
alias vi="nvim"
alias vim="nvim"
```### 3. Symlink `~/.vim/init.vim` to `~/.vimrc`
```bash
ln -s ~/.vimrc ~/.vim/init.vim
```### 4. Start modifying your `~/.vimrc`
A few of my preferred settings
```vim
" Remap leader key
let mapleader = "\"" jj and jk to escape
inoremap jj
inoremap jk" Ctrl+C to yank to clipboard
vnoremap "*y" Always use spaces
set tabstop=2 shiftwidth=2 expandtab" Color Scheme
syntax onset termguicolors
" Always use line numbers
set number" Spellcheck
set spell spelllang=en_us
```### 5. Install Plugins via [vim-plug](https://github.com/junegunn/vim-plug)
First install `vim-plug`
```bash
sh -c 'curl -fLo "${XDG_DATA_HOME:-$HOME/.local/share}"/nvim/site/autoload/plug.vim --create-dirs \
https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim'
```Then to start off, add the following to the top of your `~/.vimrc`
```vim
call plug#begin('~/.local/share/nvim/plugged')Plug 'tpope/vim-sensible'
Plug 'tpope/vim-fugitive'
Plug 'tpope/vim-surround'
Plug 'tpope/vim-eunuch'
Plug 'scrooloose/syntastic'
Plug 'jiangmiao/auto-pairs'
Plug 'vim-airline/vim-airline'
Plug 'sheerun/vim-polyglot'
Plug 'tpope/vim-repeat'" File Finder
" PlugInstall and PlugUpdate will clone fzf in ~/.fzf and run the install script
Plug 'junegunn/fzf', { 'dir': '~/.fzf', 'do': './install --all' } | Plug 'junegunn/fzf.vim'Plug 'scrooloose/nerdtree', { 'on': 'NERDTreeToggle' }
Plug 'Xuyuanp/nerdtree-git-plugin', { 'on': 'NERDTreeToggle' }"" Initialize plugin system
call plug#end()
```and run `:PlugInstall`
### 6. Explore [Vim Awesome](https://vimawesome.com/) to find plugins