Skip to content

Latest commit

 

History

History
95 lines (70 loc) · 2.13 KB

README.md

File metadata and controls

95 lines (70 loc) · 2.13 KB

vimrc

This .vimrc is a good basic set of utilities to get your vim editor in to a state that is very useful for developing puppet manifests and modules. It maintains a set of defaults that I find useful as well.

OS X Installation

  1. You first need to install brew

    ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
    
  2. Get your PATH set up right and place the following in your ~/.profile.

    export PATH=/usr/local/bin:/usr/local/sbin:~/bin:$PATH:
    

    Once you do this, close all your shells/terminals and reopen

  3. You then need to install macvim to get the YouCompleteMe plugin working. Don't worry, if you symlink the binary to vim/vi it won't load a gui

    brew install macvim
    
  4. Link vim to the macvim binary

    cd /usr/local/bin
    ln -s mvim vim
    ln -s mvim vi
    

Once you do this, close all your shells/terminals and reopen

  1. Get Vundle all set up

    mkdir ~/.vim/bundle
    git clone https://github.com/gmarik/Vundle.vim.git ~/.vim/bundle/Vundle.vim
    
  2. Create your ~/.vimrc file using the .vimrc from this repo or if you're a pro, you can manually cobble it together.

    vim ~/.vimrc
    
  3. Exit vim, reload it, and run :PluginInstall

    #<in vim> :q
    vim ~/.vimrc
    #<in vim> :PluginInstall
    
    # or from the command line
    vim +PluginInstall +qall
    

8. Once it's done its PluginInstall, exit vim, and compile YouCompleteMe.
 You will see an error message generated by YouCompleteMe before you compile
 the requisite portion.

cd ~/.vim/bundle/YouCompleteMe/ ./install.sh --clang-completer


9. Install the appropriate linters and software for python, puppet, ruby, yaml

pip install flake8 gem install puppet gem install hiera-eyaml gem install puppet-lint gem install ruby-lint npm install -g js-yaml


10. You're ready to work with puppet!

#Additional configurations

Always --rebase on a pull

git config --global --bool pull.rebase true

Always use simple pushing

git config --global push.default simple