Open in Emacs Finder Button

September 6th, 2012  |  Published in mac and iphone  |  1 Comment

Emacs button

 

So, Dr. Drang wrote (or adapted, anyhow) this handy little “open in BBEdit” button for Finder windows, and I found it intriguing because I wouldn’t mind something similar for Cocoa Emacs at all. On review of what, exactly, the button entailed, I decided I could take Dr. Drang’s work and make a working knockoff (or, as we say in Apple fandom, “samsung it”) over lunch.

After a few minutes with Icon Composer and a few more poking at the AppleScript that drives the button (see where my priorities were?), I had enough to put up on Github, where I bet you can make it better.

Here’s the README:


A very quick, still incomplete adaptation of Dr. Drang’s “Open in BBEdit” button for the Finder toolbar.

This works with the Homebrew’s Cocoa build of Emacs.

Instructions

  1. Download and drag into your Finder toolbar
  2. Select file(s), click button, see files open in new frames in your Emacs app. If you’d rather they open in new buffers, add this to ~/.emacs:

(setq ns-pop-up-frames nil)

If you haven’t selected any files, it should open the directory represented by the Finder folder you’re in in dired.

TODO

  • wait for things to break because this was done very quickly

Responses

  1. lawlist says:

    April 17th, 2013 at 7:19 pm (#)

    (setq ns-pop-up-frames nil) Thank you very much — greatly appreciated !!! One of the first immediate easy solutions I’ve encountered in a few days of toil and growing pains with Aquamacs and Emacs variants — what a nice change of pace.

Leave a Response

© Michael Hall, licensed under a Creative Commons Attribution-ShareAlike 3.0 United States license.