+1

WindowCommands are not instantiated until the console or command palette is opened.

Xavura 5 years ago • updated by Kenny Levinsen 5 years ago 1
I was hoping to add an "auto start" feature to one of my plugins. It works but is rendered useless because from what I can tell, a WindowCommand's __init__ method is not called until either the console or command palette is opened.
That's true... Temporary workaround, in an on_new or on_activated event listener, check if you're running, if yes, return, if no, start your service. I'd *expect* someone using sublime to click the window, or open a file at SOME point before requiring your plugins services.