Lot of time going into this devlog, but it makes sense since I did do a lot.
I did this sweeping refactor of the entire commands module which moved around a lot of code. Essentially each command now gets it’s own directory under the commands module that represents it’s children/parents. For example commands/shim/remove/cmd.go contains code for the mocha shim remove command.
Each cmd.go contains a Command struct that has the relevant fields and functions attached to it. This structure just makes things more organized and also means adding test files will be a bit easier since functionality is now isolated.
I also sorted out the shim binary. So essentially https://github.com/ScoopInstaller/Shim offers different version of the shim binary which can be installed. Previously I hard coded the code to install cpp v0.1.0 but now users can run mocha shim binary releases to see the options and mocha shim binary setup to install their chosen binary. This also means we actually get the latest releases from GitHub.