Vim Tip: Fix plugin loading error “Not an editor command: ^M”

This post is a preservation of the now inactive:

One of the most annoying errors you probably already encountered  with Vim terminal (not GVim) on Windows when you use Vim plugins that were obtained through Git (via plugin manager like Vundle, Pathogen, etc.) is this kind of error message:

E492: Not an editor command: ^M
line    9:
E182: Invalid command name
line   10:
E492: Not an editor command: ^M
line   12:
E182: Invalid command name
line   13:
E492: Not an editor command: ^M
line   15:
E182: Invalid command name
line   16:
E492: Not an editor command: ^M
line   18:
E182: Invalid command name

This error is reported and asked so many times on StackOverflow and GitHub, and the answers provided are mostly about removing the special character or setting file format to “unix”. However, that wouldn’t solve the problem.

It took me a very long time (I gave up many times) to finally find out the solution through this GitHub issue on Vundle. It wasn’t something many people would expect. Turned out Git’s default setting to deal with line endings is not sufficient.

All you need to do is to config your Git correctly before cloning Vim plugins:

$ git config --global core.autocrlf input

That’s it. Now you can install Vim plugins like normal.

For more information about the above Git setting, see here.

Future of Dark Room

Much has changed in the years since Dark Room was originally written, and there are many options available at this time. Thus, the question to be asked is, does continued development of DR make sense? I spent a significant amount of time rewriting the application from scratch to run as an adobe air application. I did this because I was no longer using windows at the time, so dedicating some much time on a .net application did not make a lot of sense, thus a cross platform solution seemed more desirable. Unfortunately, Adobe dropped linux support shortly before the first beta release of the new program. So, I essentially stopped development on it.

I still want to have a cross platform application. I began trying to find new viable options, and I was just about to start a write up in python when I discovered FocusWriter. It is a cross platform distraction free environment, and it uses QT. It’s written in C++, which I don’t really like, but I could deal with it. I would almost say it is enough to use FocusWriter, but it is missing some key functionality from Dark Room I couldn’t live without. Therefore, at this point I am seriously considering forking FocusWriter in order to add in the additional Dark Room functionality.


Effects of Magic on the Real World

One of the major issues I have associated with fantasy settings is that a world filled with magic is essentially medieval plus wizards. It seems even more silly in the context that many settings purport to be thousands of years old. So, what I want to do is make a basic game that could help model the effects magic on an otherwise realistic world.

Originally, I was thinking about setting this up in the ancient / dark ages since my interest is primary on the fantasy realm. Player knowledge would become a significant hindrance though. Effectively players would have unfair knowledge about technological development that could be leveraged with magic. In order to deal with the problem, the game should likely be set in modern day.

I am thinking of setting up a small self contained scenario for this, kind of like Lady Blackbird, with pregens. I want to keep the characters disassociated from the players in order to avoid weirdness. The scenario would kick off when the group uncovered a set of “items of power.” That essentially give those in possession of the items the ability to wield magic. Magic should not be limited in functionality, other than the final result of the effects cannot create paradoxes.

The question becomes, how to model the interaction of magic within the world. I’m thinking a basic die mechanism that can be used to measure the degree of success when attempting to use magic for something. And, while the player always succeeds, their margin of success determines the level of complication created by the act. Complications would scale relative to the effect desired.

As far as complications are concerned, I am thinking about creating some tables that could be rolled against in order to generate some ideas. But, complications that are directly relevant would be preferred. The trick of the matter is trying to figure out how something like, an unlimited supply of free gasoline would affect the world.

What would be the best way to model such a thing?

Screaming Fast, Like its 2004!

Due to the death of my good computers, I have found myself relegated to my PowerMac G5. Surprisingly this machine is stilling going strong. Fortunately, I had replaced the video card, and maxed the ram a few years ago.

But, the hard drive in this thing was so freaking loud that something had to be done. I debating getting a newer drive on the hope that it would be quieter, but decided to bite the bullet and just get a solid state drive. Now that I have run it for a couple of days, I have to say that this machine is running as fast as it possibly can. Which means it is actually quite useable. IO operations are pretty good, the age is really only noticeable on CPU intensive activities.