sjl / badwolf

A Vim color scheme.
http://stevelosh.com/projects/badwolf/
MIT License
1.25k stars 226 forks source link

use g:colors_name instead of colors_name #22

Open ressu opened 9 years ago

ressu commented 9 years ago

I was debugging an issue with vim startup colors and noticed that badwolf doesn't set the colors_name properly. Which essentially means that :colorscheme will always return default.

the proper variable to use (according to vim documentation) is g:colors_name and not colors_name as it is currently.

captm0rgan commented 9 years ago

I'm having an issue where vim won't apply badwolf unless I run "colorscheme badwolf" directly instead of having it in my .vimrc. Is this what's causing it?

ressu commented 9 years ago

It's the most likely culprit. If your vim startup (most likely some script) tries to reload the theme, it will load the default theme instead. For me, this shows up when I try to invoke :gui from a terminal vim session.

Let me whip up a pull request for this..

captm0rgan commented 9 years ago

Yeah. That fixed it. Thanks.

Edit: It appears that it didn't fix it. I don't know why it appeared to be working.

captm0rgan commented 9 years ago

So it appears to be dependent on the version of vim. Some of my machines work with the fix, and some don't. It's weird. All well.

ressu commented 9 years ago

There are a few caveats in themes. But I don't think they apply here.. If you aren't using my fork directly, the cause could be that the issue title talks about color_name when it should be colors_name. Other than that, the documentation doesn't mention any limitations on vim versions, so I would assume that there hasn't been any recent changes.