gb find unused vendoring dependencies

111 views
Skip to first unread message

Jérôme LAFORGE

unread,
Oct 3, 2015, 4:37:10 AM10/3/15
to golang-nuts
Hello all,
Within project managed by gb, and after lot of testing/refactoring, I want to find unused vendoring dependencies.
Do you know a elegant way to find those unused vendoring dependencies?

Currently, my only way is to rename vendor directory (mv vendor old_vendor), then rebuild the project with (gb build all), and fetch missing dependencies (gb vendor fetch <dependency>) and compare the new vendor directory with old vendor directory.

Thx in adv
Cheers
Jérôme

Dave Cheney

unread,
Oct 3, 2015, 7:08:36 AM10/3/15
to golang-nuts
gb vendor supports a purge command, but I've had some reports that it isn't as accurate as people would like, ie it leaves things.

Jérôme LAFORGE

unread,
Oct 3, 2015, 7:18:06 AM10/3/15
to golang-nuts
gb vendor supports a purge command, but I've had some reports that it isn't as accurate as people would like, ie it leaves things.

Ok, I already tried it, but purge seems only remove entries into manifest when I before removed manually dependency from vendor directory.
If you tell me that it is bug and that purge's goal is to remove the unused dependencies (i.e. source from vendor directory and entry from manifest), it is perfect for me.

thx.
Reply all
Reply to author
Forward
0 new messages