Skip to content

cedarcode/cedarvim

Repository files navigation

cedarvim

Prerequisites

  • Vim 7.4+ (8.0+ recommended)

Installing

$ git clone https://github.com/cedarcode/cedarvim ~/.vim
$ cd ~/.vim
$ git submodule init
$ git submodule update

Updating

$ cd ~/.vim
$ git pull
$ git submodule update

Features

Navigation

  • <C-p> to quickly search and open files and more via ctrlp.vim package
  • <C-b> to quickly go back to recently opened files
  • <C-n> to open/close file explorer and more via nerdtree package
  • <C-\> to search for all occurrences of the current word under the cursor in every file

Git

  • Full git integration
    • :Ggrep to search the work tree with git grep among many other features via vim-fugitive package
    • :Gbrowse to open files/commits/etc in GitHub via vim-rhubarb package
  • Shows a git diff in the "gutter" (sign column) of the editor, [c and ]c key mappings available to navigate diff hunks and more via vim-gitgutter package

Ruby on Rails

  • bundler wrapper, e.g. :Bundle to run bundle, gf (go to file) works in Gemfile.lock, among other features via vim-bundler package
  • rails integration, e.g. gf for partials and others, :Rails console, :Generate controller Blog, among many other features via vim-rails package
  • Auto adds end after if, do, def and several other keywords via vim-endwise package

Other

  • gc or gcc (depending on mode) to toggle source code commented state and more via vim-commentary package
  • Highlights trailing whitespaces in red and provides :FixWhitespace to fix it via vim-trailing-whitespaces package
  • Several default settings recommended by @tpope via vim-sensible package
  • 20+ key mapping/shortcuts recommended by @tpope via vim-unimpaired package
  • Shows line numbers by default
  • Uses 2-spaces indentation by default
  • Uses system clipboard by default
  • Mouse/trackpad enabled in all modes by default
  • <C-Up> and <C-Down> to move text lines up and down easily, in both normal and visual modes
  • *.swp files kept in hidden location to avoid dirty directories
  • Persistent undo and redo. E.g. You can undo after closing and reopening vim.

Your own customizations

Put any extra configuration and/or overrides in ~/.vimrc.after. cedarvim will pick them up automatically.

Adding new plugin

$ cd ~/.vim
$ git submodule add <plugin-git-url> pack/cedarvim/start/<plugin-name>

Removing a plugin

$ cd ~/.vim
$ git submodule deinit pack/cedarvim/start/<plugin-name>
$ git rm pack/cedarvim/start/<plugin-name>

About

Simple yet powerful vim distribution 🌿

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published