Giter VIP home page Giter VIP logo

vimfiles's Introduction

Gerardo Curiel Vimfiles

I'm @gerard0, and this is my ~/.vim directory.

Installation

$ git clone git://github.com/gerardo/vimfiles.git ~/.vim

Create symlinks:

$ ln -s ~/.vim/_vimrc ~/.vimrc
$ ln -s ~/.vim/_gvimrc ~/.gvimrc

Switch to the ~/.vim directory, and fetch submodules (mostly just Neobundle ):

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

And you're good to go!

Updating to the latest version

To update to the latest version of the vimfiles, just run a git pull from your ~/.vim directory:

$ git pull origin master

Pre-requisites

It requires the_silver_searcher, ctags, git, and curl . The recommended way of installing them is using Homebrew on OSX. On Linux, you can use your distribution's package management system.

Take a look at the Pre-requisites wiki page for more information. If there's any missing, please open an issue.

Intro to VIM

In case you've never used VIM before, here are some links and info worth reading:

Features

The vimfiles comes with some predefined plugins and base customizations:

  • Line numbers
  • Show trailing whitespace as ¬ and tabs as
  • Airline-enabled status line
  • <leader>w opens a new horizontal split
  • <leader>ww opens a new vertical split
  • Remapped arrow keys to hjkl. Why? Read on
  • <C-W>! invokes kwbd plugin; it closes all open buffers in the open windows but keeps the windows open

NERDCommenter allows you to wrangle your code comments, regardless of filetype. View :help NERDCommenter for all the details.

NERDTree is a file explorer plugin that provides "project drawer" functionality to your vim projects. You can learn more about it with :help NERDTree. Use Ctrl+E,Ctrl+E to toggle NERDTree

Ack.vim uses ack to search inside the current directory for a pattern. You can learn more about it with :help Ack.

Fuzzy file, buffer and mru finder.

Syntastic is a syntax checking plugin that runs buffers through external syntax checkers as they are saved and opened. You will need to install the required syntax checkers.

EasyMotion provides a much simpler way to use some motions in vim. It takes the <number> out of <number>w or <number>f{char} by highlighting all possible choices and allowing you to press one key to jump directly to the target.

When one of the available motions is triggered, all visible text preceding or following the cursor is faded, and motion targets are highlighted.

Narrowing means focussing on a region and making the rest inaccessible. You simply select the region, call :NarrowRegion and the selected part will open in a new scratch buffer. The rest of the file will be protected, so you won't accidentally modify that buffer. In the new buffer, you can do a global replace, search or anything else to modify that part. When you are finished, simply write that buffer (e.g. by |:w|) and your modifications will be put in the original buffer making it accessible again.

Fugitive adds pervasive git support to git directories in vim. For more information, use :help fugitive

Use :Gstatus to view git status and type - on any file to stage or unstage it. Type p on a file to enter git add -p and stage specific hunks in the file.

Use :Gdiff on an open file to see what changes have been made to that file

There are more plugins included. Check its homepages for more information.

Feedback

Suggestions and improvements welcome!

License

This code is free to use under the terms of the MIT license.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

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.