Git Product home page Git Product logo

dotvim's Introduction

My vim setup

My vim IDE setup for Python, Go, Rust, html, css, javascript, typescript, gettext and more.

make sure to install prettier ` npm install -g prettier `

and follow

https://github.com/maralla/completor.vim#javascript

Features

  • vimrc handling
  • Incremental and smart case search.
  • Sublime Text style multiple selections
  • Trailing whitespace highlightling and cleaning shortcut
  • Logical and Visual layout (for Right-To-Left lanaguegs) editing.
  • Tabs expand to 4 spaces by default
  • Remap `<Leader> to <SPACE> and jj` to ``<ESC>
  • Highlight current row and color column 80
  • 70+ language packs support
  • Syntax checking
  • Snippets
  • Quotes, parens etc pair, surround
  • Extended pair matching with %
  • ASCII drawing
  • Fuzzy file, buffer, mru, tag, etc finder
  • Task list
  • VCS plugins (Fugitive, Lawrencium)
  • Tab completion
  • Commenting

Prerequisites

Vim with Python support.

Usage

The following commands will clone the repo, symlink ~/.vimrc and installs all the files:

git clone https://github.com/codemerlin/dotvim.git ~/.vim ; cd ~/.vim ; chmod +x ./install.sh ; ./install.sh

To add or override settings, place them in ~/.vim/vimrc.local.

To update submodules in the future, when you have vim running, source vimrc to make sure plugins list is updated (or restart vim):

:PlugUpdate

completor.vim

For setting up completor.vim per specific supported language, please see: https://github.com/maralla/completor.vim#completers

Upgrading

In case you're updating from previous Vundle based to vim-plug, remove the bundle directory as it's not needed anymore, get vim-plug and install the plugins:

cd ~/.vim
rm -rf bundle
curl -fLo ~/.vim/autoload/plug.vim --create-dirs \
    https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim
vim +PlugUpdate +qa

Go tags

For CtrlPBufTag search in go lang files, make sure you have an updated version of ctags (>=5.8) and put in your ~/.ctags:

--langdef=Go
--langmap=Go:.go
--regex-Go=/func([ \t]+\([^)]+\))?[ \t]+([a-zA-Z0-9_]+)/\2/f,func/
--regex-Go=/var[ \t]+([a-zA-Z_][a-zA-Z0-9_]+)/\1/v,var/
--regex-Go=/type[ \t]+([a-zA-Z_][a-zA-Z0-9_]+)/\1/t,type/

Overrides

  • ~/.vim/vimrc.before, if exists, is sourced before everything allowing definitions of variables to act upon.
  • ~/.vim/vimrc.local, or ~/.vim/vimrc.after if exists, is sourced after all the files in ~/.vim/vimrc.d allowing override of default settings (e.g: color schemes, plugin configuration, etc.).

Plugins

  • Solarized - color scheme
  • base16-vim - color scheme
  • vim-molokai - color scheme
  • vim-distpach - asynchronous build and test dispatcher
  • Fugitive - a Git wrapper so awesome, it should be illegal
  • Lawrencium - Mercurial wrapper for Vim, inspired by Tim Pope's Fugitive
  • ctrlp.vim - Fuzzy file, buffer, mru, tag, etc finder
  • SuperTab - Insert mode completions with Tab
  • completor.vim - Async completion framework made ease
  • Syntastic - Syntax checking hacks for vim (for vim < 8)
  • ale - Asynchronous Lint Engine (for vim >= 8)
  • UltiSnips - The ultimate snippet solution for Vim.
  • vim-snippets - vim-snipmate default snippets
  • python-mode - Vim python-mode. PyLint, Rope, Pydoc, breakpoints from box
  • vim-go - Go development plugin for Vim
  • rust.vim - provides Rust file detection, syntax highlighting, formatting, Syntastic integration, and more.
  • DrawIt - Ascii drawing plugin: lines, ellipses, arrows, fills, and more!
  • vim-surround - quoting/parenthesizing made simple
  • Shebang - Make executable by setting the correct shebang and executable bit
  • Tagbar - Displays tags in a window, ordered by class etc
  • NERD tree - A tree explorer
  • auto-pairs - Insert or delete brackets, parens, quotes in pair
  • po.vim - Easier editing of GNU gettext PO files
  • TaskList - Eclipse like task list
  • MatchIt - Extended % matching for HTML, LaTeX, and many other languages
  • MatchTag - Highlight matching HTML tags
  • vim-airline - Light weight statusline utility
  • tabular - text filtering and alignment
  • vim-plugin-viewdoc - Flexible viewer for any documentation
  • tcomment_vim - An extensible & universal comment vim-plugin that also handles embedded filetypesludovicchabant/vim-lawrencium
  • vim-unimpaired - pairs of handy bracket mappings
  • vim-multiple-cursors - True Sublime Text style multiple selections for Vim
  • splitjoin.vim - A vim plugin that simplifies the transition between multiline and single-line code
  • vim-repeat - enable repeating supported plugin maps with "."
  • tsuquyomi - A Vim plugin for TypeScript
  • vim-highlightedyank - Make the yanked region apparent!

Shortcuts and re-Mappings

Key Command
jj <Esc> in insert and command modes
<SPACE> <Leader>
<Leader>v Load .vimrc
<Leader>V Activate changes to .vimrc (Make sure to save it before)
<F2> Close current split (window)
<F3> Toggle NERD tree
<F4> Toggle search highlight
<F5> Toggle Tagbar
<Leader>S Remove trailing whitespace
<CTRL>hjkl Window movement commands
<CTRL>arrow Window movement commands
<Leader>d Delete buffer, keep the split
-, + Resize horizontal splits
<ALT>< <ALT>> Resize vertical splits
<F9> Toggle logical (RTL, e.g: Hebrew) editing
<F8> Toggle visual (RTL, e.g: Hebrew) editing
g/ :grep!<Space>
g* :grep! -w current_word
ga :grepadd! (add results to the current search)
gr :CtrlPBufTag (fuzzy tag search in current file)

dotvim's People

Contributors

athakral avatar habeanf avatar meirkriheli avatar mohitt avatar

Watchers

 avatar

Forkers

priyankaace

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.