Archive for the ‘emacs’ Category

Using flymake to check erb templates

Friday, November 5th, 2010

Live syntax checking code in Emacs with flymake is extremely useful. It's quite easy to use for syntax checking scripting languages or for running code analysis tools in the background. Flymake's initial goal, however, was syntax checking compiled languages like C by running a ...

Setting default-directory for Mercurial MQ patches in Emacs

Tuesday, July 6th, 2010

Emacs' diff-mode is a great tool to work with patches. You can move inside a patch by files or by hunks, it highlights the changes in each line and you can apply and revert individual hunks. However, diff-mode doesn't work out-of-the-box with Mercurial's MQ extension. To make it work, we ...

Showing the current directory in Emacs’ mode line

Friday, May 23rd, 2008

Today I got tired of always looking up, where all these little files named "_show.rhtml", "_list.rhtml" and their ilk are living, and patched the emacs mode line to include the last element of the current buffer's directory. http://www.emacswiki.org/cgi-bin/wiki/ModeLineDirtrack describes something very similar, but it repeats the whole mode line definition ...

Live syntax-checking JavaScript with Emacs

Tuesday, May 6th, 2008

There are quite some options for doing live syntax checks from within Emacs. A good one is using Steve Yegge's relatively new js2-mode for javascript editing which has a javascript parser built in. But that is not what this blog post will be about. The other option is to use flymake ...