[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [O] Alfred workflow for org-capture
From: |
Damon Haley |
Subject: |
Re: [O] Alfred workflow for org-capture |
Date: |
Fri, 13 Sep 2013 12:41:04 -0600 |
User-agent: |
Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.3 (darwin) |
In addition to Alfred/Applescript, the Quickkeys application allows once to
directly access emacs keybindings (without emacsclient) and then let emacs
call call apple script to retrieve useful context for org-capture.
My solution is completely stolen from John Wiegley, but it works great.
After calling org-smart-capture with quickkeys, quickkeys calls the
appropriate org-insert functions
from here:
https://github.com/jwiegley/dot-emacs/blob/master/dot-org.el#L534
Quickkeys just needs to know the frontmost application when capture was
called, which is easy to configure, and then it types the relevant org-insert
keybinding.
John, has also written a function called smart-capture that goes directly to
the capture template of one's choice:
https://github.com/jwiegley/dot-emacs/blob/master/lisp/org-smart-capture.el
Quickkeys is also worth its price for automating tons of actions with or
without Apple Script.
Damon
>>>>> Haider Rizvi <address@hidden> writes:
> "Robert P. Goldman" <address@hidden> writes:
>> Does anyone have a workflow for the Alfred Mac app launcher that will
>> interact with org-capture?
> If Alfred can trigger an Applescript, I use the following with Quicksilver:
> Applescript:
> property eclient : "/Applications/Emacs.app/Contents/MacOS/bin/emacsclient
> -n -e " do shell script eclient & "'(make-orgcapture-frame)'"
> elisp in init.el or ...:
> (defun make-orgcapture-frame ()
> "Create a new frame and run org-capture."
> (interactive)
> (make-frame '((name . "remember") (width . 80) (height . 16)
> (top . 400) (left . 300)
> (font .
> "-apple-Monaco-medium-normal-normal-*-13-*-*-*-m-0-iso10646-1")
> ))
> (select-frame-by-name "remember")
> (org-capture))
> Regards,
--
app: https://alpha.app.net/haleyscomet |
net: https://identi.ca/vinylisl |
git: https://github.com/dhaley |
irc: dkh on #drupal-colorado/irc/freenode.net