Limp, a Lisp mode for vim

Discussion of programming Lisps using vi or vim
yena
Posts: 12
Joined: Sat Jun 28, 2008 2:33 am

Limp, a Lisp mode for vim

Post by yena » Sat Jun 28, 2008 2:37 am

Hi,

This forum needs some content, so I want to mention that I have been using Limp (http://mikael.jansson.be/hacking/limp/docs/), a lisp mode for vim, for about one month. It is a new software with some bugs, but basically it works well, and I think it is the best solution for those that don't like Emacs. I tried Viper mode on Emacs, but you lose your .vimrc settings, and it is not the same.

findinglisp
Posts: 447
Joined: Sat Jun 28, 2008 7:49 am
Location: Austin, TX
Contact:

Re: Limp, a Lisp mode for vim

Post by findinglisp » Sat Jun 28, 2008 9:49 am

I'm glad to see Limp exist. I'm very much an Emacs user, but it has seemed for too long that the only way to program Lisp in a sensible manner was to use Emacs (with or without SLIME). I'm glad to see vi users getting better tools.
Cheers, Dave
Slowly but surely the world is finding Lisp. http://www.findinglisp.com/blog/

dmgenp
Posts: 13
Joined: Sat Jun 28, 2008 10:15 am

Re: Limp, a Lisp mode for vim

Post by dmgenp » Sat Jun 28, 2008 10:25 am

It works ok, but i didn't find in documentation how to adjust colors or how to switch off automatic closing brace insert. In gvim, when form is highlited after \ec, it becomes unreadable in almost every color scheme. Had no time dig in the source for answers yet.

mikaeljansson
Posts: 5
Joined: Sat Jun 28, 2008 2:09 pm

Re: Limp, a Lisp mode for vim

Post by mikaeljansson » Sat Jun 28, 2008 2:14 pm

dmgenp wrote:It works ok, but i didn't find in documentation how to adjust colors or how to switch off automatic closing brace insert. In gvim, when form is highlited after \ec, it becomes unreadable in almost every color scheme. Had no time dig in the source for answers yet.
The reason for these things not being tunable is becasue I've yet to hear from a user that wants that level of configuration. Basically, I've just packaged what I like -- I am, however, open to suggestions, and I would very much like to hear about suggestions, questions or comments, at [email protected] (http://groups.google.com/group/limp-user).

If you already know what's bugging you, feel free to open a new ticket at http://mikael.jansson.be/hacking/limp/newticket and I'll have a look at it!

Thanks!
--
Mikael Jansson
http://mikael.jansson.be

yena
Posts: 12
Joined: Sat Jun 28, 2008 2:33 am

Re: Limp, a Lisp mode for vim

Post by yena » Sat Jun 28, 2008 4:54 pm

dmgenp wrote:It works ok, but i didn't find in documentation how to adjust colors or how to switch off automatic closing brace insert. In gvim, when form is highlited after \ec, it becomes unreadable in almost every color scheme. Had no time dig in the source for answers yet.
I have specified the color scheme in my .vimrc and edited the color commands manually to make it look ok (in mode.vim), but I agree that it should be easier to configure than editing the source code. If nothing else, it means that I have to do it over and over again every time a new version is released. This are my current settings for gvim using the default color scheme:

Code: Select all

    hi Brackets      ctermbg=53 ctermfg=white 
    hi BracketsBlock ctermbg=235 guibg=lightgray
    hi StatusLine    ctermbg=white ctermfg=160
    hi StatusLineNC  ctermbg=black ctermfg=gray
    hi Pmenu         ctermbg=53 ctermfg=255
    hi PmenuSel      ctermbg=255 ctermfg=53

dmgenp
Posts: 13
Joined: Sat Jun 28, 2008 10:15 am

Re: Limp, a Lisp mode for vim

Post by dmgenp » Sun Jun 29, 2008 10:07 am

yena wrote:This are my current settings for gvim using the default color scheme:
Thanks, i'll try this next time i get my hands on lisp hacking. Sadly, i don't have much time for lisp lately :(

istirbu

Re: Limp, a Lisp mode for vim

Post by istirbu » Mon Jun 30, 2008 2:51 am

Hello,

Is there a way to keep both windows with Lisp and Vim
opened? A realtime view of the output would be great.

BTW, thanks for Limp!

dmgenp
Posts: 13
Joined: Sat Jun 28, 2008 10:15 am

Re: Limp, a Lisp mode for vim

Post by dmgenp » Mon Jun 30, 2008 7:05 am

istirbu wrote: Is there a way to keep both windows with Lisp and Vim
opened? A realtime view of the output would be great.
I' ve done that by manually starting lisp in a terminal:
start:
$LIMPRUNTIME/bin/lisp.sh test -b
connect to it in the running terminal:
$LIMPRUNTIME/bin/lisp.sh test

and then connect from gvim:
press F12, press tab on the prompt

Code: Select all

Connect to [boot new]:
your newly created lisp instance name willl be displayed. press enter, and you will have an independent window with running lisp. Pressing F12 will open another window with the same lisp instance.

mikaeljansson
Posts: 5
Joined: Sat Jun 28, 2008 2:09 pm

Re: Limp, a Lisp mode for vim

Post by mikaeljansson » Tue Jul 01, 2008 12:26 am

istirbu wrote:Is there a way to keep both windows with Lisp and Vim
opened? A realtime view of the output would be great.
Yes. Boot a Lisp (by pressing F12, enter and then give it a name). In the status line, you'll see in parens the name and number of the Lisp process. Then, in another terminal,

$ /usr/local/limp/latest/bin/lisp.sh <number-corresponding-to-the-lisp>

You can also give the name, if you don't have >1 Lisps with the same name.
istirbu wrote:BTW, thanks for Limp!
Thank you. I'm glad you like it. If you find any bugs or issues, file a ticket at http://mikael.jansson.be/hacking/limp/newticket, so I can further improve on Limp!

Also, please consider using the official support forums at http://groups.google.com/group/limp-user -- it makes it much easier for me to track discussions, by keeping them all in a single place.
You can either use the Google Groups web interface, or, if you prefer an e-mail version, [email protected] (subscribe first by sending an e-mail to [email protected]).

Thanks!
--
Mikael Jansson
http://mikael.jansson.be

holygoat
Posts: 2
Joined: Sun Jun 29, 2008 11:07 am

Re: Limp, a Lisp mode for vim

Post by holygoat » Fri Jul 04, 2008 11:24 pm

I thought I'd post some context about how I use Limp. I'm very glad to see it exist — I never got previous vim plugins to work properly.

Firstly, I already had great syntax coloring (I use ps_color), and I couldn't quite fix Limp's bracket highlight to not annoy me, so I just stripped the whole thing out (including deleting highlight.vim).

Secondly, I switched F12 to F1. F12 collides with Mac system keys, y'see, and there seems to be a bug in Limp that causes it to enter the disconnected state every time I (re)open a file, so I find myself hitting that key a lot!

Thirdly, I use ACL rather than SBCL, so I hacked up lisp.sh to pass the correct image arguments, not ask for a version, etc.

When I start up, I actually open a separate Terminal and attach screen there. (Limp starts X11 and xterm, which is not as Mac-friendly... but because it just uses screen, I can kill the xterm without fear!)

With those changes, the only things that get on my nerves are:

* The reloading-limp bug, which was supposed to be fixed but still shows up for me
* The disconnecting-on-edit bug
* That *somehow* Limp has changed indenting in Lisp files. My previous indent system wasn't perfect — custom indents for macros are hard-coded — but Limp seems to do the wrong thing for me all the time:

Code: Select all

(if (thing)
    (cond
     (one 1)
     (two 2))
    (two))
rather than

Code: Select all

(if (thing)
  (cond
    (one 1)
    (two 2))
  (two))
for example. I still haven't found where this is getting set (probably in the bracket completion stuff)... ah well. Fixing that is a low priority.

Thanks for your hard work, Mikael!

Post Reply