La Vita è Bella

Saturday, May 19, 2007

Add emacs mode line support to vim, and call for help

UPDATE: sfiera took this project over so please head to his github page for this project. Thank you for the awesome work, sfiera!

Different editor configurations, especially tabstops are always pain for co-work. So if everyone uses vim, you can specify some vim instruction to override one's vim configuration in your file, just like:

// vim:tabstop=4:

And if everyone uses emacs, you can also specify emacs mode line like:

// -*- tab-width: 2 -*-

But what about make vim to read emacs mode line? I've wrote a script to do so.

As I didn't use emacs at all, I don't know which instructions can be specified in the emacs mode line. I just wrote a handler for "tab-width" as an example. If you are familiar with both emacs and vim, please help me to add more handlers into this script.

After more handlers added, I'll submit this script to

tags: , , , ,

02:25:41 by fishy - opensource - Permanent Link

Revision: 1.1/1.1, last modified on 2011-03-14 @ 13:55.

Karma: 149 (76.14% out of 285 were positive) [+/-]

You can subscribe to RSS 2.0 feed for comments and trackbacks

There are currently no trackbacks for this item.
Use this TrackBack url to ping this item (right-click, copy link target). If your blog does not support Trackbacks you can manually add your trackback by using this form.

Tom Scogland

Tom Scogland wrote:

I'm in the same boat as you, not knowing many, but c-basic-offset: seems to set sw ts and sts all together, and it's the most used option where I'm working right now, so it might be a good one to look for. indent-tabs-mode seems to be an antonym of expandtab also, if that's nil, expandtab is on, etc. Thanks alot for the useful script!

Saturday, June 07, 2008 03:51:14


fishy wrote:

@Tom: patches are welcome :)

Saturday, June 07, 2008 11:05:50


Patrick wrote:

Found it today - very useful. I might add more when I have time, e.g. filetype.

Thursday, November 05, 2009 21:47:56

Leif Arne Storset

Leif Arne Storset wrote:

See for another script that parses more instructions and is Vundle-compatible.

Thursday, December 06, 2012 16:28:39

Leif Arne Storset

Leif Arne Storset wrote:

Oops, didn't see the note at the top of the page that said pretty much exactly what I said. :)

Thursday, December 06, 2012 16:29:33

Add Comment


May the Force be with you. RAmen