Sublime Forum

Bug with the context menu option

#1

I’ve notice a small but somewhat annoying bug with the ‘Open with Sublime Text’ context menu option.

When ever you open a file with this option, with Sublime closed, it seems to throw away the session data. Is there anyway to have it tack it on so to speak to the last session when ever you open a file this way?

0 Likes

#2

If you exit via ‘Exit and preserve session’, then your session will be restored and the file opened. Alternatively, you can put --restore on the command line to make it always happen.

There’s likely a good argument for this to always happen, but then again, some people don’t even like the last set of files opening on a normal startup.

0 Likes

#3

Ah ok. I always just exited by right clicking and choosing close and if I just opened Sublime again normally the session was preserved so I wasn’t aware that it wasn’t already doing it.

Also where exactly should I add ‘–restore’ to enable this permanently?

0 Likes

#4

change the path for your sublimetext.exe, save to a .reg file, and double click to import into registry

[code]Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT*\shell\Open with Sublime Text\command]
@="d:\bin\editors\sublime\sublimetext.exe --restore “%1"”

[/code]

0 Likes

#5

Thank you very much!

0 Likes