An open API service indexing awesome lists of open source software.

https://github.com/image357/.vim

.vim folder with vimrc and plugins
https://github.com/image357/.vim

Last synced: 7 months ago
JSON representation

.vim folder with vimrc and plugins

Awesome Lists containing this project

README

          

# .vim
.vim folder with vimrc and plugins

# Clean Setup
```bash
rm -rf "$HOME/.vim" "$HOME/.vimrc" && mkdir -p "$HOME/.vim" && git clone git@github.com:image357/.vim.git "$HOME/.vim" || git clone https://github.com/image357/.vim.git "$HOME/.vim" && bash "$HOME/.vim/setup.sh"
```

# Dependencies
* python3-dev
* golang
* gcc / (g)make / cmake
* clang / libclang-devel / libc++-dev / libcxx-devel
* The Silver Searcher
https://github.com/ggreer/the_silver_searcher

# Plugins
* ack.vim
https://github.com/mileszs/ack.vim
* ctrlp.vim
https://github.com/ctrlpvim/ctrlp.vim
* gruvbox
https://github.com/morhetz/gruvbox
* gundo.vim
https://github.com/sjl/gundo.vim
* nerdcommenter
https://github.com/preservim/nerdcommenter
* pathogen
https://github.com/tpope/vim-pathogen
* YouCompleteMe
https://github.com/Valloric/YouCompleteMe

# References
https://dougblack.io/words/a-good-vimrc.html

# Bindings and Features
The `` key is mapped by default to `comma` which has the same position on international and language specific keyboards.
You can change this setting in `$HOME/.vim/vimrc`.

### Normal Mode
* **` u`**
Advanced undo command with tree structure and incremental diff of every change. Current position is indicated by `@`.
Navigate with arrows or `hjkl`. Press `enter` to apply change. Press `p` to show difference to current position.
Close advanced undo by pressing ` u` again.

* **` a`**
Open a new tab and start a recursive search for a given expression in all files beneath your current working directory.
Hidden files and gitignored files are ignored.
You can view the files by pressing `o` or open them in a new tab by pressing `t`. To close the file browser press `q`.

* **` t`**
Browse all open buffers and files relative to your current working directory.

* **` r`**
If the current file is a python script, run it in an interactive terminal session.
Caution: The file will be written to disk before.

* **` g`**
Goto the function/module/variable definition under the cursor position.

* **` h`**
Open the function/module/variable docstring in a preview window.

* **` `**
Stop highlighting search results.

* **``**
Toogle code folding.

* **` s`**
Save current vim session.

* **` l`**
Load previously saved vim session.

### Insert Mode
* **`jk`**
Leave insert mode and start normal mode.

* **` + `**
Force autocompletion at the current position.

* **``** / **` + `**
Cycle through the autocompletion suggestions.

### All Modes
* **` + /`**
Toggle comments for the selected lines.

### Autocompletion
C/C++ autocompletion needs a `.ycm_extra_conf.py` file in the current directory. If there is none, the default file `$HOME/vim/utility/ycm_extra_conf.py` will be used. Python autocompletion works out of the box, but can use an extra-conf-file (for setting up virtualenvs etc.).