kisielk / godepgraph

A Go dependency graph visualization tool
MIT License
1.05k stars 90 forks source link

remove vendor prefix when storing packages #21

Closed davcamer closed 6 years ago

davcamer commented 6 years ago

This standardizes vendored packages so that they can be found using the string from another package's .Imports list.

This addresses the issues I described in #10.

I believe vendor/ is a safe token to split on, based on this passage in the documentation:

Code below a directory named "vendor" is importable only by code in the directory tree rooted
at the parent of "vendor", and only using an import path that omits the prefix up to and including
the vendor element.
kisielk commented 6 years ago

Is something wrong with the GitHub diff, or with the commit? It looks like lines were only added but the old ones were not deleted.

davcamer commented 6 years ago

That was a problem with the commit. Sorry about that.