A theme, config and collection of plugins for Neovim
Find a file
Kevin 1c21ca23c9 Updated info in the README as well as adding the mappings for mouse
buttons and the list of plugins. Two extensions that never really got
integrated into the config have been removed, so you should readd them
to bundle.user if you use them. A lot of the keyboard config has
changed, but most of that is just formatting; the additions are the new
mouse button mappings, and the return of shift+middleclick to paste from
X, which was accidentally removed at some point before. I also switched
the default state of the syntax checker to off to avoid having people
run into issues and not already know how to enable/disable it.
2014-04-18 05:12:35 -04:00
vim Updated info in the README as well as adding the mappings for mouse 2014-04-18 05:12:35 -04:00
.gitmodules Updated info in the README as well as adding the mappings for mouse 2014-04-18 05:12:35 -04:00
gentags removed the echo tag I had on the tags generation command for testing 2014-04-05 04:57:08 -04:00
LICENSE Added the MIT license to the project in case it's helpful to be there 2014-04-09 14:32:06 -04:00
README.md Updated info in the README as well as adding the mappings for mouse 2014-04-18 05:12:35 -04:00
update Tweaked the update script to drop the user variables from vimrc into 2014-04-08 03:39:10 -04:00
vimrc Updated info in the README as well as adding the mappings for mouse 2014-04-18 05:12:35 -04:00

Darkcloud Vim Distribution: Theme, Config and Plugins

Requirements

  1. Vim version >= 7.4: It might work on earlier versions but all development and testing has been done here.
  2. Git (optional): Required to clone and update the repository, and pull the plugins as submodules.
  3. CTags (optional): Required to generate tags needed by the tagbar plugin, as well as to have tags provided by auto-completion (ctags website).
  4. Grep and Find (optional): Have grep, fgrep, egrep and agrep (windows binaries), and find and xargs (windows binaries) in $PATH or the vim folder to use the Grep plugin commands.
  5. Powerline Fonts (optional): Needed to enable the fancier looking status line (powerline-patched fonts).
  6. Bash (optional): Used in the update and gentags scripts.

Features

  • A custom theme that includes an original colour scheme and an ever growing collection of explicit syntax colour overrides.
  • A complete default configuration that attempts to provide a useful, easy to use and modern vim experience without becoming bloated.
  • Key bindings and aliases to make useful features more accessible and provide a smoother work flow while attempting to vim's default behaviour while adding behaviour.
  • A selection of plugins chosen either because they improve vim's support for common filetypes, or because they provide value-added features that aren't bloated and manage to make vim more useful as a text editor.

Darkcloud Vim Distribution Theme

Installation

  1. Clone the darkcloud-vimconfig repo and use the update script to install the plugins:
  • git clone https://github.com/prurigro/darkcloud-vimconfig.git
  • sh darkcloud-vimconfig/update
  • Note: The update script requires bash, but if it's not available you can enter the darkcloud-vimconfig/ folder and run: git submodule update --init to install the plugins manually, then create vim/vimrc.user and remember to run: :Helptags once everything else is running.
  1. If you don't know where vim expects to find your vimrc, start vim and run: :version to find the values "user vimrc file" (for a single-user install) and "system vimrc file" (for a system-wide install). T
  2. Copy or symlink the vimrc file from darkcloud-vimconfig/vimrc to one of the locations vim expects to find it, based on whether you want a local or system-wide install, then choose one of the following:
  • Edit the g:darkcloudpath variable in the vimrc file iteself, pointing it to the location you're keeping the darkcloud-vimconfig repo folder.
  • Create a file @ ~/.vim/darkcloud-path.vim and in it put the following: let g:darkcloudpath="/etc/darkcloud-vimconfig", but replacing "/etc/darkcloud-vimconfig" with the path to the darkcloud-vimconfig repo folder.
  • Place darkcloud-vimconfig in the default location @ /etc/darkcloud-vimconfig.
  • Create your own vimrc and have that set the g:darkcloudpath variable before sourcing the included vimrc.
  • Come up with some other solution that fits your setup better than these. :)
  1. Open the vimrc you just installed and either edit the variables in the "USER CONFIG SETTINGS" section, or (preferably) copy them to vim/vimrc.user and edit them there:
  • g:darkcloudpath: Set to the location of the darkcloud-vimconfig folder. (default: /etc/darkcloud-vimconfig)
  • g:autostartfiler: 1 = Start the filer file manager when vim is run and the buffer is empty | 0 = Do nothing when vim is run and the buffer is empty (default: 1)
  • g:autostartchecker: 1 = Check syntax once an appropriate file is loaded | 0 = Check syntax only after syntax checking is toggled on (default: 0)
  • g:autostarttagbar: 1 = Have the tagbar load automatically when a compatible format is run | 0 = The tagbar will stay hidden until triggered on demand with its toggle (default: 0)
  • g:powerlinefonts: 1 = Render the statusline using characters available with powerline-patched fonts | 0 = Render the statusbar with less attractive but more compatible characters available in all fonts (default: 0)
  • guifont: Set to the name of the font you would like to use with gVim followed by the size, making sure to escape spaces and that a powerline-compatible font is selected if the above option is set to 1. (default: Droid\ Sans\ Mono\ 12)
  1. Install ctags (http://ctags.sourceforge.net) to your system using a package and ensure it can be accessed in $PATH, or install support for vim exclusively by copying the ctags binary to the darkcloud-vimconfig/vim folder.

Configuration

  • Custom Configuration: Settings with priority over those set by darkcloud-vimconfig can be added to a file named vimrc.user, located in darkcloud-vimconfig/vim/ or any of the folders in the runtimepath.
  • Custom Plugins: Pathogen compatible plugins can be cloned or extracted to "darkcloud-vimconfig/vim/bundle.user/", or a folder named "bundle" or "bundle.user" in any of the folders in the runtimepath.
  • Custom Snippets: To add or override Emmet snippets, create ~/.vim/snippets.json and add your own definitions using json like shown in the Emmet Documentation.
  • File Associations: To use the file manager in vim to run files with external programs, create "~/.vim/filetypes.vim" and on each line, write an association between a file extension and the program to launch files of that type that looks like: call vimfiler#set_execute_file('mp4','xdg-open').
  • Update Script: (requires: bash+git) Use this to update the project and submodules, as well as handle any required maintenance, generate docs from the pathogen plugins and create missing config scripts with preset values.
  • Generate System Tags: (requires: bash+ctags) Generate a list of ctags for your system libraries in /usr/include and /usr/local/include as well as any folders passed as arguments by running the gentags script.

Mappings

Mouse

Binding Mode Action
Shift-MiddleClick ALL Unbind this from vim so xorg can use it to paste
Ctrl-ScrollUp ALL Scroll right a few characters at a time
Ctrl-ScrollDown ALL Scroll left a few characters at a time
Alt-ScrollUp ALL Scroll right one character at a time
Alt-ScrollDown ALL Scroll left one character at a time
MiddleClick ALL Behaves like right-click (selects to the cursor)
Ctrl-RightClick ALL Copy selection or character under the cursor
Ctrl-MiddleClick ALL Copy selection or character under the cursor
Alt-RightClick ALL Cut selection or character under the cursor
Alt-MiddleClick ALL Cut selection or character under the cursor
Ctrl-Alt-RightClick ALL Paste at the cursor (not mouse)
Ctrl-Alt-MiddleClick ALL Paste at the cursor (not mouse)
Ctrl-LeftClick ALL Select the word being clicked
Alt-LeftClick ALL Select the line being clicked
Ctrl-Alt-LeftClick ALL Select the paragraph being clicked

Keyboard

Todo: For now, check comments at the top of vim/config/keyboard.vim for a list.

Plugins

  • aspnet.vim--Abshire: Syntax highlighting for ASP.NET (asp, aspx etc).
  • breeze.vim: Provides tag matching and navigation shortcuts for HTML.
  • c.vim: C Syntax Extensions for better highlighting.
  • emmet-vim: Support for expanding abbreviations.
    • webapi-vim A web library used by emmet to provide support for custom snippets.
  • grep: Provides the ability to perform various match-based searches using grep.
  • gundo.vim: Sidebar to visualize your undo tree and browse the differences of each change.
  • lightline.vim A light and configurable statusline/tabline for Vim.
  • neocomplcache.vim The 'ultimate' auto-completion system for Vim.
  • ReplaceWithRegister Replace text with the contents of a register (for paste+replace without writing over the buffer).
  • SpellCheck Provides a list of spelling mistakes in the bottom bar that can be clicked to find them in the document.
  • SudoEdit.vim Read and write files without the necessary permissions through the use of sudo.
  • syntastic Uses system compilers and parsers to check syntax either on-the-fly or after saving a compatible document.
  • tagbar Uses ctags to generate a sidebar of the tags for the current file.
  • tcomment_vim File-type sensible comments that can be easily toggled on and off for blocks of text.
  • vim-extradite A git commit browser extending vim-fugitive that displays differences and optionally loads old revisions.
  • vimfiler.vim A curses-style file manager for vim that runs on it's own or in a sidebar and can associate handlers for file types.
    • unite.vim A library used by Vim Filer to help build its user interface.
  • vim-fixkey A set of keyboard mappings that override differences in different environments that might normally break consistency or compatibility.
  • vim-fugitive A wrapper integrating git into vim in such a way as to provide features neither of them could offer on their own.
  • vim-jquery An extension adding highlighting for jquery to javascript syntax.
  • vim-markdown Syntax highlighting, matching rules and mappings for the original Markdown and extensions.
  • vim-move Provides a few convenient ways to move selected text.
  • vim-neco-calc A calculator plugin extending neocomplcache.vim for the on-the-fly auto-completion of simple math equations.
  • vim-pathogen A plugin to load other plugins while keeping them isolated in their own directory structure rather than all dumped together.
  • vim-polyglot A meta-package of what it attempts to ensure are the best syntax plugins for each file type.
  • vim-signify When a version controlled file is changed, this displays a column showing where and how, and allows for navigation to and between differences.
  • vim-surround Provides functionality to exchange surrounding delimiters and xml-style tags with another, or simply remove them.
    • vim-repeat A library used by vim-surround to allow its delimiter-switching functions to be repeated with the . command.
  • vim-systemd-syntax A syntax plugin providing support for systemd unit files.
  • vim-togglelist Supplies toggle functions for the location and error lists, which are used by a number of plugins and normally require separate open and close commands.
  • vim-trailing-whitespace Highlights and allows for the easy removal of trailing whitespace in documents.

Notes

  • Runtimepath: To find the runtimepath locations currently set, run the following in vim: :verbose set runtimepath.
  • Key Bindings: You can find a list of the bindings added by darkcloud-vimconfig, as well as a few of the ones added by plugins in vim/config/keyboard.vim.
  • Vim Quick Reference: Type ??, ?> and ?< to toggle sidebars with three styles of quick reference material on different reference topics.

Credits

License

All projects cloned in the vim/bundle folder are separate and have their own licenses. Everything else is released under the MIT license.