Removing projects in Sublime Text 2 and 3

Anto picture Anto · Jul 31, 2012 · Viewed 43.1k times · Source

How do you remove a project from Sublime Text 2 and 3's project windows (Ctrl+Alt+P) ?

Delete has no effect, there is no contextual menu, and deleting the associated files *.sublime-project and *.sublime-workspace doesn't remove the project from the list either.

Any idea? Because this window begins to be cluttered...

Answer

Valjas picture Valjas · Aug 1, 2012

It would be nice if Sublime Text removed projects you've deleted from the recent projects list. Unfortunately, it does not and the list can become littered with projects that no longer exist.

Until Sublime Text offers this feature there are a couple of manual ways you can remove projects.

Option 1: The quick way (Clear All):

If you're just looking for the fastest way to clean up your list this option is for you.

Please be aware that this will clear out all projects in the recent list. This includes ones you have not deleted.

In the Sublime Text menu goto:

Project > Open Recent > Clear Items

enter image description here

Option 2: The manual way (but with control of which projects are removed):

  1. Close Sublime Text
  2. Locate the Session.sublime_session file using the paths below and open it with another code editor. * DO NOT open it with Sublime Text as any changes you make will be overwritten. *

    Paths to Session.sublime_session file listed by OS and ST version:

    Windows x64:

    Sublime Text 2

    C:\Users\[Username]\AppData\Roaming\Sublime Text 2\Settings\Session.sublime_session

    Sublime Text 3

    C:\Program Files\Sublime Text 3\Data\Local\Session.sublime_session

    Mac OSX:

    Sublime Text 2

    ~/Library/Application Support/Sublime Text 2/Settings/Session.sublime_session

    Sublime Text 3

    ~/Library/Application Support/Sublime Text 3/Local/Session.sublime_session

    Linux (Ubuntu):

    Sublime Text 2

    ~/.config/sublime-text-2/Settings/Session.sublime_session

    Sublime Text 3

    ~/.config/sublime-text-3/Local/Session.sublime_session

    What to expect to see:

    You should see something like the following at the bottom of this file:

    enter image description here

  3. Remove the unwanted project(s) from this file

    What the file would look like after deleting project3:

    enter image description here

  4. Save and re-launch Sublime Text 2/3

Option 3: The plugin way

You can check out the Sublime Text plugin Project Manager.

Option 4: The Node.js way

You can check out: clean-sublime-text-project-history