Shortcut/"Open with" Sublime Text, in a new Sublime window

This works for me (and is more comfortable for me than the Open with submenu):

  1. Open regedit.exe
  2. navigate to HKEY_CLASSES_ROOT\*\shell
    To apply this only to certain file types replace the * with the appropiate extension
  3. Add key "Open With sublime in new window"
  4. Inside this, add new key "command"
  5. Inside "command" set the (Default) string to:
    C:\Program Files\Sublime Text 2\sublime_text.exe -n "%1"

(basically copy the original keys, adding the -n)

  1. Optional:
    Inside the key "Open With sublime in new window", add a string named Icon:
    C:\Program Files\Sublime Text 2\sublime_text.exe,0
    This will add an the Sublime Text icon to the left of the command on the right-click menu.

To add the entries to the context menu for folders, add the same entries in:

  • HKEY_CLASSES_ROOT\Folder\shell
    For the context menu when you click on a folder icon
  • HKEY_CLASSES_ROOT\Directory\Background\shell
    For the context menu when you click on the background of a folder
    For this entry you must replace "%1" with "%V" (Thanks Filip)