Sublime Forum

What is the best way to extend an existing plugin so users only need to add a repo to their addon list?

#1

As some of you know I’ve been working on XCodeMapper ( soon to have a non-dev name in which case I’ll either end up forking and making a stand-alone addon, or committing to remaining an addon ) which is a modification to CodeMap by oleg-shiro which adds a panel and basic support to navigate through code. My extension makes adding things to look for a lot easier, add entries easier, adds category support and nested categories and multiple view-output types and many many many callbacks to modify how found-code is interacted with before being output…

Right now the repo is set up for manual install and to make it easier for the end-user to know where to install files… I have the repo set up starting in %AppData%/ named AppData/Sublime Text 3/Packages/ some files in here to add extra highlighting support and now a bugfix for CodeMap then User/CodeMap/ my files and main install here…

Ideally I’d like to have the repo set up as an addon so it extracts directly to Packages/CodeMap/ so User/CodeMap/ can be user for other methods… I’d also like the ability to modify other packages so would I just set up the root directory to contain CodeMap/, PHP/, Python/, JavaScript/, GMod Lua/, Lua/, etc? in order to add the files to Packages/CodeMap/ and the other folders? Or how would I go about doing that?

Additionally, package control is odd - the setup instructions are wonky… I’m supposed to fork my repo, clone it, do something, then push it? and then run it in order for Package Control to list it?
If I set CodeMap as a dependency then CodeMap will be extracted - which is fine ( but then can I modify files from it? )

There are so many unanswered questions and searching for modifying existing plugin, editing plugin, etc… returns nothing really related…

So… If it isn’t possible to do what I want then I need to create a new plugin and reinvent a wheel that has already been made - I do like having the extra control though because I can ensure bugs are patched immediately instead of waiting and I can use my coding standards for the development of it along with adding features I’d like to see…

I’m still reading up on using Package Control to extend the CodeMap plugin which is currently the goal… Hopefully it’ll give me all of the functionality I need… Any help with this is much appreciated along with helping modify multiple plugins at once without them needed as dependencies!

Worst case I’d go for is, instead of being on Package Control, to have the users add my repo using Package Control and the files being automatically added to either Packages/CodeMap/ and the other folders, or Packages/*/ plus Packages/User/CodeMap/ - hopefully the repo can be designed to do that because right now the CodeMap repo looks like the root dir is INSIDE of CodeMap instead of CodeMap being nested…

0 Likes