Sublime Forum

How to open specific project ignoring switch_project window?

#1

Example:
subprocess.Popen(‘subl.exe’, ‘Packages\User\Project\Autohotkey.sublime-project’])

This open in new window instead of switching current view.
How to switch to that project in the same view?

0 Likes

#2

We ran into something similar with building projects for our plugin. Sublime will load a project in a new window if there is an active project or open files. I believe our solution was to close the active project and open files and then run the command to open sublime with the specific project.

window.run_command("close_project") # close the project
window.run_command("close_all") #close all active files

I hope this helps!

-Nick

0 Likes