Arc Forumnew | comments | leaders | submitlogin
3 points by sjs 6166 days ago | link | parent

> This is the sort of thing that I'd rather just steal from someone else :-)

Me too. ;-)

I've been doing Arc stuff on my Linux box so far, which means mostly Emacs and quick edits in vi. Emacs has great support for parenthesized languages.

In TextMate I'm currently using the lisp bundle, but if I do anything significant on my MacBook I'm probably just going to do it in Emacs. Without Emacs I find lisp somewhat painful to write. For example, in TextMate I cannot choose how many sexps to wrap with then next paren. Say I have this code that I need to wrap with an if:

  (do (some code here))
In TextMate I must place the closing paren manually. Not a big deal in this case, but with more complicated code it can be tedious. Inserting the closing paren automatically in this case is a hassle, not a boon. You get:

  (<cursor>)(do (some code here))
And then you must adjust it manually.

In Emacs (with paredit-mode) I can hit Alt-1 ( and instead of getting "()" inserted, the closing paren wraps the following sexp. Alt-2 ( does the same but wraps the next 2 sexps. So you get:

  (<cursor>(do (some code here)))
And you just keep typing your code.

My advice is to just use Emacs and forget TextMate (for now, for Arc). I like TextMate for non-lisps so don't take this the wrong way. Right tool for the job and all that.

Sorry for the non-answer to your request. Just had to get my 2 cents in I guess.



2 points by projectileboy 6166 days ago | link

No, no... This is helpful; thanks. I don't have any particular love for TextMate - it just seemed the quickest way to point B. (Actually, as a long time Blub programmer, my favorite text editor is IntelliJ. Go ahead and laugh... it's nicer than you think.)

-----

2 points by brett 6166 days ago | link

You can use selection for that in TextMate. If type ( with a block of text selected it wraps that block with parens.

-----

3 points by sjs 6166 days ago | link

That sort of works but still requires manual selection. Regardless there are many more reasons to work in Emacs when using lisp so I'll stick with it. (e.g. inferior-lisp-mode, send files or defs to a running lisp as you edit them)

-----

3 points by tel 6165 days ago | link

Textmate's lack of inferior process panes pretty much cripples it for most rapid iteration, REPL-esque programming in my mind.

-----