Just above I posted asking if there was a way to see what addons had a dependency on a selected var file. The issue was that if I removed something I didn't want to break something else. Since there didn't seem to be a way to do it I created one.
Dependency Viewer is a C# program that queries all the var files in a specified AddonPackages directory recursively and attempts to determine who depends on a selected var file. Once this is done the user can select a var file in the UI and can see which other vars have it as a dependency. I use the word "attempt" here because more than a few vars come out with broken meta.json files and while I have attempted to catch all the errors this can cause you may find you have issues.
There is help available in the form of text/html document and an image indicating the steps you need to follow to scan a directory. I will try to help where I can but I've got limited time to spend on this, I wrote it for myself and decided to share. The application produces a log which it overwrites on each run if you want to try to track down problematic vars.
The full source is provided so you can compile it yourself (C# VS2017) or scan it for viruses if you so wish. The only external libraries it uses are Newtonsoft JSON and NLog.
Limitations
So yeah, knock yourself out if you think you can get some use out of it.
Dependency Viewer is a C# program that queries all the var files in a specified AddonPackages directory recursively and attempts to determine who depends on a selected var file. Once this is done the user can select a var file in the UI and can see which other vars have it as a dependency. I use the word "attempt" here because more than a few vars come out with broken meta.json files and while I have attempted to catch all the errors this can cause you may find you have issues.
There is help available in the form of text/html document and an image indicating the steps you need to follow to scan a directory. I will try to help where I can but I've got limited time to spend on this, I wrote it for myself and decided to share. The application produces a log which it overwrites on each run if you want to try to track down problematic vars.
The full source is provided so you can compile it yourself (C# VS2017) or scan it for viruses if you so wish. The only external libraries it uses are Newtonsoft JSON and NLog.
Limitations
- I don't attempt to resolve ".latest" dependencies into the actual version number you have installed. In fact this program doesn't care if you have a dependency installed or not. It just uses the metadata in the var files.
- I don't check dependencies of dependencies. Realistically if you have it installed I should pick it up when I scan the dependent var file. Maybe sometime in the future.
- This may be slow if you have a lot of addons. My AddonPackages directory is 50GB and it takes about 5 seconds.
- Plenty of other limitations I'm sure, this has only been tested against my install, my day job is not as a programmer, C# is not a language I'm strong with and this was written over a two day period.
So yeah, knock yourself out if you think you can get some use out of it.
You must be registered to see the links