haxelib icon indicating copy to clipboard operation
haxelib copied to clipboard

old versions of libraries still exist after upgraded

Open buckle2000 opened this issue 9 years ago • 3 comments

they take up space

buckle2000 avatar Apr 09 '16 12:04 buckle2000

While this might make sense, I don't think we should make this the default behaviour of the update command, because with haxelib one can use different versions for different compilations.

However, I often feel the need to remove outdated libs too. Let's make a new command for that, e.g. prune, that'll remove old versions of all or a given lib.

In addition we could add --prune/-p argument to the update command, though we don't really have any command-specific switches.

nadako avatar Apr 09 '16 12:04 nadako

Meanwhile, there seems to be this tool just for that: http://lib.haxe.org/p/clearlibs/

nadako avatar Apr 09 '16 12:04 nadako

clearlibs seems to remove anything but the latest version, while prune should keep the set version and any version specified in another lib.

Some linux package manager have an autoremove command that remove packages installed as dependencies but not depended on anymore. But that requires to track manual install vs dependency.

Another good solution would be to track which libraries are used through path (ie. -lib) but that's too expensive.

ibilon avatar Apr 09 '16 13:04 ibilon