Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

The latest Vim release is awesome!

I compiled it with --enable-luainterp=yes and it does have the Lua feature:

% gvim --version | egrep '\+lua'
+linebreak +lispindent +listcmds +localmap +lua +menu +mksession +modify_fname 

But how do I actually use it? Up until now, I was always using Vim script for my files, but how do I let it interpret Lua? And what are the bindings that I can use from inside Lua?

share|improve this question
I'm assuming you mean vim 7.3? – Gert Aug 31 '10 at 6:24
Of course, silly me... – polemon Aug 31 '10 at 12:12
up vote 7 down vote accepted

So Vim 7.3 is new enough that there isn't much information about the Lua integration. However, vim has had similar support for python, ruby, perl, and tcl. So:

Simple tutorial for python

Another python guide

As well as example tutorials for the other languages, you should definitely read the vim help for Lua, do

 :h lua

to see comprehensive help and some examples. Have fun!

share|improve this answer
Yup, there's not much info about Lua scripting out there, but I can transfer from the Python guides. – polemon Aug 31 '10 at 12:15

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.