mirror of
https://github.com/anchore/syft.git
synced 2026-10-31 22:46:36 +01:00
Add layer information for go-module-binary-cataloger (#620)
* update functions to pass Location Signed-off-by: Christopher Angelo Phillips <christopher.phillips@anchore.com> * update unit tests to pass new locations Signed-off-by: Christopher Angelo Phillips <christopher.phillips@anchore.com> * fix image source.FileResolvers to include layer info Signed-off-by: Alex Goodman <alex.goodman@anchore.com> * add non-empty location in golang binary cataloger testing Signed-off-by: Alex Goodman <alex.goodman@anchore.com> Co-authored-by: Alex Goodman <alex.goodman@anchore.com>
This commit is contained in:
co-authored by
Alex Goodman
parent
bb0f35bac4
commit
9bbc9ff633
@@ -53,14 +53,6 @@ func NewLocationFromDirectory(responsePath string, ref file.Reference) Location
|
||||
}
|
||||
}
|
||||
|
||||
func NewLocationFromReference(ref file.Reference) Location {
|
||||
return Location{
|
||||
VirtualPath: string(ref.RealPath),
|
||||
RealPath: string(ref.RealPath),
|
||||
ref: ref,
|
||||
}
|
||||
}
|
||||
|
||||
func (l Location) String() string {
|
||||
str := ""
|
||||
if l.ref.ID() != 0 {
|
||||
|
||||
Reference in New Issue
Block a user