Installing Powerline on OS X + homebrew

In: Programming

27 Oct 2013

I’ve always wanted to get that fancy Powerline status bar and prompt. Chevrons and git branch icons in the terminal just sounds so… defying:

Powerline screenshot

I’d failed to get it working properly before because of a combination of outdated Powerline docs and confusion between OS X’s system python/vim and homebrew’s python/vim. Some of my former colleagues detailed the pains and hours lost getting Powerline setup, so I gave up.

Anyway, I got a new Mac for work recently and decided to try again, and it was easier than I thought. You (including you, future Chu Yeow) can use this guide if you’re using homebrew to install vim and python (and everything else like zsh and tmux).

Installing Powerline on OS X

  1. Install python with homebrew: brew install python
  2. Install vim with homebrew: brew install vim --env-std --override-system-vim. You must install vim after python so that it’ll compile with homebrew’s python.
  3. Install powerline with pip: pip install Powerline should get installed to /usr/local/lib/python2.7/site-packages/powerline.
  4. open /usr/local/lib/python2.7/site-packages/powerline – you should see the files required for integration with zsh, vim, tmux, etc. in the bindings directory. All you need to do now is to include these bindings in your zsh, vim and tmux config files – it’s that simple!
  5. Add Powerline to vim by adding these lines to ~/.vimrc:
    source /usr/local/lib/python2.7/site-packages/powerline/bindings/vim/plugin/powerline.vim
    set laststatus=2
  6. Add Powerline to tmux by adding this to ~/.tmux.conf:
    source /usr/local/lib/python2.7/site-packages/powerline/bindings/tmux/powerline.conf
  7. Add Powerline to zsh by adding this to ~/.zshrc:
    source /usr/local/lib/python2.7/site-packages/powerline/bindings/zsh/powerline.zsh

    If you use oh-my-zsh, be sure to source the Powerline bindings after oh-my-zsh’s.

  8. Grab a patched font from (I use Inconsolata), and install it (just download, double-click the font file, and Install). If you don’t use any of these fonts, you’ll have to patch your favorite font yourself (have fun with that!)

That’s all you need! Go crazy and start tweaking your Powerline colorscheme.

9 Responses to Installing Powerline on OS X + homebrew



October 29th, 2013 at 9am




October 30th, 2013 at 10am

This was a nice, simple resource. Thanks! The directions at step 3 appear to be different now, though. Unless I did something wrong… Powerline now seems to install at `/Library/Python/2.7/site-packages/powerline` instead of `/usr/local/lib/python2.7/site-packages/powerline`.


Chu Yeow

October 31st, 2013 at 11am

Hey Paul, if Powerline gets installed to `/Library/Python/2.7/site-packages/powerline`, I suspect `pip` is using system Python (or you might very unlikely have configured your site-packages path). You might wanna see if you can get it under `/usr/local` if sandboxing the Powerline install with homebrew is important to you.


Koen Van der Auwera

October 31st, 2013 at 5pm

Nice to see you’re back! :)



April 13th, 2014 at 7am

What is the benefit of installing vim through homebrew when it’s already installed on the Mac? Is it just so it uses the correct version of python? Can you not set the existing version of vim to use the brewed python?


clumsy ninja hack cydia

May 26th, 2014 at 9pm

Hi there! I could have sworn I’ve been to this blog before but
after checking through some of the post I realized
it’s new to me. Nonetheless, I’m definitely happy I
found it and I’ll be bookmarking and checking back often!


valentino bow pumps

June 15th, 2014 at 11pm

I’ve circumstances used one pannier,mens christian louboutinPorter Cable offers a Deluxe Plate Joiner Kit with an effective 7.5 built in amplifiers and 10,000 rpm. (Outer diameter) Dust port that mutually standard bags or can simply hook up to a vacuum. The DW682K has a fence tilt of 0 to135 degrees with a positive protective stop at 90 degrees; further, The bale handle is attached to the fence (instead of the motor) For increased permanence and control while cutting. The short twoturn helix 2 i


nike free run 3 tiffany blue for sale

June 28th, 2014 at 3pm

beyond The 40yearold have already been designed providing some one an all in one highlightreel stop and motivate an all in one Conor Casey header exceeding combination tavern Withinside going to be the Sounders’ at the outset program attributed for more information about the saying take going to be the leading a member midfielder Freddie Ljungberg he is under get more information at avenues to understand more about make for they,where to buy tiffany blue nike free run 3, Seattle attained it appe



July 1st, 2014 at 12am

Thanks for this! I really didn’t want to install MacPorts just to get powerline…

Comment Form