Page 1 of 2

LOVE and vim

Posted: Mon Jun 22, 2009 4:27 pm
by jcw
Just wondering how people using vim to code lua and LOVE get things done.
I jump around by searching, but has anyone gotten folding or a function/class browser to work?

I've mapped ",l" to "!open .", which in OS X runs the game. Every time I make an edit, I just hit ctrl+x (mapped to :w!) and ,l, which saves and runs the game very quickly.

Re: LOVE and vim

Posted: Mon Jun 22, 2009 8:02 pm
by qubodup
I probably use as much of vim's capabilities as I do of my brain and I'm also afraid of reading manuals :|

I did read a vim noob guide a while ago where folding was mentioned - apparently it works out of the box. I suppose http://www.vim.org/htmldoc/fold.html will have a detailed answer. http://www.linux.com/archive/articles/114138 has a cheat sheet.

Re: LOVE and vim

Posted: Tue Jun 23, 2009 5:22 am
by mike
I use vim at work sometimes... I know how to use :wq and :q!. I'm not much of a hacker :(

Re: LOVE and vim

Posted: Tue Jun 23, 2009 7:01 am
by Sardtok
Yeah, I'd go with Mike.
I only use vim for some simple text editing.
For code I'd much rather use emacs, or a proper GUI-based IDE.

Re: LOVE and vim

Posted: Tue Jun 23, 2009 9:28 am
by appleide
I'm with mike too. I'd much rather use Smultron. I use vim occasionally in uni though, only because I had to use putty on windows.

Sardtok: do you know LISP?

Re: LOVE and vim

Posted: Tue Jun 23, 2009 12:58 pm
by mike
appleide wrote:LISP?
KILL IT! KILL IT WITH FIRE!

Re: LOVE and vim

Posted: Tue Jun 23, 2009 12:59 pm
by bartbes
I use vim most of the times, I love the way indenting just works. Anyway, I don't know how I set it up, but I enabled auto-syntax-highlighting and auto-indenting and all I need to do now is :w :q :wq and :q!.

Re: LOVE and vim

Posted: Tue Jun 23, 2009 6:37 pm
by Sardtok
appleide wrote:I'm with mike too. I'd much rather use Smultron. I use vim occasionally in uni though, only because I had to use putty on windows.

Sardtok: do you know LISP?
Nah, I've never looked into it. It looks like it has an interesting syntax, though.

Btw. if you have a good connection to your uni, you could use an X server and just have putty automagically export $DISPLAY to your machine.
I use vim whenever I need to do a quick edit, on my proxy, at work, and sometimes at uni, but for anything extensive… … Yeah, you know.

Re: LOVE and vim

Posted: Tue Jun 23, 2009 11:09 pm
by subrime
vim only good for simple text editing...

what is coding if not simple text editing?

Re: LOVE and vim

Posted: Wed Jun 24, 2009 9:06 pm
by Sardtok
Coding is complex text editing.
I can't imagine working on a project with many files at the same time in vim, I'm sure it can handle multiple buffers like emacs, but I prefer a tabbed text editor/IDE for that.

And btw. I've never had to do any setting up to get colouring in vim. It just works out of the box (but there's probably some config file that comes with the vim package).
I actually use it quite a lot at work, so I can read strings in one localization file while translating another, and the G command (go to line) comes in handy with xargs grep -in fed by find.