From 8d25d44ea979860a08b690b70f893b5e09936702 Mon Sep 17 00:00:00 2001 From: Toure Dunnon Date: Mon, 12 Oct 2020 18:59:56 -0400 Subject: [PATCH] Add homepage field as output to the gemspec metadata (#215) https://github.com/anchore/syft/issues/214 Signed-off-by: Toure --- syft/cataloger/ruby/parse_gemspec_test.go | 1 + syft/pkg/gem_metadata.go | 1 + 2 files changed, 2 insertions(+) diff --git a/syft/cataloger/ruby/parse_gemspec_test.go b/syft/cataloger/ruby/parse_gemspec_test.go index 2c0cae20c..47bc9fc44 100644 --- a/syft/cataloger/ruby/parse_gemspec_test.go +++ b/syft/cataloger/ruby/parse_gemspec_test.go @@ -21,6 +21,7 @@ func TestParseGemspec(t *testing.T) { Files: []string{"exe/bundle", "exe/bundler"}, Authors: []string{"André Arko", "Samuel Giddins", "Colby Swandale", "Hiroshi Shibata", "David Rodríguez", "Grey Baker", "Stephanie Morillo", "Chris Morris", "James Wen", "Tim Moore", "André Medeiros", "Jessica Lynn Suttles", "Terence Lee", "Carl Lerche", "Yehuda Katz"}, Licenses: []string{"MIT"}, + Homepage: "https://bundler.io", }, } diff --git a/syft/pkg/gem_metadata.go b/syft/pkg/gem_metadata.go index 26f5ae0f4..e93bbc171 100644 --- a/syft/pkg/gem_metadata.go +++ b/syft/pkg/gem_metadata.go @@ -6,4 +6,5 @@ type GemMetadata struct { Files []string `mapstructure:"files" json:"files"` Authors []string `mapstructure:"authors" json:"authors"` Licenses []string `mapstructure:"licenses" json:"licenses"` + Homepage string `mapstructure:"homepage" json:"homepage"` }