Hey, this is my blog

It is somewhat abandoned.

Emacs Client on Windows 8

Problem:

I want to use emacs like I use notepadd++ on windows. That is:

  • Right click menu item to “edit with Emacs”
  • Associate file types with emacs (like .org)
  • Have only one emacs open at a time

Here are the steps I took:

  1. Create the context menu like this (global_context_emacs.reg) :

    REGEDIT4
    [HKEY_CLASSES_ROOT\*\shell]
    
    [HKEY_CLASSES_ROOT\*\shell\openwemacs]
    @="&GNU Emacs"
    # The above value appears in the global context menu, # i.e., when you right click on a file.
    # (The '&' makes the next character a shortcut.) "Icon"="C:\\Program Files\\Emacs\\bin\\emacs.exe,0"
    # The above uses the icon of the Emacs exe for the context # and should match the path used for the command below.
    # The ,0 selects the main icon. [HKEY_CLASSES_ROOT\*\shell\openwemacs\command]
    @="C:\\Program Files\\Emacs\\bin\\runemacs.exe \"%1\""
    # The above has to point to where you install Emacs  
  2. Create a batch file called runclientw.bat and compile to exe and associate file types as needed. See here