Is it possible to retrieve a list of commands (like what you would see in the command palette) from a plugin?
Thanks
Is it possible to retrieve a list of commands (like what you would see in the command palette) from a plugin?
Thanks
Don’t think that is built in, but you can probably read the sublime-commands files and get whatever information you want. That’s what I do to look at keybindings associated with the various plugins.
That would allow me to get all the plugin commands.
How would you go about getting all the default commands?
Thanks!
So you can get a list of the packages (well the directories) by using the Sublime API. You can then look through those directories for Default.sublime-command files. Those are simply JSON files, so after parsing you can extract whatever information you want from it. The below link is a portion of my code that reads key map files. I want to clean it up some, but let me know if you have any questions.