Open moonglum opened 11 years ago
I think there should be a exo diff
command in the future. It compares the installed packages with the packages from the configuration file.
brew leaves
gives a list of all leaves in the dependency tree. This should be compared to the brews
.ls -a ~ | grep '^\.’
(not sure if that’s helpful)npm ls -g --depth=0
or even with the --json
option (because the —parseable
option is broken)rbenv versions
and filter those with a starrvm list rubies
I think we should implement the diff
method for those managers for which it makes sense. It should never remove packages automatically though IMHO. This should be done in the next milestone though. Moving it now.
If you can detect which NPM Package/Gem has an executable installed, it would make sense to show them. But listing all NPMs/Gems is not very helpful.
Btw: the rbenv version marked with a star is the current used one.
For npm bin files:
1) npm -g bin
returns the bin dir where the executables are installed
2) List that directory and get the link targets of the symbolic links
3) Parse the package out of that directory name, eg ../lib/node_modules/bower/bin/bower
is in the bower package
Could be little fragile but worth a shot.
@bitboxer asked:
This question is in my opinion way broader. Let's take
Homebrew
as an example: If the user decides to remove one of the brews from his list, should the update task now remove this brew? I'm not really sure about that. It is not trivial to detect (just comparing the installed brews and the brews that should be installed doesn't do the trick because of dependencies) – and for other tasks it is almost impossible (Font comes to mind).For Font the question has another facet: If you
teardown
Font, what should happen? Should it remove all fonts it knows? Because it can't detect which fonts it installed by just looking at the files.I think this question needs some thought, and I guess until we found a solution,
update
should not remove brews, fonts, rubies or anything else.