_Emacs in XCode_

Last modified on : 21.09.2009

I'm an Emacs lover. I use Emacs every day. I use it on all my computers, even on this server. So, Emacs lovers, don't hate me for what follows...

I've becoming more and more serious about developping a Macosx cocoa app. In a first stage I've set up Emacs to be the default editor. Allthough Emacs can be configured to enable some kind of auto completion, it can't do it as XCode does. As I don't know all the Cocoa framework class methods, I switched the editor back to XCode.

I really miss some key features in XCode, but I had to stick with it. Well, that's what I presumed, until I started digging around...

This was a very nice help !

MacOSX works with Keybindings.dict files to set keybindings and the default system text editor functions does support features as : kill ring ! However it is not bound to any key and by the way, the kill ring is set to 1 (which means no kill ring at all).

These are the steps to enable this (works on SnowLeopard, but should be working on previous versions also - untested):

You're done! Happy emacs Xcode !

_Emacs git mode_

Last modified on : 27.09.2008

I've stumbled across this nice tutorial. With the mentioned emacs-git mode you can checkout a branch which is not available in the emacs-mode joined in the official git repo. Nice stuff there !

_Emacs mail snipping out_

Last modified on : 10.09.2008

Here is a function that will kill the marked region and replace it with "[..]". Very usefull when replying to long messages.

 (defun snip-region-for-message ()
        "Snips the selected region of an included message."
        (interactive)
        (delete-region (point) (mark))
        (if (not (zerop (current-column)))
            (newline))
        (insert "[..]")
        (if (at-end-of-line-p)
            (progn
                    (forward-line 1)
                    (beginning-of-line))
            (progn
                    (newline)
                    (insert message-yank-prefix)))
        (beginning-of-line))

_my first org-mode setup_

Last modified on : 24.07.2008

So I started the orgmode setup. I use the latest stable version 6.05b. I could have used the development version out of the git repo, but for this kind of applications I'd rather use released versions. This helps in isolating bugs.

This is my first starting setup :

 (add-to-list 'load-path "/Users/ec/emacslisp/org-6.05b/lisp")
 (add-to-list 'auto-mode-alist '("\\.org\\'" . org-mode))
 (global-set-key "\C-cl" 'org-store-link)
 (global-set-key "\C-ca" 'org-agenda)
 (setq org-agenda-files (file-expand-wildcards "~/org/*.org"))
 (setq org-todo-keywords
       '((sequence "TODO" "MAYBE" "STARTED" "|" "DONE")
         (sequence "ASK" "BUY" "|" "DELIVERED")
         (sequence "|" "CANCELED")))

_moving from planner to org-mode_

Last modified on : 23.07.2008

For the past 3 years I've used planner-mode to organize my projects and todo-lists. The feature I do like most is the possibility to link a task to more than one project. That makes it possible not to have to copy tasks around project files as it is required by org-mode.

However there's a negative point to planner-mode. There's no archiving feature in planner. That makes my ~/Planner directory have files dated from 2005 which I won't ever need. Since files have links to each other through tasks, I never deleted those files, fearing that I might corrupt data. Org-mode doesn't need an archiving feature, since once a project is finished, you can just move that project out of your org-directory.

It did take me some time to decide to move to org-mode. Now I'm making the effort of planning the transition from planner to org-mode. This doesn't seem as easy as it sounds since I actually have found no other way than check every single project I have in Planner (covering more than 3 years of data !). If anyone has a better idea, please let me know :)

When evaluating org-mode I've been through this nice tutorial. Also I've watched this screencast.

The orgmode site lists all these and more tutorials/screencasts etc.

_emacs info_

Last modified on : 21.07.2008

Don't know about Emacs ? Take a look here

home ©2008 erik colson

_keywords_

ALL
canon
catalyst
emacs
finance
geniustrader
git
info
macosx
nginx
orgmode
perl
photo
taskjuggler
wxperl
xcode