From a0d516d93c082c4a1326645c25a0d4843255bcbd Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 24 Nov 2020 06:33:33 +0000 Subject: [PATCH 01/44] Bump github.com/Masterminds/semver/v3 from 3.1.0 to 3.1.1 Bumps [github.com/Masterminds/semver/v3](https://github.com/Masterminds/semver) from 3.1.0 to 3.1.1. - [Release notes](https://github.com/Masterminds/semver/releases) - [Changelog](https://github.com/Masterminds/semver/blob/master/CHANGELOG.md) - [Commits](https://github.com/Masterminds/semver/compare/v3.1.0...v3.1.1) Signed-off-by: dependabot[bot] --- go.mod | 2 +- go.sum | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/go.mod b/go.mod index fb4814c..6acebde 100644 --- a/go.mod +++ b/go.mod @@ -3,7 +3,7 @@ module github.com/paketo-buildpacks/libpak go 1.15 require ( - github.com/Masterminds/semver/v3 v3.1.0 + github.com/Masterminds/semver/v3 v3.1.1 github.com/buildpacks/libcnb v1.18.1 github.com/creack/pty v1.1.11 github.com/heroku/color v0.0.6 diff --git a/go.sum b/go.sum index 92b450f..fb06a75 100644 --- a/go.sum +++ b/go.sum @@ -1,7 +1,7 @@ github.com/BurntSushi/toml v0.3.1 h1:WXkYYl6Yr3qBf1K79EBnL4mak0OimBfB0XUf9Vl28OQ= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= -github.com/Masterminds/semver/v3 v3.1.0 h1:Y2lUDsFKVRSYGojLJ1yLxSXdMmMYTYls0rCvoqmMUQk= -github.com/Masterminds/semver/v3 v3.1.0/go.mod h1:VPu/7SZ7ePZ3QOrcuXROw5FAcLl4a0cBrbBpGY/8hQs= +github.com/Masterminds/semver/v3 v3.1.1 h1:hLg3sBzpNErnxhQtUy/mmLR2I9foDujNK030IGemrRc= +github.com/Masterminds/semver/v3 v3.1.1/go.mod h1:VPu/7SZ7ePZ3QOrcuXROw5FAcLl4a0cBrbBpGY/8hQs= github.com/buildpacks/libcnb v1.18.1 h1:NcAqtyLmSkpcgIOl83GOHY5Mk2ltBFiAI8mmAvavvEs= github.com/buildpacks/libcnb v1.18.1/go.mod h1:ozKZYold67tlck+1cobg11YhGmJqkQr8bMAH5gSvEvw= github.com/creack/pty v1.1.11 h1:07n33Z8lZxZ2qwegKbObQohDhXDQxiMMz1NOUGYlesw= From 845ebc22673f64a4d8ec78397eb85aa42c6fa1e2 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 9 Dec 2020 06:25:47 +0000 Subject: [PATCH 02/44] Bump github.com/onsi/gomega from 1.10.3 to 1.10.4 Bumps [github.com/onsi/gomega](https://github.com/onsi/gomega) from 1.10.3 to 1.10.4. - [Release notes](https://github.com/onsi/gomega/releases) - [Changelog](https://github.com/onsi/gomega/blob/master/CHANGELOG.md) - [Commits](https://github.com/onsi/gomega/compare/v1.10.3...v1.10.4) Signed-off-by: dependabot[bot] --- go.mod | 2 +- go.sum | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index 6acebde..8fcd2d1 100644 --- a/go.mod +++ b/go.mod @@ -9,7 +9,7 @@ require ( github.com/heroku/color v0.0.6 github.com/imdario/mergo v0.3.11 github.com/mattn/go-shellwords v1.0.10 - github.com/onsi/gomega v1.10.3 + github.com/onsi/gomega v1.10.4 github.com/pelletier/go-toml v1.8.1 github.com/sclevine/spec v1.4.0 github.com/spf13/pflag v1.0.5 diff --git a/go.sum b/go.sum index fb06a75..4d8f7e5 100644 --- a/go.sum +++ b/go.sum @@ -42,6 +42,8 @@ github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108 github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY= github.com/onsi/gomega v1.10.3 h1:gph6h/qe9GSUw1NhH1gp+qb+h8rXD8Cy60Z32Qw3ELA= github.com/onsi/gomega v1.10.3/go.mod h1:V9xEwhxec5O8UDM77eCW8vLymOMltsqPVYWrpDsH8xc= +github.com/onsi/gomega v1.10.4 h1:NiTx7EEvBzu9sFOD1zORteLSt3o8gnlvZZwSE9TnY9U= +github.com/onsi/gomega v1.10.4/go.mod h1:g/HbgYopi++010VEqkFgJHKC09uJiW9UkXvMUuKHUCQ= github.com/pelletier/go-toml v1.8.1 h1:1Nf83orprkJyknT6h7zbuEGUEjcyVlCxSUGTENmNCRM= github.com/pelletier/go-toml v1.8.1/go.mod h1:T2/BmBdy8dvIRq1a/8aqjN41wvWlN4lrapLU/GW4pbc= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= @@ -62,6 +64,8 @@ golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73r golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20201006153459-a7d1128ccaa0 h1:wBouT66WTYFXdxfVdz9sVWARVd/2vfGcmI45D2gj45M= golang.org/x/net v0.0.0-20201006153459-a7d1128ccaa0/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= +golang.org/x/net v0.0.0-20201202161906-c7110b5ffcbb h1:eBmm0M9fYhWpKZLjQUUKka/LtIxf46G4fxeEz5KJr9U= +golang.org/x/net v0.0.0-20201202161906-c7110b5ffcbb/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= From c3466570a5fcf0303ac52ad267862c7d74d24d0d Mon Sep 17 00:00:00 2001 From: nebhale Date: Fri, 18 Dec 2020 05:22:36 +0000 Subject: [PATCH 03/44] Bump pipeline from 1.8.1 to 1.9.0 Bumps pipeline from 1.8.1 to 1.9.0. Signed-off-by: GitHub --- .github/pipeline-version | 2 +- .github/workflows/update-pipeline.yml | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/pipeline-version b/.github/pipeline-version index a8fdfda..f8e233b 100644 --- a/.github/pipeline-version +++ b/.github/pipeline-version @@ -1 +1 @@ -1.8.1 +1.9.0 diff --git a/.github/workflows/update-pipeline.yml b/.github/workflows/update-pipeline.yml index 9e758c8..0f70aa4 100644 --- a/.github/workflows/update-pipeline.yml +++ b/.github/workflows/update-pipeline.yml @@ -64,6 +64,7 @@ jobs: GITHUB_TOKEN: ${{ secrets.JAVA_GITHUB_TOKEN }} - uses: peter-evans/create-pull-request@v3 with: + author: ${{ secrets.JAVA_GITHUB_USERNAME }} <${{ secrets.JAVA_GITHUB_USERNAME }}@users.noreply.github.com> body: |- Bumps pipeline from `${{ steps.pipeline.outputs.old-version }}` to `${{ steps.pipeline.outputs.new-version }}`. From 36ebdeacba20d13d82c49ef40b13822abc144fb3 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 14 Jan 2021 06:17:41 +0000 Subject: [PATCH 04/44] Bump github.com/stretchr/testify from 1.6.1 to 1.7.0 Bumps [github.com/stretchr/testify](https://github.com/stretchr/testify) from 1.6.1 to 1.7.0. - [Release notes](https://github.com/stretchr/testify/releases) - [Commits](https://github.com/stretchr/testify/compare/v1.6.1...v1.7.0) Signed-off-by: dependabot[bot] --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index 8fcd2d1..c23462c 100644 --- a/go.mod +++ b/go.mod @@ -13,6 +13,6 @@ require ( github.com/pelletier/go-toml v1.8.1 github.com/sclevine/spec v1.4.0 github.com/spf13/pflag v1.0.5 - github.com/stretchr/testify v1.6.1 + github.com/stretchr/testify v1.7.0 github.com/xi2/xz v0.0.0-20171230120015-48954b6210f8 ) diff --git a/go.sum b/go.sum index 4d8f7e5..8a594fc 100644 --- a/go.sum +++ b/go.sum @@ -56,6 +56,8 @@ github.com/stretchr/objx v0.1.0 h1:4G4v2dO3VZwixGIRoQ5Lfboy6nUhCyYzaqnIAPPhYs4= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/testify v1.6.1 h1:hDPOHmpOpP40lSULcqw7IrRb/u7w6RpDC9399XyoNd0= github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= +github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY= +github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/xi2/xz v0.0.0-20171230120015-48954b6210f8 h1:nIPpBwaJSVYIxUFsDv3M8ofmx9yWTog9BfvIu0q41lo= github.com/xi2/xz v0.0.0-20171230120015-48954b6210f8/go.mod h1:HUYIGzjTL3rfEspMxjDjgmT5uz5wzYJKVo23qUhYTos= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= From db191cff00d8d3dcf54ba2573e443316ae0f7e7d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 18 Jan 2021 07:28:38 +0000 Subject: [PATCH 05/44] Bump github.com/mattn/go-shellwords from 1.0.10 to 1.0.11 Bumps [github.com/mattn/go-shellwords](https://github.com/mattn/go-shellwords) from 1.0.10 to 1.0.11. - [Release notes](https://github.com/mattn/go-shellwords/releases) - [Commits](https://github.com/mattn/go-shellwords/compare/v1.0.10...v1.0.11) Signed-off-by: dependabot[bot] --- go.mod | 2 +- go.sum | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/go.mod b/go.mod index c23462c..dc561eb 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/creack/pty v1.1.11 github.com/heroku/color v0.0.6 github.com/imdario/mergo v0.3.11 - github.com/mattn/go-shellwords v1.0.10 + github.com/mattn/go-shellwords v1.0.11 github.com/onsi/gomega v1.10.4 github.com/pelletier/go-toml v1.8.1 github.com/sclevine/spec v1.4.0 diff --git a/go.sum b/go.sum index 8a594fc..bedaea2 100644 --- a/go.sum +++ b/go.sum @@ -32,8 +32,8 @@ github.com/mattn/go-colorable v0.1.2 h1:/bC9yWikZXAL9uJdulbSfyVNIR3n3trXl+v8+1sx github.com/mattn/go-colorable v0.1.2/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE= github.com/mattn/go-isatty v0.0.8 h1:HLtExJ+uU2HOZ+wI0Tt5DtUDrx8yhUqDcp7fYERX4CE= github.com/mattn/go-isatty v0.0.8/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= -github.com/mattn/go-shellwords v1.0.10 h1:Y7Xqm8piKOO3v10Thp7Z36h4FYFjt5xB//6XvOrs2Gw= -github.com/mattn/go-shellwords v1.0.10/go.mod h1:EZzvwXDESEeg03EKmM+RmDnNOPKG4lLtQsUlTZDWQ8Y= +github.com/mattn/go-shellwords v1.0.11 h1:vCoR9VPpsk/TZFW2JwK5I9S0xdrtUq2bph6/YjEPnaw= +github.com/mattn/go-shellwords v1.0.11/go.mod h1:EZzvwXDESEeg03EKmM+RmDnNOPKG4lLtQsUlTZDWQ8Y= github.com/nxadm/tail v1.4.4 h1:DQuhQpB1tVlglWS2hLQ5OV6B5r8aGxSrPc5Qo6uTN78= github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A= github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= From 5d42f40801a47d5715ee9a5844f416578e0f2748 Mon Sep 17 00:00:00 2001 From: Emily Casey Date: Tue, 19 Jan 2021 11:22:33 -0500 Subject: [PATCH 06/44] Don't shell parse config values * Resolves #38 Signed-off-by: Emily Casey --- buildpack.go | 7 +------ go.mod | 1 - go.sum | 2 -- 3 files changed, 1 insertion(+), 9 deletions(-) diff --git a/buildpack.go b/buildpack.go index 4391438..d35b247 100644 --- a/buildpack.go +++ b/buildpack.go @@ -25,7 +25,6 @@ import ( "github.com/Masterminds/semver/v3" "github.com/buildpacks/libcnb" "github.com/heroku/color" - "github.com/mattn/go-shellwords" "github.com/paketo-buildpacks/libpak/bard" ) @@ -277,15 +276,11 @@ func NewConfigurationResolver(buildpack libcnb.Buildpack, logger *bard.Logger) ( for _, c := range md.Configurations { s, _ := cr.Resolve(c.Name) - p, err := shellwords.Parse(s) - if err != nil { - return ConfigurationResolver{}, fmt.Errorf("unable to parse value\n%w", err) - } e := configurationEntry{ Name: c.Name, Description: c.Description, - Value: strings.Join(p, " "), + Value: s, } if l := len(e.Name); l > nameLength { diff --git a/go.mod b/go.mod index dc561eb..7950fec 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,6 @@ require ( github.com/creack/pty v1.1.11 github.com/heroku/color v0.0.6 github.com/imdario/mergo v0.3.11 - github.com/mattn/go-shellwords v1.0.11 github.com/onsi/gomega v1.10.4 github.com/pelletier/go-toml v1.8.1 github.com/sclevine/spec v1.4.0 diff --git a/go.sum b/go.sum index bedaea2..1ee1b02 100644 --- a/go.sum +++ b/go.sum @@ -32,8 +32,6 @@ github.com/mattn/go-colorable v0.1.2 h1:/bC9yWikZXAL9uJdulbSfyVNIR3n3trXl+v8+1sx github.com/mattn/go-colorable v0.1.2/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE= github.com/mattn/go-isatty v0.0.8 h1:HLtExJ+uU2HOZ+wI0Tt5DtUDrx8yhUqDcp7fYERX4CE= github.com/mattn/go-isatty v0.0.8/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= -github.com/mattn/go-shellwords v1.0.11 h1:vCoR9VPpsk/TZFW2JwK5I9S0xdrtUq2bph6/YjEPnaw= -github.com/mattn/go-shellwords v1.0.11/go.mod h1:EZzvwXDESEeg03EKmM+RmDnNOPKG4lLtQsUlTZDWQ8Y= github.com/nxadm/tail v1.4.4 h1:DQuhQpB1tVlglWS2hLQ5OV6B5r8aGxSrPc5Qo6uTN78= github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A= github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= From 9092c6194f4465bc573e511fcae0ec27c048acc9 Mon Sep 17 00:00:00 2001 From: Emily Casey Date: Mon, 1 Feb 2021 09:54:08 -0500 Subject: [PATCH 07/44] Buildpack API 0.5 * Doensn't contribute helper profile script now that exec.d is supported * Returns BOM entries for dependency and helper layers Signed-off-by: Emily Casey --- build_test.go | 5 +- buildpack.go | 6 +- buildpack_test.go | 4 +- detect_test.go | 5 +- go.mod | 2 +- go.sum | 2 + internal/toml_writer.go | 2 +- internal/toml_writer_test.go | 10 +- layer.go | 122 +++++++++++------------ layer_test.go | 185 ++++++++++++++++++++++++----------- main_test.go | 2 +- 11 files changed, 212 insertions(+), 133 deletions(-) diff --git a/build_test.go b/build_test.go index 5056c77..8e4dfe4 100644 --- a/build_test.go +++ b/build_test.go @@ -105,7 +105,10 @@ func testBuild(t *testing.T, context spec.G, it spec.S) { }) it("handles error from Builder", func() { - Expect(ioutil.WriteFile(filepath.Join(buildpackPath, "buildpack.toml"), []byte(`[buildpack] + Expect(ioutil.WriteFile(filepath.Join(buildpackPath, "buildpack.toml"), []byte(` +api = "0.5" + +[buildpack] name = "test-name" version = "test-version"`), 0644)).To(Succeed()) diff --git a/buildpack.go b/buildpack.go index d35b247..c0c0055 100644 --- a/buildpack.go +++ b/buildpack.go @@ -83,9 +83,9 @@ type BuildpackDependency struct { Licenses []BuildpackDependencyLicense `toml:"licenses"` } -// AsBuildpackPlanEntry renders the dependency as a BuildpackPlanEntry. -func (b BuildpackDependency) AsBuildpackPlanEntry() libcnb.BuildpackPlanEntry { - return libcnb.BuildpackPlanEntry{ +// AsBOMEntry renders a bill of materials entry describing the dependency. +func (b BuildpackDependency) AsBOMEntry() libcnb.BOMEntry { + return libcnb.BOMEntry{ Name: b.ID, Metadata: map[string]interface{}{ "name": b.Name, diff --git a/buildpack_test.go b/buildpack_test.go index 4b68105..5bc9844 100644 --- a/buildpack_test.go +++ b/buildpack_test.go @@ -33,7 +33,7 @@ func testBuildpack(t *testing.T, context spec.G, it spec.S) { Expect = NewWithT(t).Expect ) - it("renders dependency as an BuildpackPlanEntry", func() { + it("renders dependency as a BOMEntry", func() { dependency := libpak.BuildpackDependency{ ID: "test-id", Name: "test-name", @@ -49,7 +49,7 @@ func testBuildpack(t *testing.T, context spec.G, it spec.S) { }, } - Expect(dependency.AsBuildpackPlanEntry()).To(Equal(libcnb.BuildpackPlanEntry{ + Expect(dependency.AsBOMEntry()).To(Equal(libcnb.BOMEntry{ Name: dependency.ID, Metadata: map[string]interface{}{ "name": dependency.Name, diff --git a/detect_test.go b/detect_test.go index a14ab0e..02e64af 100644 --- a/detect_test.go +++ b/detect_test.go @@ -99,7 +99,10 @@ func testDetect(t *testing.T, context spec.G, it spec.S) { }) it("handles error from Detector", func() { - Expect(ioutil.WriteFile(filepath.Join(buildpackPath, "buildpack.toml"), []byte(`[buildpack] + Expect(ioutil.WriteFile(filepath.Join(buildpackPath, "buildpack.toml"), []byte(` +api = "0.5" + +[buildpack] name = "test-name" version = "test-version"`), 0644)).To(Succeed()) diff --git a/go.mod b/go.mod index 7950fec..214e95e 100644 --- a/go.mod +++ b/go.mod @@ -4,7 +4,7 @@ go 1.15 require ( github.com/Masterminds/semver/v3 v3.1.1 - github.com/buildpacks/libcnb v1.18.1 + github.com/buildpacks/libcnb v1.19.0 github.com/creack/pty v1.1.11 github.com/heroku/color v0.0.6 github.com/imdario/mergo v0.3.11 diff --git a/go.sum b/go.sum index 1ee1b02..f98727f 100644 --- a/go.sum +++ b/go.sum @@ -4,6 +4,8 @@ github.com/Masterminds/semver/v3 v3.1.1 h1:hLg3sBzpNErnxhQtUy/mmLR2I9foDujNK030I github.com/Masterminds/semver/v3 v3.1.1/go.mod h1:VPu/7SZ7ePZ3QOrcuXROw5FAcLl4a0cBrbBpGY/8hQs= github.com/buildpacks/libcnb v1.18.1 h1:NcAqtyLmSkpcgIOl83GOHY5Mk2ltBFiAI8mmAvavvEs= github.com/buildpacks/libcnb v1.18.1/go.mod h1:ozKZYold67tlck+1cobg11YhGmJqkQr8bMAH5gSvEvw= +github.com/buildpacks/libcnb v1.19.0 h1:7Frn3qErlVmQydk95YXmHtpmf5bZ1l7h4rK/C+SKAmY= +github.com/buildpacks/libcnb v1.19.0/go.mod h1:slnOsywO4mNdkShkwX1GYR+kQF1tH2F9Urfr66lWGQs= github.com/creack/pty v1.1.11 h1:07n33Z8lZxZ2qwegKbObQohDhXDQxiMMz1NOUGYlesw= github.com/creack/pty v1.1.11/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= diff --git a/internal/toml_writer.go b/internal/toml_writer.go index 78cca79..a76b6a5 100644 --- a/internal/toml_writer.go +++ b/internal/toml_writer.go @@ -67,7 +67,7 @@ func (t TOMLWriter) Write(path string, value interface{}) error { } switch v := value.(type) { - case libcnb.Launch: + case libcnb.LaunchTOML: if len(v.Slices) > 0 { t.logger.Headerf("%d application slices", len(v.Slices)) } diff --git a/internal/toml_writer_test.go b/internal/toml_writer_test.go index 10d5605..9785008 100644 --- a/internal/toml_writer_test.go +++ b/internal/toml_writer_test.go @@ -87,7 +87,7 @@ other-field = "other-value"`)) }) it("logs []libcnb.Slice", func() { - err := tomlWriter.Write(path, libcnb.Launch{ + err := tomlWriter.Write(path, libcnb.LaunchTOML{ Slices: []libcnb.Slice{ {}, {}, @@ -100,7 +100,7 @@ other-field = "other-value"`)) }) it("logs []libcnb.Label", func() { - err := tomlWriter.Write(path, libcnb.Launch{ + err := tomlWriter.Write(path, libcnb.LaunchTOML{ Labels: []libcnb.Label{ {Key: "test-key-1"}, {Key: "test-key-2"}, @@ -117,7 +117,7 @@ other-field = "other-value"`)) context("[]libcnb.Process", func() { it("aligns process types", func() { - err := tomlWriter.Write(path, libcnb.Launch{ + err := tomlWriter.Write(path, libcnb.LaunchTOML{ Processes: []libcnb.Process{ {Type: "short", Command: "test-command-1"}, {Type: "a-very-long-type", Command: "test-command-2"}, @@ -133,7 +133,7 @@ other-field = "other-value"`)) }) it("appends arguments", func() { - err := tomlWriter.Write(path, libcnb.Launch{ + err := tomlWriter.Write(path, libcnb.LaunchTOML{ Processes: []libcnb.Process{ {Type: "test-type", Command: "test-command", Arguments: []string{"test-arg-1", "test-arg-2"}}, }, @@ -147,7 +147,7 @@ other-field = "other-value"`)) }) it("indicates direct", func() { - err := tomlWriter.Write(path, libcnb.Launch{ + err := tomlWriter.Write(path, libcnb.LaunchTOML{ Processes: []libcnb.Process{ {Type: "test-type", Command: "test-command", Direct: true}, }, diff --git a/layer.go b/layer.go index 6f0918d..48670fb 100644 --- a/layer.go +++ b/layer.go @@ -21,7 +21,6 @@ import ( "os" "path/filepath" "reflect" - "strings" "github.com/heroku/color" "github.com/pelletier/go-toml" @@ -45,29 +44,26 @@ type LayerContributor struct { // Name is the user readable name of the contribution. Name string + + // ExpectedTypes indicates the types that should be set on the layer. + ExpectedTypes libcnb.LayerTypes } // NewLayerContributor creates a new instance. -func NewLayerContributor(name string, expectedMetadata interface{}) LayerContributor { +func NewLayerContributor(name string, expectedMetadata interface{}, expectedTypes libcnb.LayerTypes) LayerContributor { return LayerContributor{ ExpectedMetadata: expectedMetadata, Name: name, + ExpectedTypes: expectedTypes, } } // LayerFunc is a callback function that is invoked when a layer needs to be contributed. type LayerFunc func() (libcnb.Layer, error) -type LayerFlag uint8 - -const ( - BuildLayer LayerFlag = iota - CacheLayer - LaunchLayer -) // Contribute is the function to call when implementing your libcnb.LayerContributor. -func (l *LayerContributor) Contribute(layer libcnb.Layer, f LayerFunc, flags ...LayerFlag) (libcnb.Layer, error) { +func (l *LayerContributor) Contribute(layer libcnb.Layer, f LayerFunc) (libcnb.Layer, error) { raw, err := toml.Marshal(l.ExpectedMetadata) if err != nil { return libcnb.Layer{}, fmt.Errorf("unable to encode metadata\n%w", err) @@ -81,6 +77,7 @@ func (l *LayerContributor) Contribute(layer libcnb.Layer, f LayerFunc, flags ... l.Logger.Debugf("Expected metadata: %+v", expected) l.Logger.Debugf("Actual metadata: %+v", layer.Metadata) + // TODO: compare entire layer not just metadata (in case build, launch, or cache have changed) if reflect.DeepEqual(expected, layer.Metadata) { l.Logger.Headerf("%s: %s cached layer", color.BlueString(l.Name), color.GreenString("Reusing")) return layer, nil @@ -101,17 +98,7 @@ func (l *LayerContributor) Contribute(layer libcnb.Layer, f LayerFunc, flags ... return libcnb.Layer{}, err } - for _, f := range flags { - switch f { - case BuildLayer: - layer.Build = true - case CacheLayer: - layer.Cache = true - case LaunchLayer: - layer.Launch = true - } - } - + layer.LayerTypes = l.ExpectedTypes layer.Metadata = expected return layer, nil @@ -127,8 +114,11 @@ type DependencyLayerContributor struct { // DependencyCache is the cache to use to get the dependency. DependencyCache DependencyCache - // LayerContributor is the contained LayerContributor used for the actual contribution. - LayerContributor LayerContributor + // ExpectedTypes indicates the types that should be set on the layer. + ExpectedTypes libcnb.LayerTypes + + // ExpectedMetadata contains metadata describing the expected layer + ExpectedMetadata interface{} // Logger is the logger to use. Logger bard.Logger @@ -137,29 +127,38 @@ type DependencyLayerContributor struct { RequestModifierFuncs []RequestModifierFunc } -// NewDependencyLayerContributor creates a new instance and adds the dependency to the Buildpack Plan. -func NewDependencyLayerContributor(dependency BuildpackDependency, cache DependencyCache, plan *libcnb.BuildpackPlan) DependencyLayerContributor { +// NewDependencyLayer returns a new DependencyLayerContributor for the given BuildpackDependency and a BOMEntry describing the layer contents. +func NewDependencyLayer(dependency BuildpackDependency, cache DependencyCache, types libcnb.LayerTypes) (DependencyLayerContributor, libcnb.BOMEntry) { c := DependencyLayerContributor{ Dependency: dependency, + ExpectedMetadata: dependency, DependencyCache: cache, - LayerContributor: NewLayerContributor(fmt.Sprintf("%s %s", dependency.Name, dependency.Version), dependency), + ExpectedTypes: types, } - entry := dependency.AsBuildpackPlanEntry() + entry := dependency.AsBOMEntry() entry.Metadata["layer"] = c.LayerName() - plan.Entries = append(plan.Entries, entry) - return c + if types.Launch { + entry.Launch = true + } + if !(types.Launch && !types.Cache && !types.Build) { + // launch-only layers are the only layers NOT guaranteed to be present in the build environment + entry.Build = true + } + + return c, entry } // DependencyLayerFunc is a callback function that is invoked when a dependency needs to be contributed. type DependencyLayerFunc func(artifact *os.File) (libcnb.Layer, error) // Contribute is the function to call whe implementing your libcnb.LayerContributor. -func (d *DependencyLayerContributor) Contribute(layer libcnb.Layer, f DependencyLayerFunc, flags ...LayerFlag) (libcnb.Layer, error) { - d.LayerContributor.Logger = d.Logger +func (d *DependencyLayerContributor) Contribute(layer libcnb.Layer, f DependencyLayerFunc) (libcnb.Layer, error) { + lc := NewLayerContributor(d.Name(), d.ExpectedMetadata, d.ExpectedTypes) + lc.Logger = d.Logger - return d.LayerContributor.Contribute(layer, func() (libcnb.Layer, error) { + return lc.Contribute(layer, func() (libcnb.Layer, error) { artifact, err := d.DependencyCache.Artifact(d.Dependency, d.RequestModifierFuncs...) if err != nil { return libcnb.Layer{}, fmt.Errorf("unable to get dependency %s\n%w", d.Dependency.ID, err) @@ -167,7 +166,7 @@ func (d *DependencyLayerContributor) Contribute(layer libcnb.Layer, f Dependency defer artifact.Close() return f(artifact) - }, flags...) + }) } // LayerName returns the conventional name of the layer for this contributor @@ -175,6 +174,11 @@ func (d *DependencyLayerContributor) LayerName() string { return d.Dependency.ID } +// Name returns the human readable name of the layer +func (d *DependencyLayerContributor) Name() string { + return fmt.Sprintf("%s %s", d.Dependency.Name, d.Dependency.Version) +} + // HelperLayerContributor is a helper for implementing a libcnb.LayerContributor for a buildpack helper application in // order to get consistent logging and avoidance. type HelperLayerContributor struct { @@ -182,8 +186,8 @@ type HelperLayerContributor struct { // Path is the path to the helper application. Path string - // LayerContributor is the contained LayerContributor used for the actual contribution. - LayerContributor LayerContributor + // BuildpackInfo describes the buildpack that provides the helper + BuildpackInfo libcnb.BuildpackInfo // Logger is the logger to use. Logger bard.Logger @@ -192,31 +196,40 @@ type HelperLayerContributor struct { Names []string } -// NewHelperLayerContributor creates a new instance and adds the helper to the Buildpack Plan. -func NewHelperLayerContributor(buildpack libcnb.Buildpack, plan *libcnb.BuildpackPlan, names ...string) HelperLayerContributor { +// NewHelperLayer returns a new HelperLayerContributor and a BOMEntry describing the layer contents. +func NewHelperLayer(buildpack libcnb.Buildpack, names ...string) (HelperLayerContributor, libcnb.BOMEntry) { c := HelperLayerContributor{ - Path: filepath.Join(buildpack.Path, "bin", "helper"), - LayerContributor: NewLayerContributor("Launch Helper", buildpack.Info), - Names: names, + Path: filepath.Join(buildpack.Path, "bin", "helper"), + Names: names, + BuildpackInfo: buildpack.Info, } - plan.Entries = append(plan.Entries, libcnb.BuildpackPlanEntry{ + entry := libcnb.BOMEntry{ Name: "helper", Metadata: map[string]interface{}{ "layer": c.Name(), "names": names, "version": buildpack.Info.Version, }, - }) + Launch: true, + } + + return c, entry +} - return c +// Name returns the conventional name of the layer for this contributor +func (h HelperLayerContributor) Name() string { + return filepath.Base(h.Path) } // Contribute is the function to call whe implementing your libcnb.LayerContributor. func (h HelperLayerContributor) Contribute(layer libcnb.Layer) (libcnb.Layer, error) { - h.LayerContributor.Logger = h.Logger + lc := NewLayerContributor("Launch Helper", h.BuildpackInfo, libcnb.LayerTypes{ + Launch: true, + }) + lc.Logger = h.Logger - return h.LayerContributor.Contribute(layer, func() (libcnb.Layer, error) { + return lc.Contribute(layer, func() (libcnb.Layer, error) { in, err := os.Open(h.Path) if err != nil { return libcnb.Layer{}, fmt.Errorf("unable to open %s\n%w", h.Path, err) @@ -228,7 +241,6 @@ func (h HelperLayerContributor) Contribute(layer libcnb.Layer) (libcnb.Layer, er return libcnb.Layer{}, fmt.Errorf("unable to copy %s to %s", h.Path, out) } - var p []string for _, n := range h.Names { link := layer.Exec.FilePath(n) h.Logger.Bodyf("Creating %s", link) @@ -241,24 +253,8 @@ func (h HelperLayerContributor) Contribute(layer libcnb.Layer) (libcnb.Layer, er if err := os.Symlink(out, link); err != nil { return libcnb.Layer{}, fmt.Errorf("unable to link %s to %s\n%w", out, link, err) } - - p = append(p, - "exec 4<&1", - fmt.Sprintf(`for_export=$(%s 3>&1 >&4) || exit $?`, link), - "exec 4<&-", - "set -a", - `eval "$for_export"`, - "set +a", - ) } - layer.Profile.Add("helper", strings.Join(p, "\n")) - return layer, nil - }, LaunchLayer) -} - -// Name returns the conventional name of the layer for this contributor -func (h HelperLayerContributor) Name() string { - return filepath.Base(h.Path) + }) } diff --git a/layer_test.go b/layer_test.go index f1c92eb..c62b4e5 100644 --- a/layer_test.go +++ b/layer_test.go @@ -30,6 +30,7 @@ import ( "github.com/sclevine/spec" "github.com/paketo-buildpacks/libpak" + "github.com/paketo-buildpacks/libpak/bard" ) func testLayer(t *testing.T, context spec.G, it spec.S) { @@ -138,30 +139,127 @@ func testLayer(t *testing.T, context spec.G, it spec.S) { }) it("sets build layer flag", func() { + lc.ExpectedTypes.Build = true layer, err := lc.Contribute(layer, func() (libcnb.Layer, error) { return layer, nil - }, libpak.BuildLayer) + }) Expect(err).NotTo(HaveOccurred()) - Expect(layer.Build).To(BeTrue()) + Expect(layer.LayerTypes.Build).To(BeTrue()) }) it("sets cache layer flag", func() { + lc.ExpectedTypes.Cache = true layer, err := lc.Contribute(layer, func() (libcnb.Layer, error) { return layer, nil - }, libpak.CacheLayer) + }) Expect(err).NotTo(HaveOccurred()) - Expect(layer.Cache).To(BeTrue()) + Expect(layer.LayerTypes.Cache).To(BeTrue()) }) it("sets launch layer flag", func() { + lc.ExpectedTypes.Launch = true layer, err := lc.Contribute(layer, func() (libcnb.Layer, error) { return layer, nil - }, libpak.LaunchLayer) + }) Expect(err).NotTo(HaveOccurred()) - Expect(layer.Launch).To(BeTrue()) + Expect(layer.LayerTypes.Launch).To(BeTrue()) + }) + }) + + context("NewDependencyLayer", func() { + var dep libpak.BuildpackDependency + + it.Before(func() { + dep = libpak.BuildpackDependency{ + ID: "test-id", + Name: "test-name", + Version: "1.1.1", + URI: "test-uri", + SHA256: "576dd8416de5619ea001d9662291d62444d1292a38e96956bc4651c01f14bca1", + Stacks: []string{"test-stack"}, + Licenses: []libpak.BuildpackDependencyLicense{ + { + Type: "test-type", + URI: "test-uri", + }, + }, + } + }) + it("returns a BOM entry for the layer", func() { + _, entry := libpak.NewDependencyLayer(dep, libpak.DependencyCache{}, libcnb.LayerTypes{}) + Expect(entry.Name).To(Equal("test-id")) + Expect(entry.Metadata["name"]).To(Equal("test-name")) + Expect(entry.Metadata["version"]).To(Equal("1.1.1")) + Expect(entry.Metadata["uri"]).To(Equal("test-uri")) + Expect(entry.Metadata["sha256"]).To(Equal("576dd8416de5619ea001d9662291d62444d1292a38e96956bc4651c01f14bca1")) + Expect(entry.Metadata["licenses"]).To(Equal([]libpak.BuildpackDependencyLicense{ + { + Type: "test-type", + URI: "test-uri", + }, + })) + }) + context("launch layer type", func() { + it("only sets launch on the entry", func() { + _, entry := libpak.NewDependencyLayer(dep, libpak.DependencyCache{}, libcnb.LayerTypes{ + Launch: true, + }) + Expect(entry.Launch).To(BeTrue()) + Expect(entry.Build).To(BeFalse()) + }) + }) + + context("launch and build layer type", func() { + it("sets launch and build on the entry", func() { + _, entry := libpak.NewDependencyLayer(dep, libpak.DependencyCache{}, libcnb.LayerTypes{ + Launch: true, + Build: true, + }) + Expect(entry.Launch).To(BeTrue()) + Expect(entry.Build).To(BeTrue()) + }) + }) + + context("launch and cache layer type", func() { + it("sets launch and build on the entry", func() { + _, entry := libpak.NewDependencyLayer(dep, libpak.DependencyCache{}, libcnb.LayerTypes{ + Launch: true, + Cache: true, + }) + Expect(entry.Launch).To(BeTrue()) + Expect(entry.Build).To(BeTrue()) + }) + }) + + context("build layer type", func() { + it("sets build on the entry", func() { + _, entry := libpak.NewDependencyLayer(dep, libpak.DependencyCache{}, libcnb.LayerTypes{ + Build: true, + }) + Expect(entry.Launch).To(BeFalse()) + Expect(entry.Build).To(BeTrue()) + }) + }) + + context("cache layer type", func() { + it("sets build on the entry", func() { + _, entry := libpak.NewDependencyLayer(dep, libpak.DependencyCache{}, libcnb.LayerTypes{ + Cache: true, + }) + Expect(entry.Launch).To(BeFalse()) + Expect(entry.Build).To(BeTrue()) + }) + }) + + context("no layer types", func() { + it("sets build on the entry", func() { + _, entry := libpak.NewDependencyLayer(dep, libpak.DependencyCache{}, libcnb.LayerTypes{}) + Expect(entry.Launch).To(BeFalse()) + Expect(entry.Build).To(BeTrue()) + }) }) }) @@ -193,8 +291,7 @@ func testLayer(t *testing.T, context spec.G, it spec.S) { layer.Metadata = map[string]interface{}{} - dlc.LayerContributor.ExpectedMetadata = dependency - + dlc.ExpectedMetadata = dependency dlc.Dependency = dependency dlc.DependencyCache.CachePath = layer.Path dlc.DependencyCache.DownloadPath = layer.Path @@ -320,24 +417,27 @@ func testLayer(t *testing.T, context spec.G, it spec.S) { }, })) }) + }) - it("contributes to buildpack plan", func() { - plan := libcnb.BuildpackPlan{} - - _ = libpak.NewDependencyLayerContributor(dependency, libpak.DependencyCache{}, &plan) - - Expect(plan.Entries).To(ContainElement(libcnb.BuildpackPlanEntry{ - Name: dependency.ID, - Metadata: map[string]interface{}{ - "name": dependency.Name, - "version": dependency.Version, - "layer": dependency.ID, - "uri": dependency.URI, - "sha256": dependency.SHA256, - "stacks": dependency.Stacks, - "licenses": dependency.Licenses, + context("NewHelperLayer", func() { + it("returns a BOM entry with version equal to buildpack version", func() { + _, entry := libpak.NewHelperLayer(libcnb.Buildpack{ + Info: libcnb.BuildpackInfo{ + Version: "test-version", }, - })) + }, "test-name-1", "test-name-2") + Expect(entry).To(Equal( + libcnb.BOMEntry{ + Name: filepath.Base("helper"), + Metadata: map[string]interface{}{ + "layer": "helper", + "names": []string{"test-name-1", "test-name-2"}, + "version": "test-version", + }, + Launch: true, + Build: false, + }, + )) }) }) @@ -366,9 +466,12 @@ func testLayer(t *testing.T, context spec.G, it spec.S) { file = filepath.Join(file, "helper") Expect(ioutil.WriteFile(file, []byte{}, 0755)).To(Succeed()) - hlc.Path = file - hlc.LayerContributor.ExpectedMetadata = buildpack.Info - hlc.Names = []string{"test-name-1", "test-name-2"} + hlc = libpak.HelperLayerContributor{ + Path: file, + BuildpackInfo: buildpack.Info, + Logger: bard.Logger{}, + Names: []string{"test-name-1", "test-name-2"}, + } }) it.After(func() { @@ -395,19 +498,6 @@ func testLayer(t *testing.T, context spec.G, it spec.S) { file = filepath.Join(layer.Exec.FilePath("test-name-2")) Expect(file).To(BeAnExistingFile()) Expect(os.Readlink(file)).To(Equal(filepath.Join(layer.Path, "helper"))) - - Expect(layer.Profile["helper"]).To(Equal(fmt.Sprintf(`exec 4<&1 -for_export=$(%s 3>&1 >&4) || exit $? -exec 4<&- -set -a -eval "$for_export" -set +a -exec 4<&1 -for_export=$(%s 3>&1 >&4) || exit $? -exec 4<&- -set -a -eval "$for_export" -set +a`, layer.Exec.FilePath("test-name-1"), layer.Exec.FilePath("test-name-2")))) }) it("does not call function with matching metadata", func() { @@ -438,20 +528,5 @@ set +a`, layer.Exec.FilePath("test-name-1"), layer.Exec.FilePath("test-name-2")) "clear-env": buildpack.Info.ClearEnvironment, })) }) - - it("contributes to buildpack plan", func() { - plan := libcnb.BuildpackPlan{} - - _ = libpak.NewHelperLayerContributor(buildpack, &plan, "test-name-1", "test-name-2") - - Expect(plan.Entries).To(ContainElement(libcnb.BuildpackPlanEntry{ - Name: filepath.Base("helper"), - Metadata: map[string]interface{}{ - "layer": "helper", - "names": []string{"test-name-1", "test-name-2"}, - "version": buildpack.Info.Version, - }, - })) - }) }) } diff --git a/main_test.go b/main_test.go index 9e5ba78..a4ffd63 100644 --- a/main_test.go +++ b/main_test.go @@ -66,7 +66,7 @@ func testMain(t *testing.T, context spec.G, it spec.S) { Expect(ioutil.WriteFile(filepath.Join(buildpackPath, "buildpack.toml"), []byte(` -api = "0.0.0" +api = "0.5" [buildpack] id = "test-id" From afd93b2ead4fc2c907f4005b30757413a64975f8 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 2 Feb 2021 07:16:12 +0000 Subject: [PATCH 08/44] Bump github.com/onsi/gomega from 1.10.4 to 1.10.5 Bumps [github.com/onsi/gomega](https://github.com/onsi/gomega) from 1.10.4 to 1.10.5. - [Release notes](https://github.com/onsi/gomega/releases) - [Changelog](https://github.com/onsi/gomega/blob/master/CHANGELOG.md) - [Commits](https://github.com/onsi/gomega/compare/v1.10.4...v1.10.5) Signed-off-by: dependabot[bot] --- go.mod | 2 +- go.sum | 10 ++-------- 2 files changed, 3 insertions(+), 9 deletions(-) diff --git a/go.mod b/go.mod index 214e95e..02a9044 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/creack/pty v1.1.11 github.com/heroku/color v0.0.6 github.com/imdario/mergo v0.3.11 - github.com/onsi/gomega v1.10.4 + github.com/onsi/gomega v1.10.5 github.com/pelletier/go-toml v1.8.1 github.com/sclevine/spec v1.4.0 github.com/spf13/pflag v1.0.5 diff --git a/go.sum b/go.sum index f98727f..07225be 100644 --- a/go.sum +++ b/go.sum @@ -2,8 +2,6 @@ github.com/BurntSushi/toml v0.3.1 h1:WXkYYl6Yr3qBf1K79EBnL4mak0OimBfB0XUf9Vl28OQ github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/Masterminds/semver/v3 v3.1.1 h1:hLg3sBzpNErnxhQtUy/mmLR2I9foDujNK030IGemrRc= github.com/Masterminds/semver/v3 v3.1.1/go.mod h1:VPu/7SZ7ePZ3QOrcuXROw5FAcLl4a0cBrbBpGY/8hQs= -github.com/buildpacks/libcnb v1.18.1 h1:NcAqtyLmSkpcgIOl83GOHY5Mk2ltBFiAI8mmAvavvEs= -github.com/buildpacks/libcnb v1.18.1/go.mod h1:ozKZYold67tlck+1cobg11YhGmJqkQr8bMAH5gSvEvw= github.com/buildpacks/libcnb v1.19.0 h1:7Frn3qErlVmQydk95YXmHtpmf5bZ1l7h4rK/C+SKAmY= github.com/buildpacks/libcnb v1.19.0/go.mod h1:slnOsywO4mNdkShkwX1GYR+kQF1tH2F9Urfr66lWGQs= github.com/creack/pty v1.1.11 h1:07n33Z8lZxZ2qwegKbObQohDhXDQxiMMz1NOUGYlesw= @@ -40,10 +38,10 @@ github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+W github.com/onsi/ginkgo v1.12.1 h1:mFwc4LvZ0xpSvDZ3E+k8Yte0hLOMxXUlP+yXtJqkYfQ= github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk= github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY= -github.com/onsi/gomega v1.10.3 h1:gph6h/qe9GSUw1NhH1gp+qb+h8rXD8Cy60Z32Qw3ELA= -github.com/onsi/gomega v1.10.3/go.mod h1:V9xEwhxec5O8UDM77eCW8vLymOMltsqPVYWrpDsH8xc= github.com/onsi/gomega v1.10.4 h1:NiTx7EEvBzu9sFOD1zORteLSt3o8gnlvZZwSE9TnY9U= github.com/onsi/gomega v1.10.4/go.mod h1:g/HbgYopi++010VEqkFgJHKC09uJiW9UkXvMUuKHUCQ= +github.com/onsi/gomega v1.10.5 h1:7n6FEkpFmfCoo2t+YYqXH0evK+a9ICQz0xcAy9dYcaQ= +github.com/onsi/gomega v1.10.5/go.mod h1:gza4q3jKQJijlu05nKWRCW/GavJumGt8aNRxWg7mt48= github.com/pelletier/go-toml v1.8.1 h1:1Nf83orprkJyknT6h7zbuEGUEjcyVlCxSUGTENmNCRM= github.com/pelletier/go-toml v1.8.1/go.mod h1:T2/BmBdy8dvIRq1a/8aqjN41wvWlN4lrapLU/GW4pbc= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= @@ -54,8 +52,6 @@ github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= github.com/stretchr/objx v0.1.0 h1:4G4v2dO3VZwixGIRoQ5Lfboy6nUhCyYzaqnIAPPhYs4= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= -github.com/stretchr/testify v1.6.1 h1:hDPOHmpOpP40lSULcqw7IrRb/u7w6RpDC9399XyoNd0= -github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/xi2/xz v0.0.0-20171230120015-48954b6210f8 h1:nIPpBwaJSVYIxUFsDv3M8ofmx9yWTog9BfvIu0q41lo= @@ -64,8 +60,6 @@ golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACk golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= -golang.org/x/net v0.0.0-20201006153459-a7d1128ccaa0 h1:wBouT66WTYFXdxfVdz9sVWARVd/2vfGcmI45D2gj45M= -golang.org/x/net v0.0.0-20201006153459-a7d1128ccaa0/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/net v0.0.0-20201202161906-c7110b5ffcbb h1:eBmm0M9fYhWpKZLjQUUKka/LtIxf46G4fxeEz5KJr9U= golang.org/x/net v0.0.0-20201202161906-c7110b5ffcbb/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= From f3d6e37e879343329e1eb4565cc441e5ab10bb4a Mon Sep 17 00:00:00 2001 From: paketo-bot Date: Tue, 9 Feb 2021 05:18:42 +0000 Subject: [PATCH 09/44] Bump pipeline from 1.9.0 to 1.9.1 Bumps pipeline from 1.9.0 to 1.9.1. Signed-off-by: GitHub --- .github/dependabot.yml | 7 ------- .github/pipeline-version | 2 +- 2 files changed, 1 insertion(+), 8 deletions(-) diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 1d28333..5302b7b 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -1,12 +1,5 @@ version: 2 updates: - - package-ecosystem: github-actions - directory: / - schedule: - interval: daily - labels: - - semver:patch - - type:dependency-upgrade - package-ecosystem: gomod directory: / schedule: diff --git a/.github/pipeline-version b/.github/pipeline-version index f8e233b..9ab8337 100644 --- a/.github/pipeline-version +++ b/.github/pipeline-version @@ -1 +1 @@ -1.9.0 +1.9.1 From 32102f9248d1efe2988ba283ecda823160a2b0cd Mon Sep 17 00:00:00 2001 From: paketo-bot Date: Wed, 10 Feb 2021 05:18:44 +0000 Subject: [PATCH 10/44] Bump pipeline from 1.9.1 to 1.9.2 Bumps pipeline from 1.9.1 to 1.9.2. Signed-off-by: GitHub --- .github/pipeline-version | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/pipeline-version b/.github/pipeline-version index 9ab8337..8fdcf38 100644 --- a/.github/pipeline-version +++ b/.github/pipeline-version @@ -1 +1 @@ -1.9.1 +1.9.2 From 57aad381d732493dcce968f21a3e07982702cbc5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 8 Mar 2021 06:56:58 +0000 Subject: [PATCH 11/44] Bump github.com/onsi/gomega from 1.10.5 to 1.11.0 Bumps [github.com/onsi/gomega](https://github.com/onsi/gomega) from 1.10.5 to 1.11.0. - [Release notes](https://github.com/onsi/gomega/releases) - [Changelog](https://github.com/onsi/gomega/blob/master/CHANGELOG.md) - [Commits](https://github.com/onsi/gomega/compare/v1.10.5...v1.11.0) Signed-off-by: dependabot[bot] --- go.mod | 2 +- go.sum | 8 ++++++-- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/go.mod b/go.mod index 02a9044..1249111 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/creack/pty v1.1.11 github.com/heroku/color v0.0.6 github.com/imdario/mergo v0.3.11 - github.com/onsi/gomega v1.10.5 + github.com/onsi/gomega v1.11.0 github.com/pelletier/go-toml v1.8.1 github.com/sclevine/spec v1.4.0 github.com/spf13/pflag v1.0.5 diff --git a/go.sum b/go.sum index 07225be..213145a 100644 --- a/go.sum +++ b/go.sum @@ -19,6 +19,8 @@ github.com/golang/protobuf v1.4.0-rc.4.0.20200313231945-b860323f09d0/go.mod h1:W github.com/golang/protobuf v1.4.0/go.mod h1:jodUvKwWbYaEsadDk5Fwe5c77LiNKVO9IDvqG2KuDX0= github.com/golang/protobuf v1.4.2 h1:+Z5KGCizgyZCbGh1KZqA0fcLLkwbsjIzS4aV2v7wJX0= github.com/golang/protobuf v1.4.2/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= +github.com/golang/protobuf v1.4.3 h1:JjCZWpVbqXDqFVmTfYWEVTMIYrL/NPdPSCHPJ0T/raM= +github.com/golang/protobuf v1.4.3/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= github.com/google/go-cmp v0.3.1/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= github.com/google/go-cmp v0.4.0 h1:xsAVV57WRhGj6kEIi8ReJzQlHHqcBYCElAvkovg3B/4= @@ -40,8 +42,8 @@ github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108 github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY= github.com/onsi/gomega v1.10.4 h1:NiTx7EEvBzu9sFOD1zORteLSt3o8gnlvZZwSE9TnY9U= github.com/onsi/gomega v1.10.4/go.mod h1:g/HbgYopi++010VEqkFgJHKC09uJiW9UkXvMUuKHUCQ= -github.com/onsi/gomega v1.10.5 h1:7n6FEkpFmfCoo2t+YYqXH0evK+a9ICQz0xcAy9dYcaQ= -github.com/onsi/gomega v1.10.5/go.mod h1:gza4q3jKQJijlu05nKWRCW/GavJumGt8aNRxWg7mt48= +github.com/onsi/gomega v1.11.0 h1:+CqWgvj0OZycCaqclBD1pxKHAU+tOkHmQIWvDHq2aug= +github.com/onsi/gomega v1.11.0/go.mod h1:azGKhqFUon9Vuj0YmTfLSmx0FUwqXYSTl5re8lQLTUg= github.com/pelletier/go-toml v1.8.1 h1:1Nf83orprkJyknT6h7zbuEGUEjcyVlCxSUGTENmNCRM= github.com/pelletier/go-toml v1.8.1/go.mod h1:T2/BmBdy8dvIRq1a/8aqjN41wvWlN4lrapLU/GW4pbc= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= @@ -92,5 +94,7 @@ gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWD gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.3.0 h1:clyUAQHOM3G0M3f5vQj7LuJrETvjVot3Z5el9nffUtU= gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= +gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= +gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c h1:dUUwHk2QECo/6vqA44rthZ8ie2QXMNeKRTHCNY2nXvo= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= From 2c3b0643bd0398ba5fdbadc764513c4ab20466ee Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 10 Mar 2021 06:01:44 +0000 Subject: [PATCH 12/44] Bump github.com/imdario/mergo from 0.3.11 to 0.3.12 Bumps [github.com/imdario/mergo](https://github.com/imdario/mergo) from 0.3.11 to 0.3.12. - [Release notes](https://github.com/imdario/mergo/releases) - [Commits](https://github.com/imdario/mergo/compare/v0.3.11...0.3.12) Signed-off-by: dependabot[bot] --- go.mod | 2 +- go.sum | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/go.mod b/go.mod index 1249111..3ae775d 100644 --- a/go.mod +++ b/go.mod @@ -7,7 +7,7 @@ require ( github.com/buildpacks/libcnb v1.19.0 github.com/creack/pty v1.1.11 github.com/heroku/color v0.0.6 - github.com/imdario/mergo v0.3.11 + github.com/imdario/mergo v0.3.12 github.com/onsi/gomega v1.11.0 github.com/pelletier/go-toml v1.8.1 github.com/sclevine/spec v1.4.0 diff --git a/go.sum b/go.sum index 213145a..6e06b26 100644 --- a/go.sum +++ b/go.sum @@ -28,8 +28,8 @@ github.com/google/go-cmp v0.4.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/ github.com/heroku/color v0.0.6 h1:UTFFMrmMLFcL3OweqP1lAdp8i1y/9oHqkeHjQ/b/Ny0= github.com/heroku/color v0.0.6/go.mod h1:ZBvOcx7cTF2QKOv4LbmoBtNl5uB17qWxGuzZrsi1wLU= github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU= -github.com/imdario/mergo v0.3.11 h1:3tnifQM4i+fbajXKBHXWEH+KvNHqojZ778UH75j3bGA= -github.com/imdario/mergo v0.3.11/go.mod h1:jmQim1M+e3UYxmgPu/WyfjB3N3VflVyUjjjwH0dnCYA= +github.com/imdario/mergo v0.3.12 h1:b6R2BslTbIEToALKP7LxUvijTsNI9TAe80pLWN2g/HU= +github.com/imdario/mergo v0.3.12/go.mod h1:jmQim1M+e3UYxmgPu/WyfjB3N3VflVyUjjjwH0dnCYA= github.com/mattn/go-colorable v0.1.2 h1:/bC9yWikZXAL9uJdulbSfyVNIR3n3trXl+v8+1sx8mU= github.com/mattn/go-colorable v0.1.2/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE= github.com/mattn/go-isatty v0.0.8 h1:HLtExJ+uU2HOZ+wI0Tt5DtUDrx8yhUqDcp7fYERX4CE= From 46a74cf5a0c1365a848401cef3815741f7c82b77 Mon Sep 17 00:00:00 2001 From: paketo-bot Date: Thu, 11 Mar 2021 05:20:14 +0000 Subject: [PATCH 13/44] Bump pipeline from 1.9.2 to 1.9.3 Bumps pipeline from 1.9.2 to 1.9.3. Signed-off-by: GitHub --- .github/pipeline-version | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/pipeline-version b/.github/pipeline-version index 8fdcf38..77fee73 100644 --- a/.github/pipeline-version +++ b/.github/pipeline-version @@ -1 +1 @@ -1.9.2 +1.9.3 From da5eff5ba67a34b55825d8cb17be8fe557e74f89 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 6 Apr 2021 06:02:19 +0000 Subject: [PATCH 14/44] Bump github.com/pelletier/go-toml from 1.8.1 to 1.9.0 Bumps [github.com/pelletier/go-toml](https://github.com/pelletier/go-toml) from 1.8.1 to 1.9.0. - [Release notes](https://github.com/pelletier/go-toml/releases) - [Commits](https://github.com/pelletier/go-toml/compare/v1.8.1...v1.9.0) Signed-off-by: dependabot[bot] --- go.mod | 2 +- go.sum | 10 +++------- 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/go.mod b/go.mod index 3ae775d..8f7842a 100644 --- a/go.mod +++ b/go.mod @@ -9,7 +9,7 @@ require ( github.com/heroku/color v0.0.6 github.com/imdario/mergo v0.3.12 github.com/onsi/gomega v1.11.0 - github.com/pelletier/go-toml v1.8.1 + github.com/pelletier/go-toml v1.9.0 github.com/sclevine/spec v1.4.0 github.com/spf13/pflag v1.0.5 github.com/stretchr/testify v1.7.0 diff --git a/go.sum b/go.sum index 6e06b26..a0daf7c 100644 --- a/go.sum +++ b/go.sum @@ -6,9 +6,8 @@ github.com/buildpacks/libcnb v1.19.0 h1:7Frn3qErlVmQydk95YXmHtpmf5bZ1l7h4rK/C+SK github.com/buildpacks/libcnb v1.19.0/go.mod h1:slnOsywO4mNdkShkwX1GYR+kQF1tH2F9Urfr66lWGQs= github.com/creack/pty v1.1.11 h1:07n33Z8lZxZ2qwegKbObQohDhXDQxiMMz1NOUGYlesw= github.com/creack/pty v1.1.11/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= +github.com/davecgh/go-spew v1.1.0 h1:ZDRjVQ15GmhC3fiQ8ni8+OwkZQO4DARzQgrnXU1Liz8= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= -github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/fsnotify/fsnotify v1.4.7 h1:IXs+QLmnXW2CcXuY+8Mzv/fWEsPGWxqefPtCP5CnV9I= github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= @@ -17,7 +16,6 @@ github.com/golang/protobuf v1.4.0-rc.1.0.20200221234624-67d41d38c208/go.mod h1:x github.com/golang/protobuf v1.4.0-rc.2/go.mod h1:LlEzMj4AhA7rCAGe4KMBDvJI+AwstrUpVNzEA03Pprs= github.com/golang/protobuf v1.4.0-rc.4.0.20200313231945-b860323f09d0/go.mod h1:WU3c8KckQ9AFe+yFwt9sWVRKCVIyN9cPHBJSNnbL67w= github.com/golang/protobuf v1.4.0/go.mod h1:jodUvKwWbYaEsadDk5Fwe5c77LiNKVO9IDvqG2KuDX0= -github.com/golang/protobuf v1.4.2 h1:+Z5KGCizgyZCbGh1KZqA0fcLLkwbsjIzS4aV2v7wJX0= github.com/golang/protobuf v1.4.2/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= github.com/golang/protobuf v1.4.3 h1:JjCZWpVbqXDqFVmTfYWEVTMIYrL/NPdPSCHPJ0T/raM= github.com/golang/protobuf v1.4.3/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= @@ -40,12 +38,11 @@ github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+W github.com/onsi/ginkgo v1.12.1 h1:mFwc4LvZ0xpSvDZ3E+k8Yte0hLOMxXUlP+yXtJqkYfQ= github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk= github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY= -github.com/onsi/gomega v1.10.4 h1:NiTx7EEvBzu9sFOD1zORteLSt3o8gnlvZZwSE9TnY9U= github.com/onsi/gomega v1.10.4/go.mod h1:g/HbgYopi++010VEqkFgJHKC09uJiW9UkXvMUuKHUCQ= github.com/onsi/gomega v1.11.0 h1:+CqWgvj0OZycCaqclBD1pxKHAU+tOkHmQIWvDHq2aug= github.com/onsi/gomega v1.11.0/go.mod h1:azGKhqFUon9Vuj0YmTfLSmx0FUwqXYSTl5re8lQLTUg= -github.com/pelletier/go-toml v1.8.1 h1:1Nf83orprkJyknT6h7zbuEGUEjcyVlCxSUGTENmNCRM= -github.com/pelletier/go-toml v1.8.1/go.mod h1:T2/BmBdy8dvIRq1a/8aqjN41wvWlN4lrapLU/GW4pbc= +github.com/pelletier/go-toml v1.9.0 h1:NOd0BRdOKpPf0SxkL3HxSQOG7rNh+4kl6PHcBPFs7Q0= +github.com/pelletier/go-toml v1.9.0/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/sclevine/spec v1.4.0 h1:z/Q9idDcay5m5irkZ28M7PtQM4aOISzOpj4bUPkDee8= @@ -92,7 +89,6 @@ gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMy gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= -gopkg.in/yaml.v2 v2.3.0 h1:clyUAQHOM3G0M3f5vQj7LuJrETvjVot3Z5el9nffUtU= gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= From 305e111d5da23b03a88f37c6a3b20fb009110f20 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 12 Apr 2021 07:05:29 +0000 Subject: [PATCH 15/44] Bump github.com/buildpacks/libcnb from 1.19.0 to 1.20.0 Bumps [github.com/buildpacks/libcnb](https://github.com/buildpacks/libcnb) from 1.19.0 to 1.20.0. - [Release notes](https://github.com/buildpacks/libcnb/releases) - [Commits](https://github.com/buildpacks/libcnb/compare/v1.19.0...v1.20.0) Signed-off-by: dependabot[bot] --- go.mod | 2 +- go.sum | 9 ++------- 2 files changed, 3 insertions(+), 8 deletions(-) diff --git a/go.mod b/go.mod index 3ae775d..bbd6b23 100644 --- a/go.mod +++ b/go.mod @@ -4,7 +4,7 @@ go 1.15 require ( github.com/Masterminds/semver/v3 v3.1.1 - github.com/buildpacks/libcnb v1.19.0 + github.com/buildpacks/libcnb v1.20.0 github.com/creack/pty v1.1.11 github.com/heroku/color v0.0.6 github.com/imdario/mergo v0.3.12 diff --git a/go.sum b/go.sum index 6e06b26..4bf0282 100644 --- a/go.sum +++ b/go.sum @@ -2,8 +2,8 @@ github.com/BurntSushi/toml v0.3.1 h1:WXkYYl6Yr3qBf1K79EBnL4mak0OimBfB0XUf9Vl28OQ github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/Masterminds/semver/v3 v3.1.1 h1:hLg3sBzpNErnxhQtUy/mmLR2I9foDujNK030IGemrRc= github.com/Masterminds/semver/v3 v3.1.1/go.mod h1:VPu/7SZ7ePZ3QOrcuXROw5FAcLl4a0cBrbBpGY/8hQs= -github.com/buildpacks/libcnb v1.19.0 h1:7Frn3qErlVmQydk95YXmHtpmf5bZ1l7h4rK/C+SKAmY= -github.com/buildpacks/libcnb v1.19.0/go.mod h1:slnOsywO4mNdkShkwX1GYR+kQF1tH2F9Urfr66lWGQs= +github.com/buildpacks/libcnb v1.20.0 h1:BpqAgWLmSbu2/IHMsO+BdqwDejP8jw3EDTx4vN1INvA= +github.com/buildpacks/libcnb v1.20.0/go.mod h1:q+nl2Cg76musVOM5CRFeasdbY23FNEz4kvOkZeEUyaM= github.com/creack/pty v1.1.11 h1:07n33Z8lZxZ2qwegKbObQohDhXDQxiMMz1NOUGYlesw= github.com/creack/pty v1.1.11/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= @@ -17,8 +17,6 @@ github.com/golang/protobuf v1.4.0-rc.1.0.20200221234624-67d41d38c208/go.mod h1:x github.com/golang/protobuf v1.4.0-rc.2/go.mod h1:LlEzMj4AhA7rCAGe4KMBDvJI+AwstrUpVNzEA03Pprs= github.com/golang/protobuf v1.4.0-rc.4.0.20200313231945-b860323f09d0/go.mod h1:WU3c8KckQ9AFe+yFwt9sWVRKCVIyN9cPHBJSNnbL67w= github.com/golang/protobuf v1.4.0/go.mod h1:jodUvKwWbYaEsadDk5Fwe5c77LiNKVO9IDvqG2KuDX0= -github.com/golang/protobuf v1.4.2 h1:+Z5KGCizgyZCbGh1KZqA0fcLLkwbsjIzS4aV2v7wJX0= -github.com/golang/protobuf v1.4.2/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= github.com/golang/protobuf v1.4.3 h1:JjCZWpVbqXDqFVmTfYWEVTMIYrL/NPdPSCHPJ0T/raM= github.com/golang/protobuf v1.4.3/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= @@ -40,8 +38,6 @@ github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+W github.com/onsi/ginkgo v1.12.1 h1:mFwc4LvZ0xpSvDZ3E+k8Yte0hLOMxXUlP+yXtJqkYfQ= github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk= github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY= -github.com/onsi/gomega v1.10.4 h1:NiTx7EEvBzu9sFOD1zORteLSt3o8gnlvZZwSE9TnY9U= -github.com/onsi/gomega v1.10.4/go.mod h1:g/HbgYopi++010VEqkFgJHKC09uJiW9UkXvMUuKHUCQ= github.com/onsi/gomega v1.11.0 h1:+CqWgvj0OZycCaqclBD1pxKHAU+tOkHmQIWvDHq2aug= github.com/onsi/gomega v1.11.0/go.mod h1:azGKhqFUon9Vuj0YmTfLSmx0FUwqXYSTl5re8lQLTUg= github.com/pelletier/go-toml v1.8.1 h1:1Nf83orprkJyknT6h7zbuEGUEjcyVlCxSUGTENmNCRM= @@ -92,7 +88,6 @@ gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMy gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= -gopkg.in/yaml.v2 v2.3.0 h1:clyUAQHOM3G0M3f5vQj7LuJrETvjVot3Z5el9nffUtU= gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= From 6b2cbc5ff31f9381b1d8f535de4dc4767db3f025 Mon Sep 17 00:00:00 2001 From: Daniel Mikusa Date: Mon, 12 Apr 2021 15:06:26 -0400 Subject: [PATCH 16/44] Update tests to be compatible with libcnb-1.20 & API 0.6 --- build_test.go | 2 +- detect_test.go | 2 +- layer_test.go | 24 ++++++++++++++---------- main_test.go | 2 +- 4 files changed, 17 insertions(+), 13 deletions(-) diff --git a/build_test.go b/build_test.go index 8e4dfe4..2e3bde4 100644 --- a/build_test.go +++ b/build_test.go @@ -106,7 +106,7 @@ func testBuild(t *testing.T, context spec.G, it spec.S) { it("handles error from Builder", func() { Expect(ioutil.WriteFile(filepath.Join(buildpackPath, "buildpack.toml"), []byte(` -api = "0.5" +api = "0.6" [buildpack] name = "test-name" diff --git a/detect_test.go b/detect_test.go index 02e64af..8a92627 100644 --- a/detect_test.go +++ b/detect_test.go @@ -100,7 +100,7 @@ func testDetect(t *testing.T, context spec.G, it spec.S) { it("handles error from Detector", func() { Expect(ioutil.WriteFile(filepath.Join(buildpackPath, "buildpack.toml"), []byte(` -api = "0.5" +api = "0.6" [buildpack] name = "test-name" diff --git a/layer_test.go b/layer_test.go index c62b4e5..0d7effe 100644 --- a/layer_test.go +++ b/layer_test.go @@ -502,11 +502,13 @@ func testLayer(t *testing.T, context spec.G, it spec.S) { it("does not call function with matching metadata", func() { layer.Metadata = map[string]interface{}{ - "id": buildpack.Info.ID, - "name": buildpack.Info.Name, - "version": buildpack.Info.Version, - "homepage": buildpack.Info.Homepage, - "clear-env": buildpack.Info.ClearEnvironment, + "id": buildpack.Info.ID, + "name": buildpack.Info.Name, + "version": buildpack.Info.Version, + "homepage": buildpack.Info.Homepage, + "clear-env": buildpack.Info.ClearEnvironment, + "description": "", + "keywords": []interface{}{}, } _, err := hlc.Contribute(layer) @@ -521,11 +523,13 @@ func testLayer(t *testing.T, context spec.G, it spec.S) { Expect(err).NotTo(HaveOccurred()) Expect(layer.Metadata).To(Equal(map[string]interface{}{ - "id": buildpack.Info.ID, - "name": buildpack.Info.Name, - "version": buildpack.Info.Version, - "homepage": buildpack.Info.Homepage, - "clear-env": buildpack.Info.ClearEnvironment, + "id": buildpack.Info.ID, + "name": buildpack.Info.Name, + "version": buildpack.Info.Version, + "homepage": buildpack.Info.Homepage, + "clear-env": buildpack.Info.ClearEnvironment, + "description": "", + "keywords": []interface{}{}, })) }) }) diff --git a/main_test.go b/main_test.go index a4ffd63..4140d7d 100644 --- a/main_test.go +++ b/main_test.go @@ -66,7 +66,7 @@ func testMain(t *testing.T, context spec.G, it spec.S) { Expect(ioutil.WriteFile(filepath.Join(buildpackPath, "buildpack.toml"), []byte(` -api = "0.5" +api = "0.6" [buildpack] id = "test-id" From eb2ad35eaf1f991fb0bd0770da77eb335e603512 Mon Sep 17 00:00:00 2001 From: paketo-bot Date: Thu, 27 May 2021 05:58:53 +0000 Subject: [PATCH 17/44] Bump pipeline from 1.9.3 to 1.10.0 Bumps pipeline from 1.9.3 to 1.10.0. Signed-off-by: GitHub --- .github/pipeline-version | 2 +- .github/workflows/tests.yml | 4 ++-- .github/workflows/update-pipeline.yml | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/pipeline-version b/.github/pipeline-version index 77fee73..81c871d 100644 --- a/.github/pipeline-version +++ b/.github/pipeline-version @@ -1 +1 @@ -1.9.3 +1.10.0 diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 8a9f2bd..8203c9c 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -18,7 +18,7 @@ jobs: restore-keys: ${{ runner.os }}-go- - uses: actions/setup-go@v2 with: - go-version: "1.15" + go-version: "1.16" - name: Install richgo run: | #!/usr/bin/env bash @@ -37,7 +37,7 @@ jobs: "https://github.com/kyoh86/richgo/releases/download/v${RICHGO_VERSION}/richgo_${RICHGO_VERSION}_linux_amd64.tar.gz" \ | tar -C "${HOME}"/bin -xz richgo env: - RICHGO_VERSION: 0.3.3 + RICHGO_VERSION: 0.3.6 - name: Run Tests run: | #!/usr/bin/env bash diff --git a/.github/workflows/update-pipeline.yml b/.github/workflows/update-pipeline.yml index 0f70aa4..6779037 100644 --- a/.github/workflows/update-pipeline.yml +++ b/.github/workflows/update-pipeline.yml @@ -16,7 +16,7 @@ jobs: steps: - uses: actions/setup-go@v2 with: - go-version: "1.15" + go-version: "1.16" - name: Install octo run: | #!/usr/bin/env bash From ecc1da89aa08ed78ad4de6a7ad93a429568cae88 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 31 May 2021 06:13:16 +0000 Subject: [PATCH 18/44] Bump github.com/creack/pty from 1.1.11 to 1.1.13 Bumps [github.com/creack/pty](https://github.com/creack/pty) from 1.1.11 to 1.1.13. - [Release notes](https://github.com/creack/pty/releases) - [Commits](https://github.com/creack/pty/compare/v1.1.11...v1.1.13) Signed-off-by: dependabot[bot] --- go.mod | 2 +- go.sum | 6 ++---- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/go.mod b/go.mod index 99f2282..05de69c 100644 --- a/go.mod +++ b/go.mod @@ -5,7 +5,7 @@ go 1.15 require ( github.com/Masterminds/semver/v3 v3.1.1 github.com/buildpacks/libcnb v1.20.0 - github.com/creack/pty v1.1.11 + github.com/creack/pty v1.1.13 github.com/heroku/color v0.0.6 github.com/imdario/mergo v0.3.12 github.com/onsi/gomega v1.11.0 diff --git a/go.sum b/go.sum index 953938a..1c2af81 100644 --- a/go.sum +++ b/go.sum @@ -4,8 +4,8 @@ github.com/Masterminds/semver/v3 v3.1.1 h1:hLg3sBzpNErnxhQtUy/mmLR2I9foDujNK030I github.com/Masterminds/semver/v3 v3.1.1/go.mod h1:VPu/7SZ7ePZ3QOrcuXROw5FAcLl4a0cBrbBpGY/8hQs= github.com/buildpacks/libcnb v1.20.0 h1:BpqAgWLmSbu2/IHMsO+BdqwDejP8jw3EDTx4vN1INvA= github.com/buildpacks/libcnb v1.20.0/go.mod h1:q+nl2Cg76musVOM5CRFeasdbY23FNEz4kvOkZeEUyaM= -github.com/creack/pty v1.1.11 h1:07n33Z8lZxZ2qwegKbObQohDhXDQxiMMz1NOUGYlesw= -github.com/creack/pty v1.1.11/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= +github.com/creack/pty v1.1.13 h1:rTPnd/xocYRjutMfqide2zle1u96upp1gm6eUHKi7us= +github.com/creack/pty v1.1.13/go.mod h1:MOBLtS5ELjhRRrroQr9kyvTxUAFNvYEK993ew/Vr4O4= github.com/davecgh/go-spew v1.1.0 h1:ZDRjVQ15GmhC3fiQ8ni8+OwkZQO4DARzQgrnXU1Liz8= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/fsnotify/fsnotify v1.4.7 h1:IXs+QLmnXW2CcXuY+8Mzv/fWEsPGWxqefPtCP5CnV9I= @@ -16,7 +16,6 @@ github.com/golang/protobuf v1.4.0-rc.1.0.20200221234624-67d41d38c208/go.mod h1:x github.com/golang/protobuf v1.4.0-rc.2/go.mod h1:LlEzMj4AhA7rCAGe4KMBDvJI+AwstrUpVNzEA03Pprs= github.com/golang/protobuf v1.4.0-rc.4.0.20200313231945-b860323f09d0/go.mod h1:WU3c8KckQ9AFe+yFwt9sWVRKCVIyN9cPHBJSNnbL67w= github.com/golang/protobuf v1.4.0/go.mod h1:jodUvKwWbYaEsadDk5Fwe5c77LiNKVO9IDvqG2KuDX0= -github.com/golang/protobuf v1.4.2/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= github.com/golang/protobuf v1.4.3 h1:JjCZWpVbqXDqFVmTfYWEVTMIYrL/NPdPSCHPJ0T/raM= github.com/golang/protobuf v1.4.3/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= @@ -38,7 +37,6 @@ github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+W github.com/onsi/ginkgo v1.12.1 h1:mFwc4LvZ0xpSvDZ3E+k8Yte0hLOMxXUlP+yXtJqkYfQ= github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk= github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY= -github.com/onsi/gomega v1.10.4/go.mod h1:g/HbgYopi++010VEqkFgJHKC09uJiW9UkXvMUuKHUCQ= github.com/onsi/gomega v1.11.0 h1:+CqWgvj0OZycCaqclBD1pxKHAU+tOkHmQIWvDHq2aug= github.com/onsi/gomega v1.11.0/go.mod h1:azGKhqFUon9Vuj0YmTfLSmx0FUwqXYSTl5re8lQLTUg= github.com/pelletier/go-toml v1.9.0 h1:NOd0BRdOKpPf0SxkL3HxSQOG7rNh+4kl6PHcBPFs7Q0= From 7ced65ab0e4e889a3c44b5208f2a0a103c7ead87 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 7 Jun 2021 06:20:49 +0000 Subject: [PATCH 19/44] Bump github.com/pelletier/go-toml from 1.9.0 to 1.9.2 Bumps [github.com/pelletier/go-toml](https://github.com/pelletier/go-toml) from 1.9.0 to 1.9.2. - [Release notes](https://github.com/pelletier/go-toml/releases) - [Commits](https://github.com/pelletier/go-toml/compare/v1.9.0...v1.9.2) --- updated-dependencies: - dependency-name: github.com/pelletier/go-toml dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- go.mod | 2 +- go.sum | 6 ++---- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/go.mod b/go.mod index 99f2282..9faa2b1 100644 --- a/go.mod +++ b/go.mod @@ -9,7 +9,7 @@ require ( github.com/heroku/color v0.0.6 github.com/imdario/mergo v0.3.12 github.com/onsi/gomega v1.11.0 - github.com/pelletier/go-toml v1.9.0 + github.com/pelletier/go-toml v1.9.2 github.com/sclevine/spec v1.4.0 github.com/spf13/pflag v1.0.5 github.com/stretchr/testify v1.7.0 diff --git a/go.sum b/go.sum index 953938a..e63af02 100644 --- a/go.sum +++ b/go.sum @@ -16,7 +16,6 @@ github.com/golang/protobuf v1.4.0-rc.1.0.20200221234624-67d41d38c208/go.mod h1:x github.com/golang/protobuf v1.4.0-rc.2/go.mod h1:LlEzMj4AhA7rCAGe4KMBDvJI+AwstrUpVNzEA03Pprs= github.com/golang/protobuf v1.4.0-rc.4.0.20200313231945-b860323f09d0/go.mod h1:WU3c8KckQ9AFe+yFwt9sWVRKCVIyN9cPHBJSNnbL67w= github.com/golang/protobuf v1.4.0/go.mod h1:jodUvKwWbYaEsadDk5Fwe5c77LiNKVO9IDvqG2KuDX0= -github.com/golang/protobuf v1.4.2/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= github.com/golang/protobuf v1.4.3 h1:JjCZWpVbqXDqFVmTfYWEVTMIYrL/NPdPSCHPJ0T/raM= github.com/golang/protobuf v1.4.3/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= @@ -38,11 +37,10 @@ github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+W github.com/onsi/ginkgo v1.12.1 h1:mFwc4LvZ0xpSvDZ3E+k8Yte0hLOMxXUlP+yXtJqkYfQ= github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk= github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY= -github.com/onsi/gomega v1.10.4/go.mod h1:g/HbgYopi++010VEqkFgJHKC09uJiW9UkXvMUuKHUCQ= github.com/onsi/gomega v1.11.0 h1:+CqWgvj0OZycCaqclBD1pxKHAU+tOkHmQIWvDHq2aug= github.com/onsi/gomega v1.11.0/go.mod h1:azGKhqFUon9Vuj0YmTfLSmx0FUwqXYSTl5re8lQLTUg= -github.com/pelletier/go-toml v1.9.0 h1:NOd0BRdOKpPf0SxkL3HxSQOG7rNh+4kl6PHcBPFs7Q0= -github.com/pelletier/go-toml v1.9.0/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c= +github.com/pelletier/go-toml v1.9.2 h1:7NiByeVF4jKSG1lDF3X8LTIkq2/bu+1uYbIm1eS5tzk= +github.com/pelletier/go-toml v1.9.2/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/sclevine/spec v1.4.0 h1:z/Q9idDcay5m5irkZ28M7PtQM4aOISzOpj4bUPkDee8= From c0f0ba34da3b04bac5dedb3cc14d1e31b8d9bd2c Mon Sep 17 00:00:00 2001 From: Daniel Mikusa Date: Mon, 7 Jun 2021 12:03:31 -0400 Subject: [PATCH 20/44] Persist expected layer types even when layer is cached. This is required due to a change in the lifecycle API 0.6. See https://github.com/buildpacks/lifecycle/pull/537. --- layer.go | 2 +- layer_test.go | 86 +++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 87 insertions(+), 1 deletion(-) diff --git a/layer.go b/layer.go index 48670fb..1967ec0 100644 --- a/layer.go +++ b/layer.go @@ -61,7 +61,6 @@ func NewLayerContributor(name string, expectedMetadata interface{}, expectedType // LayerFunc is a callback function that is invoked when a layer needs to be contributed. type LayerFunc func() (libcnb.Layer, error) - // Contribute is the function to call when implementing your libcnb.LayerContributor. func (l *LayerContributor) Contribute(layer libcnb.Layer, f LayerFunc) (libcnb.Layer, error) { raw, err := toml.Marshal(l.ExpectedMetadata) @@ -80,6 +79,7 @@ func (l *LayerContributor) Contribute(layer libcnb.Layer, f LayerFunc) (libcnb.L // TODO: compare entire layer not just metadata (in case build, launch, or cache have changed) if reflect.DeepEqual(expected, layer.Metadata) { l.Logger.Headerf("%s: %s cached layer", color.BlueString(l.Name), color.GreenString("Reusing")) + layer.LayerTypes = l.ExpectedTypes return layer, nil } diff --git a/layer_test.go b/layer_test.go index 0d7effe..bc10d77 100644 --- a/layer_test.go +++ b/layer_test.go @@ -167,6 +167,33 @@ func testLayer(t *testing.T, context spec.G, it spec.S) { Expect(layer.LayerTypes.Launch).To(BeTrue()) }) + + it("sets layer flags regardless of caching behavior (required for 0.6 API)", func() { + lc.ExpectedTypes.Launch = true + lc.ExpectedTypes.Cache = true + lc.ExpectedTypes.Build = true + + layer.Metadata = map[string]interface{}{ + "alpha": "test-alpha", + "bravo": map[string]interface{}{ + "bravo-1": "test-bravo-1", + "bravo-2": "test-bravo-2", + }, + } + + var called bool + + layer, err := lc.Contribute(layer, func() (libcnb.Layer, error) { + called = true + return layer, nil + }) + Expect(err).NotTo(HaveOccurred()) + Expect(called).To(BeFalse()) + + Expect(layer.LayerTypes.Launch).To(BeTrue()) + Expect(layer.LayerTypes.Cache).To(BeTrue()) + Expect(layer.LayerTypes.Build).To(BeTrue()) + }) }) context("NewDependencyLayer", func() { @@ -417,6 +444,42 @@ func testLayer(t *testing.T, context spec.G, it spec.S) { }, })) }) + + it("sets layer flags regardless of caching behavior (required for 0.6 API)", func() { + layer.Metadata = map[string]interface{}{ + "id": dependency.ID, + "name": dependency.Name, + "version": dependency.Version, + "uri": dependency.URI, + "sha256": dependency.SHA256, + "stacks": []interface{}{dependency.Stacks[0]}, + "licenses": []map[string]interface{}{ + { + "type": dependency.Licenses[0].Type, + "uri": dependency.Licenses[0].URI, + }, + }, + } + dlc.ExpectedTypes.Launch = true + dlc.ExpectedTypes.Cache = true + dlc.ExpectedTypes.Build = true + + var called bool + + layer, err := dlc.Contribute(layer, func(artifact *os.File) (libcnb.Layer, error) { + defer artifact.Close() + + called = true + return layer, nil + }) + Expect(err).NotTo(HaveOccurred()) + + Expect(called).To(BeFalse()) + + Expect(layer.LayerTypes.Launch).To(BeTrue()) + Expect(layer.LayerTypes.Cache).To(BeTrue()) + Expect(layer.LayerTypes.Build).To(BeTrue()) + }) }) context("NewHelperLayer", func() { @@ -532,5 +595,28 @@ func testLayer(t *testing.T, context spec.G, it spec.S) { "keywords": []interface{}{}, })) }) + + it("sets layer flags regardless of caching behavior (required for 0.6 API)", func() { + layer.Metadata = map[string]interface{}{ + "id": buildpack.Info.ID, + "name": buildpack.Info.Name, + "version": buildpack.Info.Version, + "homepage": buildpack.Info.Homepage, + "clear-env": buildpack.Info.ClearEnvironment, + "description": "", + "keywords": []interface{}{}, + } + // Launch is the only one set & always true + + layer, err := hlc.Contribute(layer) + Expect(err).NotTo(HaveOccurred()) + + Expect(filepath.Join(layer.Exec.FilePath("test-name-1"))).NotTo(BeAnExistingFile()) + Expect(filepath.Join(layer.Exec.FilePath("test-name-2"))).NotTo(BeAnExistingFile()) + + Expect(layer.LayerTypes.Launch).To(BeTrue()) + Expect(layer.LayerTypes.Cache).To(BeFalse()) + Expect(layer.LayerTypes.Build).To(BeFalse()) + }) }) } From 61f83a211d1e5a0e40271bae0eb2c051f69d84ca Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 7 Jun 2021 16:08:10 +0000 Subject: [PATCH 21/44] Bump github.com/buildpacks/libcnb from 1.20.0 to 1.21.0 Bumps [github.com/buildpacks/libcnb](https://github.com/buildpacks/libcnb) from 1.20.0 to 1.21.0. - [Release notes](https://github.com/buildpacks/libcnb/releases) - [Commits](https://github.com/buildpacks/libcnb/compare/v1.20.0...v1.21.0) Signed-off-by: dependabot[bot] --- go.mod | 2 +- go.sum | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/go.mod b/go.mod index 07185d1..91e4c1b 100644 --- a/go.mod +++ b/go.mod @@ -4,7 +4,7 @@ go 1.15 require ( github.com/Masterminds/semver/v3 v3.1.1 - github.com/buildpacks/libcnb v1.20.0 + github.com/buildpacks/libcnb v1.21.0 github.com/creack/pty v1.1.13 github.com/heroku/color v0.0.6 github.com/imdario/mergo v0.3.12 diff --git a/go.sum b/go.sum index 17805fa..ee3e7bd 100644 --- a/go.sum +++ b/go.sum @@ -2,8 +2,8 @@ github.com/BurntSushi/toml v0.3.1 h1:WXkYYl6Yr3qBf1K79EBnL4mak0OimBfB0XUf9Vl28OQ github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/Masterminds/semver/v3 v3.1.1 h1:hLg3sBzpNErnxhQtUy/mmLR2I9foDujNK030IGemrRc= github.com/Masterminds/semver/v3 v3.1.1/go.mod h1:VPu/7SZ7ePZ3QOrcuXROw5FAcLl4a0cBrbBpGY/8hQs= -github.com/buildpacks/libcnb v1.20.0 h1:BpqAgWLmSbu2/IHMsO+BdqwDejP8jw3EDTx4vN1INvA= -github.com/buildpacks/libcnb v1.20.0/go.mod h1:q+nl2Cg76musVOM5CRFeasdbY23FNEz4kvOkZeEUyaM= +github.com/buildpacks/libcnb v1.21.0 h1:GBK02W22lm1ie8E4hBGStNfShLa/CWbjoBD1kfqAKT4= +github.com/buildpacks/libcnb v1.21.0/go.mod h1:q+nl2Cg76musVOM5CRFeasdbY23FNEz4kvOkZeEUyaM= github.com/creack/pty v1.1.13 h1:rTPnd/xocYRjutMfqide2zle1u96upp1gm6eUHKi7us= github.com/creack/pty v1.1.13/go.mod h1:MOBLtS5ELjhRRrroQr9kyvTxUAFNvYEK993ew/Vr4O4= github.com/davecgh/go-spew v1.1.0 h1:ZDRjVQ15GmhC3fiQ8ni8+OwkZQO4DARzQgrnXU1Liz8= From f0c72e3d211c88db95aa30dabd1c2bad94ebd7a6 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 7 Jun 2021 16:08:12 +0000 Subject: [PATCH 22/44] Bump github.com/onsi/gomega from 1.11.0 to 1.13.0 Bumps [github.com/onsi/gomega](https://github.com/onsi/gomega) from 1.11.0 to 1.13.0. - [Release notes](https://github.com/onsi/gomega/releases) - [Changelog](https://github.com/onsi/gomega/blob/master/CHANGELOG.md) - [Commits](https://github.com/onsi/gomega/compare/v1.11.0...v1.13.0) Signed-off-by: dependabot[bot] --- go.mod | 2 +- go.sum | 60 ++++++++++++++++++++++++++++++++++++++++++++++------------ 2 files changed, 49 insertions(+), 13 deletions(-) diff --git a/go.mod b/go.mod index 07185d1..9f9d9e8 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/creack/pty v1.1.13 github.com/heroku/color v0.0.6 github.com/imdario/mergo v0.3.12 - github.com/onsi/gomega v1.11.0 + github.com/onsi/gomega v1.13.0 github.com/pelletier/go-toml v1.9.2 github.com/sclevine/spec v1.4.0 github.com/spf13/pflag v1.0.5 diff --git a/go.sum b/go.sum index 17805fa..283081f 100644 --- a/go.sum +++ b/go.sum @@ -6,22 +6,29 @@ github.com/buildpacks/libcnb v1.20.0 h1:BpqAgWLmSbu2/IHMsO+BdqwDejP8jw3EDTx4vN1I github.com/buildpacks/libcnb v1.20.0/go.mod h1:q+nl2Cg76musVOM5CRFeasdbY23FNEz4kvOkZeEUyaM= github.com/creack/pty v1.1.13 h1:rTPnd/xocYRjutMfqide2zle1u96upp1gm6eUHKi7us= github.com/creack/pty v1.1.13/go.mod h1:MOBLtS5ELjhRRrroQr9kyvTxUAFNvYEK993ew/Vr4O4= -github.com/davecgh/go-spew v1.1.0 h1:ZDRjVQ15GmhC3fiQ8ni8+OwkZQO4DARzQgrnXU1Liz8= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/fsnotify/fsnotify v1.4.7 h1:IXs+QLmnXW2CcXuY+8Mzv/fWEsPGWxqefPtCP5CnV9I= +github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= +github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= +github.com/fsnotify/fsnotify v1.4.9 h1:hsms1Qyu0jgnwNXIxa+/V/PDsU6CfLf6CNO8H7IWoS4= +github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ= +github.com/go-task/slim-sprig v0.0.0-20210107165309-348f09dbbbc0/go.mod h1:fyg7847qk6SyHyPtNmDHnmrv/HOrqktSC+C9fM+CJOE= github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.4.0-rc.1/go.mod h1:ceaxUfeHdC40wWswd/P6IGgMaK3YpKi5j83Wpe3EHw8= github.com/golang/protobuf v1.4.0-rc.1.0.20200221234624-67d41d38c208/go.mod h1:xKAWHe0F5eneWXFV3EuXVDTCmh+JuBKY0li0aMyXATA= github.com/golang/protobuf v1.4.0-rc.2/go.mod h1:LlEzMj4AhA7rCAGe4KMBDvJI+AwstrUpVNzEA03Pprs= github.com/golang/protobuf v1.4.0-rc.4.0.20200313231945-b860323f09d0/go.mod h1:WU3c8KckQ9AFe+yFwt9sWVRKCVIyN9cPHBJSNnbL67w= github.com/golang/protobuf v1.4.0/go.mod h1:jodUvKwWbYaEsadDk5Fwe5c77LiNKVO9IDvqG2KuDX0= -github.com/golang/protobuf v1.4.3 h1:JjCZWpVbqXDqFVmTfYWEVTMIYrL/NPdPSCHPJ0T/raM= +github.com/golang/protobuf v1.4.2/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= github.com/golang/protobuf v1.4.3/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= +github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk= +github.com/golang/protobuf v1.5.2 h1:ROPKBNFfQgOUMifHyP+KYbvpjbdoFNs+aK7DXlji0Tw= +github.com/golang/protobuf v1.5.2/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= github.com/google/go-cmp v0.3.1/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= -github.com/google/go-cmp v0.4.0 h1:xsAVV57WRhGj6kEIi8ReJzQlHHqcBYCElAvkovg3B/4= github.com/google/go-cmp v0.4.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= +github.com/google/go-cmp v0.5.5 h1:Khx7svrCpmxxtHBq5j2mp/xVjsi8hQMfNLvJFAlrGgU= +github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/heroku/color v0.0.6 h1:UTFFMrmMLFcL3OweqP1lAdp8i1y/9oHqkeHjQ/b/Ny0= github.com/heroku/color v0.0.6/go.mod h1:ZBvOcx7cTF2QKOv4LbmoBtNl5uB17qWxGuzZrsi1wLU= github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU= @@ -31,14 +38,18 @@ github.com/mattn/go-colorable v0.1.2 h1:/bC9yWikZXAL9uJdulbSfyVNIR3n3trXl+v8+1sx github.com/mattn/go-colorable v0.1.2/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE= github.com/mattn/go-isatty v0.0.8 h1:HLtExJ+uU2HOZ+wI0Tt5DtUDrx8yhUqDcp7fYERX4CE= github.com/mattn/go-isatty v0.0.8/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= -github.com/nxadm/tail v1.4.4 h1:DQuhQpB1tVlglWS2hLQ5OV6B5r8aGxSrPc5Qo6uTN78= github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A= +github.com/nxadm/tail v1.4.8 h1:nPr65rt6Y5JFSKQO7qToXr7pePgD6Gwiw05lkbyAQTE= +github.com/nxadm/tail v1.4.8/go.mod h1:+ncqLTQzXmGhMZNUePPaPqPvBxHAIsmXswZKocGu+AU= github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= -github.com/onsi/ginkgo v1.12.1 h1:mFwc4LvZ0xpSvDZ3E+k8Yte0hLOMxXUlP+yXtJqkYfQ= github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk= +github.com/onsi/ginkgo v1.16.2 h1:HFB2fbVIlhIfCfOW81bZFbiC/RvnpXSdhbF2/DJr134= +github.com/onsi/ginkgo v1.16.2/go.mod h1:CObGmKUOKaSC0RjmoAK7tKyn4Azo5P2IWuoMnvwxz1E= github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY= -github.com/onsi/gomega v1.11.0 h1:+CqWgvj0OZycCaqclBD1pxKHAU+tOkHmQIWvDHq2aug= +github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo= github.com/onsi/gomega v1.11.0/go.mod h1:azGKhqFUon9Vuj0YmTfLSmx0FUwqXYSTl5re8lQLTUg= +github.com/onsi/gomega v1.13.0 h1:7lLHu94wT9Ij0o6EWWclhu0aOh32VxhkwEJvzuWPeak= +github.com/onsi/gomega v1.13.0/go.mod h1:lRk9szgn8TxENtWd0Tp4c3wjlRfMTMH27I+3Je41yGY= github.com/pelletier/go-toml v1.9.2 h1:7NiByeVF4jKSG1lDF3X8LTIkq2/bu+1uYbIm1eS5tzk= github.com/pelletier/go-toml v1.9.2/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= @@ -49,43 +60,68 @@ github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= github.com/stretchr/objx v0.1.0 h1:4G4v2dO3VZwixGIRoQ5Lfboy6nUhCyYzaqnIAPPhYs4= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= +github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5cxcmMvtA= github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/xi2/xz v0.0.0-20171230120015-48954b6210f8 h1:nIPpBwaJSVYIxUFsDv3M8ofmx9yWTog9BfvIu0q41lo= github.com/xi2/xz v0.0.0-20171230120015-48954b6210f8/go.mod h1:HUYIGzjTL3rfEspMxjDjgmT5uz5wzYJKVo23qUhYTos= +github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= +golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= +golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= -golang.org/x/net v0.0.0-20201202161906-c7110b5ffcbb h1:eBmm0M9fYhWpKZLjQUUKka/LtIxf46G4fxeEz5KJr9U= +golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= +golang.org/x/net v0.0.0-20200520004742-59133d7f0dd7/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= +golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/net v0.0.0-20201202161906-c7110b5ffcbb/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= +golang.org/x/net v0.0.0-20210428140749-89ef3d95e781 h1:DzZ89McO9/gWPsQXS/FVKAlG02ZjaQ6AlZRBimEYOd0= +golang.org/x/net v0.0.0-20210428140749-89ef3d95e781/go.mod h1:OJAsFXCWl8Ukc7SiCT/9KSuxbyM7479/AVlXFRxuMCk= golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190904154756-749cb33beabd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20191005200804-aed5e4c7ecf9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191120155948-bd437916bb0e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f h1:+Nyd8tzPX9R7BWHguqsrbFdRx3WQ/1ib8I44HXV5yTA= +golang.org/x/sys v0.0.0-20200323222414-85ca7c5b95cd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210112080510-489259a85091/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210423082822-04245dca01da h1:b3NXsE2LusjYGGjL5bxEVZZORm/YEFFrWFjR8eFrw/c= +golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= -golang.org/x/text v0.3.3 h1:cokOdA+Jmi5PJGXLlLllQSgYigAEfHXJAERHVMaCc2k= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= +golang.org/x/text v0.3.6 h1:aRYxNxv6iGQlyVaZmk6ZgYEDa+Jg18DxebPSrd6bg1M= +golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4= +golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= +golang.org/x/tools v0.0.0-20201224043029-2b0845dc783e/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= +golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1 h1:go1bK/D/BFZV2I8cIQd1NKEZ+0owSTG1fDTci4IqFcE= +golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0= google.golang.org/protobuf v0.0.0-20200228230310-ab0ca4ff8a60/go.mod h1:cfTl7dwQJ+fmap5saPgwCLgHXTUD7jkjRqWcaiX5VyM= google.golang.org/protobuf v1.20.1-0.20200309200217-e05f789c0967/go.mod h1:A+miEFZTKqfCUM6K7xSMQL9OKL/b6hQv+e19PK+JZNE= google.golang.org/protobuf v1.21.0/go.mod h1:47Nbq4nVaFHyn7ilMalzfO3qCViNmqZ2kzikPIcrTAo= -google.golang.org/protobuf v1.23.0 h1:4MY060fB1DLGMB/7MBTLnwQUY6+F09GEiz6SsrNqyzM= google.golang.org/protobuf v1.23.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= +google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw= +google.golang.org/protobuf v1.26.0 h1:bxAC2xTBsZGibn2RTntX0oH50xLsqy1OxA9tTL3p/lk= +google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= +gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= From 75e390bf1d57f31a73f324cae9fb88f60d4d45d3 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 15 Jun 2021 05:48:14 +0000 Subject: [PATCH 23/44] Bump github.com/pelletier/go-toml from 1.9.2 to 1.9.3 Bumps [github.com/pelletier/go-toml](https://github.com/pelletier/go-toml) from 1.9.2 to 1.9.3. - [Release notes](https://github.com/pelletier/go-toml/releases) - [Commits](https://github.com/pelletier/go-toml/compare/v1.9.2...v1.9.3) --- updated-dependencies: - dependency-name: github.com/pelletier/go-toml dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- go.mod | 2 +- go.sum | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/go.mod b/go.mod index 560b189..0bbf88d 100644 --- a/go.mod +++ b/go.mod @@ -9,7 +9,7 @@ require ( github.com/heroku/color v0.0.6 github.com/imdario/mergo v0.3.12 github.com/onsi/gomega v1.13.0 - github.com/pelletier/go-toml v1.9.2 + github.com/pelletier/go-toml v1.9.3 github.com/sclevine/spec v1.4.0 github.com/spf13/pflag v1.0.5 github.com/stretchr/testify v1.7.0 diff --git a/go.sum b/go.sum index 5f97348..9b6486c 100644 --- a/go.sum +++ b/go.sum @@ -50,8 +50,8 @@ github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1y github.com/onsi/gomega v1.11.0/go.mod h1:azGKhqFUon9Vuj0YmTfLSmx0FUwqXYSTl5re8lQLTUg= github.com/onsi/gomega v1.13.0 h1:7lLHu94wT9Ij0o6EWWclhu0aOh32VxhkwEJvzuWPeak= github.com/onsi/gomega v1.13.0/go.mod h1:lRk9szgn8TxENtWd0Tp4c3wjlRfMTMH27I+3Je41yGY= -github.com/pelletier/go-toml v1.9.2 h1:7NiByeVF4jKSG1lDF3X8LTIkq2/bu+1uYbIm1eS5tzk= -github.com/pelletier/go-toml v1.9.2/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c= +github.com/pelletier/go-toml v1.9.3 h1:zeC5b1GviRUyKYd6OJPvBU/mcVDVoL1OhT17FCt5dSQ= +github.com/pelletier/go-toml v1.9.3/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/sclevine/spec v1.4.0 h1:z/Q9idDcay5m5irkZ28M7PtQM4aOISzOpj4bUPkDee8= From 241d22f414585e90a959fdcb902af1f2eceb19b0 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 8 Jul 2021 10:04:45 +0000 Subject: [PATCH 24/44] Bump github.com/onsi/gomega from 1.13.0 to 1.14.0 Bumps [github.com/onsi/gomega](https://github.com/onsi/gomega) from 1.13.0 to 1.14.0. - [Release notes](https://github.com/onsi/gomega/releases) - [Changelog](https://github.com/onsi/gomega/blob/master/CHANGELOG.md) - [Commits](https://github.com/onsi/gomega/compare/v1.13.0...v1.14.0) --- updated-dependencies: - dependency-name: github.com/onsi/gomega dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- go.mod | 2 +- go.sum | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/go.mod b/go.mod index 0bbf88d..230aa34 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/creack/pty v1.1.13 github.com/heroku/color v0.0.6 github.com/imdario/mergo v0.3.12 - github.com/onsi/gomega v1.13.0 + github.com/onsi/gomega v1.14.0 github.com/pelletier/go-toml v1.9.3 github.com/sclevine/spec v1.4.0 github.com/spf13/pflag v1.0.5 diff --git a/go.sum b/go.sum index 9b6486c..002eaf7 100644 --- a/go.sum +++ b/go.sum @@ -43,13 +43,13 @@ github.com/nxadm/tail v1.4.8 h1:nPr65rt6Y5JFSKQO7qToXr7pePgD6Gwiw05lkbyAQTE= github.com/nxadm/tail v1.4.8/go.mod h1:+ncqLTQzXmGhMZNUePPaPqPvBxHAIsmXswZKocGu+AU= github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk= -github.com/onsi/ginkgo v1.16.2 h1:HFB2fbVIlhIfCfOW81bZFbiC/RvnpXSdhbF2/DJr134= -github.com/onsi/ginkgo v1.16.2/go.mod h1:CObGmKUOKaSC0RjmoAK7tKyn4Azo5P2IWuoMnvwxz1E= +github.com/onsi/ginkgo v1.16.4 h1:29JGrr5oVBm5ulCWet69zQkzWipVXIol6ygQUe/EzNc= +github.com/onsi/ginkgo v1.16.4/go.mod h1:dX+/inL/fNMqNlz0e9LfyB9TswhZpCVdJM/Z6Vvnwo0= github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY= github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo= github.com/onsi/gomega v1.11.0/go.mod h1:azGKhqFUon9Vuj0YmTfLSmx0FUwqXYSTl5re8lQLTUg= -github.com/onsi/gomega v1.13.0 h1:7lLHu94wT9Ij0o6EWWclhu0aOh32VxhkwEJvzuWPeak= -github.com/onsi/gomega v1.13.0/go.mod h1:lRk9szgn8TxENtWd0Tp4c3wjlRfMTMH27I+3Je41yGY= +github.com/onsi/gomega v1.14.0 h1:ep6kpPVwmr/nTbklSx2nrLNSIO62DoYAhnPNIMhK8gI= +github.com/onsi/gomega v1.14.0/go.mod h1:cIuvLEne0aoVhAgh/O6ac0Op8WWw9H6eYCriF+tEHG0= github.com/pelletier/go-toml v1.9.3 h1:zeC5b1GviRUyKYd6OJPvBU/mcVDVoL1OhT17FCt5dSQ= github.com/pelletier/go-toml v1.9.3/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= From 713a131512f46e908e104ce43e380329a389c04e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 8 Jul 2021 13:30:52 +0000 Subject: [PATCH 25/44] Bump github.com/buildpacks/libcnb from 1.21.0 to 1.22.0 Bumps [github.com/buildpacks/libcnb](https://github.com/buildpacks/libcnb) from 1.21.0 to 1.22.0. - [Release notes](https://github.com/buildpacks/libcnb/releases) - [Commits](https://github.com/buildpacks/libcnb/compare/v1.21.0...v1.22.0) --- updated-dependencies: - dependency-name: github.com/buildpacks/libcnb dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- go.mod | 2 +- go.sum | 9 ++++----- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/go.mod b/go.mod index 230aa34..ebfd0be 100644 --- a/go.mod +++ b/go.mod @@ -4,7 +4,7 @@ go 1.15 require ( github.com/Masterminds/semver/v3 v3.1.1 - github.com/buildpacks/libcnb v1.21.0 + github.com/buildpacks/libcnb v1.22.0 github.com/creack/pty v1.1.13 github.com/heroku/color v0.0.6 github.com/imdario/mergo v0.3.12 diff --git a/go.sum b/go.sum index 002eaf7..29f8bf5 100644 --- a/go.sum +++ b/go.sum @@ -2,8 +2,8 @@ github.com/BurntSushi/toml v0.3.1 h1:WXkYYl6Yr3qBf1K79EBnL4mak0OimBfB0XUf9Vl28OQ github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/Masterminds/semver/v3 v3.1.1 h1:hLg3sBzpNErnxhQtUy/mmLR2I9foDujNK030IGemrRc= github.com/Masterminds/semver/v3 v3.1.1/go.mod h1:VPu/7SZ7ePZ3QOrcuXROw5FAcLl4a0cBrbBpGY/8hQs= -github.com/buildpacks/libcnb v1.21.0 h1:GBK02W22lm1ie8E4hBGStNfShLa/CWbjoBD1kfqAKT4= -github.com/buildpacks/libcnb v1.21.0/go.mod h1:q+nl2Cg76musVOM5CRFeasdbY23FNEz4kvOkZeEUyaM= +github.com/buildpacks/libcnb v1.22.0 h1:jnQf51ASouvsRv/F3cprStM3SrXxlueVP7MK7b8/km0= +github.com/buildpacks/libcnb v1.22.0/go.mod h1:g++R17SOuahPXTGDj1tbIcLr9csmzHrNVoTsdocdaMc= github.com/creack/pty v1.1.13 h1:rTPnd/xocYRjutMfqide2zle1u96upp1gm6eUHKi7us= github.com/creack/pty v1.1.13/go.mod h1:MOBLtS5ELjhRRrroQr9kyvTxUAFNvYEK993ew/Vr4O4= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= @@ -20,7 +20,6 @@ github.com/golang/protobuf v1.4.0-rc.2/go.mod h1:LlEzMj4AhA7rCAGe4KMBDvJI+AwstrU github.com/golang/protobuf v1.4.0-rc.4.0.20200313231945-b860323f09d0/go.mod h1:WU3c8KckQ9AFe+yFwt9sWVRKCVIyN9cPHBJSNnbL67w= github.com/golang/protobuf v1.4.0/go.mod h1:jodUvKwWbYaEsadDk5Fwe5c77LiNKVO9IDvqG2KuDX0= github.com/golang/protobuf v1.4.2/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= -github.com/golang/protobuf v1.4.3/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk= github.com/golang/protobuf v1.5.2 h1:ROPKBNFfQgOUMifHyP+KYbvpjbdoFNs+aK7DXlji0Tw= github.com/golang/protobuf v1.5.2/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= @@ -43,11 +42,12 @@ github.com/nxadm/tail v1.4.8 h1:nPr65rt6Y5JFSKQO7qToXr7pePgD6Gwiw05lkbyAQTE= github.com/nxadm/tail v1.4.8/go.mod h1:+ncqLTQzXmGhMZNUePPaPqPvBxHAIsmXswZKocGu+AU= github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk= +github.com/onsi/ginkgo v1.16.2/go.mod h1:CObGmKUOKaSC0RjmoAK7tKyn4Azo5P2IWuoMnvwxz1E= github.com/onsi/ginkgo v1.16.4 h1:29JGrr5oVBm5ulCWet69zQkzWipVXIol6ygQUe/EzNc= github.com/onsi/ginkgo v1.16.4/go.mod h1:dX+/inL/fNMqNlz0e9LfyB9TswhZpCVdJM/Z6Vvnwo0= github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY= github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo= -github.com/onsi/gomega v1.11.0/go.mod h1:azGKhqFUon9Vuj0YmTfLSmx0FUwqXYSTl5re8lQLTUg= +github.com/onsi/gomega v1.13.0/go.mod h1:lRk9szgn8TxENtWd0Tp4c3wjlRfMTMH27I+3Je41yGY= github.com/onsi/gomega v1.14.0 h1:ep6kpPVwmr/nTbklSx2nrLNSIO62DoYAhnPNIMhK8gI= github.com/onsi/gomega v1.14.0/go.mod h1:cIuvLEne0aoVhAgh/O6ac0Op8WWw9H6eYCriF+tEHG0= github.com/pelletier/go-toml v1.9.3 h1:zeC5b1GviRUyKYd6OJPvBU/mcVDVoL1OhT17FCt5dSQ= @@ -75,7 +75,6 @@ golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200520004742-59133d7f0dd7/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= -golang.org/x/net v0.0.0-20201202161906-c7110b5ffcbb/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/net v0.0.0-20210428140749-89ef3d95e781 h1:DzZ89McO9/gWPsQXS/FVKAlG02ZjaQ6AlZRBimEYOd0= golang.org/x/net v0.0.0-20210428140749-89ef3d95e781/go.mod h1:OJAsFXCWl8Ukc7SiCT/9KSuxbyM7479/AVlXFRxuMCk= golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= From ef7fb75f16defd8daad967eb1eeee4b64ccb10b6 Mon Sep 17 00:00:00 2001 From: paketo-bot Date: Mon, 12 Jul 2021 05:16:25 +0000 Subject: [PATCH 26/44] Bump pipeline from 1.10.0 to 1.10.2 Bumps pipeline from 1.10.0 to 1.10.2. Signed-off-by: GitHub --- .github/pipeline-version | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/pipeline-version b/.github/pipeline-version index 81c871d..5ad2491 100644 --- a/.github/pipeline-version +++ b/.github/pipeline-version @@ -1 +1 @@ -1.10.0 +1.10.2 From 903758225469c72f95eafccc4d812bfd421de4f3 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 27 Jul 2021 10:04:32 +0000 Subject: [PATCH 27/44] Bump github.com/creack/pty from 1.1.13 to 1.1.14 Bumps [github.com/creack/pty](https://github.com/creack/pty) from 1.1.13 to 1.1.14. - [Release notes](https://github.com/creack/pty/releases) - [Commits](https://github.com/creack/pty/compare/v1.1.13...v1.1.14) --- updated-dependencies: - dependency-name: github.com/creack/pty dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- go.mod | 2 +- go.sum | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/go.mod b/go.mod index ebfd0be..ff28468 100644 --- a/go.mod +++ b/go.mod @@ -5,7 +5,7 @@ go 1.15 require ( github.com/Masterminds/semver/v3 v3.1.1 github.com/buildpacks/libcnb v1.22.0 - github.com/creack/pty v1.1.13 + github.com/creack/pty v1.1.14 github.com/heroku/color v0.0.6 github.com/imdario/mergo v0.3.12 github.com/onsi/gomega v1.14.0 diff --git a/go.sum b/go.sum index 29f8bf5..af279c9 100644 --- a/go.sum +++ b/go.sum @@ -4,8 +4,8 @@ github.com/Masterminds/semver/v3 v3.1.1 h1:hLg3sBzpNErnxhQtUy/mmLR2I9foDujNK030I github.com/Masterminds/semver/v3 v3.1.1/go.mod h1:VPu/7SZ7ePZ3QOrcuXROw5FAcLl4a0cBrbBpGY/8hQs= github.com/buildpacks/libcnb v1.22.0 h1:jnQf51ASouvsRv/F3cprStM3SrXxlueVP7MK7b8/km0= github.com/buildpacks/libcnb v1.22.0/go.mod h1:g++R17SOuahPXTGDj1tbIcLr9csmzHrNVoTsdocdaMc= -github.com/creack/pty v1.1.13 h1:rTPnd/xocYRjutMfqide2zle1u96upp1gm6eUHKi7us= -github.com/creack/pty v1.1.13/go.mod h1:MOBLtS5ELjhRRrroQr9kyvTxUAFNvYEK993ew/Vr4O4= +github.com/creack/pty v1.1.14 h1:55VbUWoBxE1iTAh3B6JztD6xyQ06CvW/31oD6rYwrtY= +github.com/creack/pty v1.1.14/go.mod h1:MOBLtS5ELjhRRrroQr9kyvTxUAFNvYEK993ew/Vr4O4= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= From 22a16ff3154c92ae8b9eea0b407f9d8fa6a32e97 Mon Sep 17 00:00:00 2001 From: David O'Sullivan Date: Wed, 28 Jul 2021 15:36:47 +0100 Subject: [PATCH 28/44] Implements RFC0027 by providing support for BP_LOG_LEVEL in bard/logger --- bard/logger.go | 18 +++++++++++++++--- bard/logger_test.go | 15 +++++++++++++++ go.mod | 2 +- 3 files changed, 31 insertions(+), 4 deletions(-) diff --git a/bard/logger.go b/bard/logger.go index 205b40a..15189bc 100644 --- a/bard/logger.go +++ b/bard/logger.go @@ -76,13 +76,25 @@ func NewLoggerWithOptions(writer io.Writer, options ...Option) Logger { func NewLogger(writer io.Writer) Logger { var options []Option - if _, ok := os.LookupEnv("BP_DEBUG"); ok { - options = append(options, WithDebug(writer)) - } + // check for presence and value of log level environment variable + options = LogLevel(options, writer) return NewLoggerWithOptions(writer, options...) } +func LogLevel(options []Option, writer io.Writer) []Option { + + // Check for older log level env variable + _, dbSet := os.LookupEnv("BP_DEBUG") + + // Then check for common buildpack log level env variable - if either are set to DEBUG/true, enable Debug Writer + if level, ok := os.LookupEnv("BP_LOG_LEVEL"); (ok && strings.ToLower(level) == "debug") || dbSet { + + options = append(options, WithDebug(writer)) + } + return options +} + // Body formats using the default formats for its operands and logs a message to the configured body writer. Spaces // are added between operands when neither is a string. func (l Logger) Body(a ...interface{}) { diff --git a/bard/logger_test.go b/bard/logger_test.go index 1057246..edeeb80 100644 --- a/bard/logger_test.go +++ b/bard/logger_test.go @@ -66,6 +66,21 @@ func testLogger(t *testing.T, context spec.G, it spec.S) { }) }) + context("with BP_LOG_LEVEL set to DEBUG", func() { + it.Before(func() { + Expect(os.Setenv("BP_LOG_LEVEL", "DEBUG")).To(Succeed()) + l = bard.NewLogger(b) + }) + + it.After(func() { + Expect(os.Unsetenv("BP_LOG_LEVEL")).To(Succeed()) + }) + + it("configures debug", func() { + Expect(l.IsDebugEnabled()).To(BeTrue()) + }) + }) + context("with debug disabled", func() { it.Before(func() { l = bard.NewLoggerWithOptions(b) diff --git a/go.mod b/go.mod index ebfd0be..081ceb3 100644 --- a/go.mod +++ b/go.mod @@ -14,4 +14,4 @@ require ( github.com/spf13/pflag v1.0.5 github.com/stretchr/testify v1.7.0 github.com/xi2/xz v0.0.0-20171230120015-48954b6210f8 -) +) \ No newline at end of file From 60a7e52ded261ca2576820d97d5a6e06b95e3a20 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 6 Aug 2021 10:04:08 +0000 Subject: [PATCH 29/44] Bump github.com/onsi/gomega from 1.14.0 to 1.15.0 Bumps [github.com/onsi/gomega](https://github.com/onsi/gomega) from 1.14.0 to 1.15.0. - [Release notes](https://github.com/onsi/gomega/releases) - [Changelog](https://github.com/onsi/gomega/blob/master/CHANGELOG.md) - [Commits](https://github.com/onsi/gomega/compare/v1.14.0...v1.15.0) --- updated-dependencies: - dependency-name: github.com/onsi/gomega dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- go.mod | 4 ++-- go.sum | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/go.mod b/go.mod index f3aa123..b7bf2db 100644 --- a/go.mod +++ b/go.mod @@ -8,10 +8,10 @@ require ( github.com/creack/pty v1.1.14 github.com/heroku/color v0.0.6 github.com/imdario/mergo v0.3.12 - github.com/onsi/gomega v1.14.0 + github.com/onsi/gomega v1.15.0 github.com/pelletier/go-toml v1.9.3 github.com/sclevine/spec v1.4.0 github.com/spf13/pflag v1.0.5 github.com/stretchr/testify v1.7.0 github.com/xi2/xz v0.0.0-20171230120015-48954b6210f8 -) \ No newline at end of file +) diff --git a/go.sum b/go.sum index af279c9..f6ccf18 100644 --- a/go.sum +++ b/go.sum @@ -48,8 +48,8 @@ github.com/onsi/ginkgo v1.16.4/go.mod h1:dX+/inL/fNMqNlz0e9LfyB9TswhZpCVdJM/Z6Vv github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY= github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo= github.com/onsi/gomega v1.13.0/go.mod h1:lRk9szgn8TxENtWd0Tp4c3wjlRfMTMH27I+3Je41yGY= -github.com/onsi/gomega v1.14.0 h1:ep6kpPVwmr/nTbklSx2nrLNSIO62DoYAhnPNIMhK8gI= -github.com/onsi/gomega v1.14.0/go.mod h1:cIuvLEne0aoVhAgh/O6ac0Op8WWw9H6eYCriF+tEHG0= +github.com/onsi/gomega v1.15.0 h1:WjP/FQ/sk43MRmnEcT+MlDw2TFvkrXlprrPST/IudjU= +github.com/onsi/gomega v1.15.0/go.mod h1:cIuvLEne0aoVhAgh/O6ac0Op8WWw9H6eYCriF+tEHG0= github.com/pelletier/go-toml v1.9.3 h1:zeC5b1GviRUyKYd6OJPvBU/mcVDVoL1OhT17FCt5dSQ= github.com/pelletier/go-toml v1.9.3/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= From bfdb1370882bbb762dbfdcbddfadcd6d44c0714e Mon Sep 17 00:00:00 2001 From: Daniel Mikusa Date: Sun, 15 Aug 2021 17:06:42 -0400 Subject: [PATCH 30/44] Ensure symlinks to directories are skipped in the same manner as directories. Continues to follow symlinks to files & calculate sha256 hashes for the target. Signed-off-by: Daniel Mikusa --- sherpa/file_listing.go | 27 ++++++++++++++++++++++++++- sherpa/file_listing_test.go | 23 +++++++++++++++++++++-- 2 files changed, 47 insertions(+), 3 deletions(-) diff --git a/sherpa/file_listing.go b/sherpa/file_listing.go index e1fec08..ba3b21c 100644 --- a/sherpa/file_listing.go +++ b/sherpa/file_listing.go @@ -21,6 +21,7 @@ import ( "encoding/hex" "fmt" "io" + "io/fs" "os" "path/filepath" "sort" @@ -74,7 +75,12 @@ func NewFileListing(roots ...string) ([]FileEntry, error) { Mode: info.Mode().String(), } - if info.IsDir() { + symlinkToDir, err := isSymlinkToDir(path, info) + if err != nil { + return err + } + + if info.IsDir() || symlinkToDir { results <- result{value: e} return nil } @@ -140,3 +146,22 @@ func process(entry FileEntry) (FileEntry, error) { entry.SHA256 = hex.EncodeToString(s.Sum(nil)) return entry, nil } + +func isSymlinkToDir(root string, f fs.FileInfo) (bool, error) { + if f.Mode().Type() == fs.ModeSymlink { + // rawPath := filepath.Join(root, f.Name()) + path, err := os.Readlink(root) + if err != nil { + return false, fmt.Errorf("unable to read symlink %s\n%w", root, err) + } + + stat, err := os.Stat(path) + if err != nil { + return false, fmt.Errorf("unable to stat file %s\n%w", path, err) + } + + return stat.IsDir(), nil + } + + return false, nil +} diff --git a/sherpa/file_listing_test.go b/sherpa/file_listing_test.go index 50f4d8a..b8c5d3b 100644 --- a/sherpa/file_listing_test.go +++ b/sherpa/file_listing_test.go @@ -47,13 +47,32 @@ func testFileListing(t *testing.T, context spec.G, it spec.S) { }) it("create listing", func() { - Expect(ioutil.WriteFile(filepath.Join(path, "alpha.txt"), []byte{}, 0644)).To(Succeed()) + Expect(ioutil.WriteFile(filepath.Join(path, "alpha.txt"), []byte{1}, 0644)).To(Succeed()) Expect(os.MkdirAll(filepath.Join(path, "test-directory"), 0755)).To(Succeed()) - Expect(ioutil.WriteFile(filepath.Join(path, "test-directory", "bravo.txt"), []byte{}, 0644)).To(Succeed()) + Expect(ioutil.WriteFile(filepath.Join(path, "test-directory", "bravo.txt"), []byte{2}, 0644)).To(Succeed()) e, err := sherpa.NewFileListing(path) Expect(err).NotTo(HaveOccurred()) Expect(e).To(HaveLen(3)) }) + + it("create listing as hash with non-regular file", func() { + Expect(ioutil.WriteFile(filepath.Join(path, "alpha.txt"), []byte{1}, 0644)).To(Succeed()) + Expect(os.MkdirAll(filepath.Join(path, "test-directory"), 0755)).To(Succeed()) + Expect(ioutil.WriteFile(filepath.Join(path, "test-directory", "bravo.txt"), []byte{2}, 0644)).To(Succeed()) + Expect(os.Symlink(filepath.Join(path, "test-directory"), filepath.Join(path, "symlink-test-dir"))) + Expect(os.Symlink(filepath.Join(path, "test-directory", "bravo.txt"), filepath.Join(path, "symlink-bravo.txt"))) + + e, err := sherpa.NewFileListing(path) + Expect(err).NotTo(HaveOccurred()) + + Expect(e).To(HaveLen(5)) + Expect(e[0].Path).To(HaveSuffix("alpha.txt")) + Expect(e[1].Path).To(HaveSuffix("symlink-bravo.txt")) + Expect(e[2].Path).To(HaveSuffix("symlink-test-dir")) + Expect(e[3].Path).To(HaveSuffix("test-directory")) + Expect(e[4].Path).To(HaveSuffix("bravo.txt")) + Expect(e[1].SHA256).To(Equal(e[4].SHA256)) // symlink to file should have hash of target file + }) } From 3e8dd64e84faca85803d1f4190c119e413d3e254 Mon Sep 17 00:00:00 2001 From: Daniel Mikusa Date: Mon, 16 Aug 2021 08:41:13 -0400 Subject: [PATCH 31/44] Adds convenience method to generate a file listing & return the hash of the listing Signed-off-by: Daniel Mikusa --- sherpa/file_listing.go | 15 +++++++++++++++ sherpa/file_listing_test.go | 21 +++++++++++++++++++++ 2 files changed, 36 insertions(+) diff --git a/sherpa/file_listing.go b/sherpa/file_listing.go index ba3b21c..d0ee771 100644 --- a/sherpa/file_listing.go +++ b/sherpa/file_listing.go @@ -46,6 +46,21 @@ type result struct { value FileEntry } +// NewFileListingHash generates a sha256 hash from the listing of all entries under the roots +func NewFileListingHash(roots ...string) (string, error) { + files, err := NewFileListing(roots...) + if err != nil { + return "", fmt.Errorf("unable to create file listing\n%w", err) + } + + hash := sha256.New() + for _, file := range files { + hash.Write([]byte(file.Path + file.Mode + file.SHA256 + "\n")) + } + + return hex.EncodeToString(hash.Sum(nil)), nil +} + // NewFileListing generates a listing of all entries under the roots. func NewFileListing(roots ...string) ([]FileEntry, error) { entries := make(chan FileEntry) diff --git a/sherpa/file_listing_test.go b/sherpa/file_listing_test.go index b8c5d3b..f390e9c 100644 --- a/sherpa/file_listing_test.go +++ b/sherpa/file_listing_test.go @@ -17,6 +17,8 @@ package sherpa_test import ( + "crypto/sha256" + "encoding/hex" "io/ioutil" "os" "path/filepath" @@ -75,4 +77,23 @@ func testFileListing(t *testing.T, context spec.G, it spec.S) { Expect(e[4].Path).To(HaveSuffix("bravo.txt")) Expect(e[1].SHA256).To(Equal(e[4].SHA256)) // symlink to file should have hash of target file }) + + it("create listing and get SHA256", func() { + Expect(ioutil.WriteFile(filepath.Join(path, "alpha.txt"), []byte{}, 0644)).To(Succeed()) + Expect(os.MkdirAll(filepath.Join(path, "test-directory"), 0755)).To(Succeed()) + Expect(ioutil.WriteFile(filepath.Join(path, "test-directory", "bravo.txt"), []byte{}, 0644)).To(Succeed()) + + e, err := sherpa.NewFileListing(path) + Expect(err).NotTo(HaveOccurred()) + + hash := sha256.New() + for _, file := range e { + hash.Write([]byte(file.Path + file.Mode + file.SHA256 + "\n")) + } + + s, err := sherpa.NewFileListingHash(path) + Expect(err).NotTo(HaveOccurred()) + + Expect(s).To(Equal(hex.EncodeToString(hash.Sum(nil)))) + }) } From 0e35505151c03919894ce9da43ab24628a022173 Mon Sep 17 00:00:00 2001 From: Daniel Mikusa Date: Tue, 17 Aug 2021 16:01:49 -0400 Subject: [PATCH 32/44] Implement file:// downloads for artifacts This can be used with dependency mapping bindings to volume mount in external pre-cached artifacts. Signed-off-by: Daniel Mikusa --- dependency_cache.go | 38 ++++++++++++++++++++++++++++++++++++++ dependency_cache_test.go | 22 +++++++++++++++++++++- 2 files changed, 59 insertions(+), 1 deletion(-) diff --git a/dependency_cache.go b/dependency_cache.go index 158d325..200f22f 100644 --- a/dependency_cache.go +++ b/dependency_cache.go @@ -23,6 +23,7 @@ import ( "io" "io/ioutil" "net/http" + "net/url" "os" "path/filepath" "reflect" @@ -187,6 +188,43 @@ func (d *DependencyCache) Artifact(dependency BuildpackDependency, mods ...Reque } func (d DependencyCache) download(uri string, destination string, mods ...RequestModifierFunc) error { + url, err := url.Parse(uri) + if err != nil { + return fmt.Errorf("unable to parse URI %s\n%w", uri, err) + } + + if url.Scheme == "file" { + return d.downloadFile(url.Path, destination, mods...) + } + + return d.downloadHttp(uri, destination, mods...) +} + +func (d DependencyCache) downloadFile(source string, destination string, mods ...RequestModifierFunc) error { + if err := os.MkdirAll(filepath.Dir(destination), 0755); err != nil { + return fmt.Errorf("unable to make directory %s\n%w", filepath.Dir(destination), err) + } + + out, err := os.OpenFile(destination, os.O_CREATE|os.O_TRUNC|os.O_WRONLY, 0644) + if err != nil { + return fmt.Errorf("unable to open destination file %s\n%w", destination, err) + } + defer out.Close() + + input, err := os.Open(source) + if err != nil { + return fmt.Errorf("unable to open source file %s\n%w", source, err) + } + defer out.Close() + + if _, err := io.Copy(out, input); err != nil { + return fmt.Errorf("unable to copy from %s to %s\n%w", source, destination, err) + } + + return nil +} + +func (d DependencyCache) downloadHttp(uri string, destination string, mods ...RequestModifierFunc) error { req, err := http.NewRequest("GET", uri, nil) if err != nil { return fmt.Errorf("unable to create new GET request for %s\n%w", uri, err) diff --git a/dependency_cache_test.go b/dependency_cache_test.go index 65d91de..1448a9c 100644 --- a/dependency_cache_test.go +++ b/dependency_cache_test.go @@ -223,7 +223,7 @@ func testDependencyCache(t *testing.T, context spec.G, it spec.S) { Expect(ioutil.ReadAll(a)).To(Equal([]byte("test-fixture"))) }) - context("uri is overridden", func() { + context("uri is overridden HTTP", func() { it.Before(func() { dependencyCache.Mappings = map[string]string{ dependency.SHA256: fmt.Sprintf("%s/override-path", server.URL()), @@ -243,6 +243,26 @@ func testDependencyCache(t *testing.T, context spec.G, it spec.S) { }) }) + context("uri is overridden FILE", func() { + it.Before(func() { + sourcePath, err := ioutil.TempDir("", "dependency-source-path") + Expect(err).NotTo(HaveOccurred()) + sourceFile := filepath.Join(sourcePath, "source-file") + Expect(ioutil.WriteFile(sourceFile, []byte("test-fixture"), 0644)).ToNot(HaveOccurred()) + + dependencyCache.Mappings = map[string]string{ + dependency.SHA256: fmt.Sprintf("file://%s", sourceFile), + } + }) + + it("downloads from override filesystem", func() { + a, err := dependencyCache.Artifact(dependency) + Expect(err).NotTo(HaveOccurred()) + + Expect(ioutil.ReadAll(a)).To(Equal([]byte("test-fixture"))) + }) + }) + it("fails with invalid SHA256", func() { server.AppendHandlers(ghttp.RespondWith(http.StatusOK, "invalid-fixture")) From 6dcc6fb50d6634b691bfe9434ea7f320f5ea90f0 Mon Sep 17 00:00:00 2001 From: Daniel Mikusa Date: Fri, 20 Aug 2021 13:10:27 -0400 Subject: [PATCH 33/44] Fixes a bug where file listing would fail if there is a relative symlink. This will now resolve relative symlinks based on the parent directory of the symlink. Ex: /foo/bar/my-link -> my-file Then: it resolves my-link to /foo/bar/my-file Signed-off-by: Daniel Mikusa --- sherpa/file_listing.go | 11 +++++++---- sherpa/file_listing_test.go | 12 +++++++----- 2 files changed, 14 insertions(+), 9 deletions(-) diff --git a/sherpa/file_listing.go b/sherpa/file_listing.go index d0ee771..69b6890 100644 --- a/sherpa/file_listing.go +++ b/sherpa/file_listing.go @@ -162,12 +162,15 @@ func process(entry FileEntry) (FileEntry, error) { return entry, nil } -func isSymlinkToDir(root string, f fs.FileInfo) (bool, error) { +func isSymlinkToDir(symlink string, f fs.FileInfo) (bool, error) { if f.Mode().Type() == fs.ModeSymlink { - // rawPath := filepath.Join(root, f.Name()) - path, err := os.Readlink(root) + path, err := os.Readlink(symlink) if err != nil { - return false, fmt.Errorf("unable to read symlink %s\n%w", root, err) + return false, fmt.Errorf("unable to read symlink %s\n%w", symlink, err) + } + + if !filepath.IsAbs(path) { + path = filepath.Join(filepath.Dir(symlink), path) } stat, err := os.Stat(path) diff --git a/sherpa/file_listing_test.go b/sherpa/file_listing_test.go index f390e9c..0cd6660 100644 --- a/sherpa/file_listing_test.go +++ b/sherpa/file_listing_test.go @@ -65,17 +65,19 @@ func testFileListing(t *testing.T, context spec.G, it spec.S) { Expect(ioutil.WriteFile(filepath.Join(path, "test-directory", "bravo.txt"), []byte{2}, 0644)).To(Succeed()) Expect(os.Symlink(filepath.Join(path, "test-directory"), filepath.Join(path, "symlink-test-dir"))) Expect(os.Symlink(filepath.Join(path, "test-directory", "bravo.txt"), filepath.Join(path, "symlink-bravo.txt"))) + Expect(os.Symlink("alpha.txt", filepath.Join(path, "symlink-relative.txt"))) e, err := sherpa.NewFileListing(path) Expect(err).NotTo(HaveOccurred()) - Expect(e).To(HaveLen(5)) + Expect(e).To(HaveLen(6)) Expect(e[0].Path).To(HaveSuffix("alpha.txt")) Expect(e[1].Path).To(HaveSuffix("symlink-bravo.txt")) - Expect(e[2].Path).To(HaveSuffix("symlink-test-dir")) - Expect(e[3].Path).To(HaveSuffix("test-directory")) - Expect(e[4].Path).To(HaveSuffix("bravo.txt")) - Expect(e[1].SHA256).To(Equal(e[4].SHA256)) // symlink to file should have hash of target file + Expect(e[2].Path).To(HaveSuffix("symlink-relative.txt")) + Expect(e[3].Path).To(HaveSuffix("symlink-test-dir")) + Expect(e[4].Path).To(HaveSuffix("test-directory")) + Expect(e[5].Path).To(HaveSuffix("bravo.txt")) + Expect(e[1].SHA256).To(Equal(e[5].SHA256)) // symlink to file should have hash of target file }) it("create listing and get SHA256", func() { From 6c1483eec932a2c15115c294a49d3e6a0b70638d Mon Sep 17 00:00:00 2001 From: Daniel Mikusa Date: Fri, 20 Aug 2021 14:20:18 -0400 Subject: [PATCH 34/44] Switch from using io/fs to just using os which preserves Go 1.15 compatibility Signed-off-by: Daniel Mikusa --- sherpa/file_listing.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/sherpa/file_listing.go b/sherpa/file_listing.go index 69b6890..4684505 100644 --- a/sherpa/file_listing.go +++ b/sherpa/file_listing.go @@ -21,7 +21,6 @@ import ( "encoding/hex" "fmt" "io" - "io/fs" "os" "path/filepath" "sort" @@ -162,8 +161,8 @@ func process(entry FileEntry) (FileEntry, error) { return entry, nil } -func isSymlinkToDir(symlink string, f fs.FileInfo) (bool, error) { - if f.Mode().Type() == fs.ModeSymlink { +func isSymlinkToDir(symlink string, f os.FileInfo) (bool, error) { + if f.Mode().Type() == os.ModeSymlink { path, err := os.Readlink(symlink) if err != nil { return false, fmt.Errorf("unable to read symlink %s\n%w", symlink, err) From 2d30fd12012c5b2d5a589c50fc3eaa1a9ded854d Mon Sep 17 00:00:00 2001 From: paketo-bot Date: Fri, 20 Aug 2021 19:24:37 +0000 Subject: [PATCH 35/44] Bump pipeline from 1.10.2 to 1.10.3 Bumps pipeline from 1.10.2 to 1.10.3. Signed-off-by: GitHub --- .github/pipeline-version | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/pipeline-version b/.github/pipeline-version index 5ad2491..587c5f0 100644 --- a/.github/pipeline-version +++ b/.github/pipeline-version @@ -1 +1 @@ -1.10.2 +1.10.3 From b488c1c86ca77c33c251f0de40b2ffe9d09312de Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 23 Aug 2021 10:04:31 +0000 Subject: [PATCH 36/44] Bump github.com/onsi/gomega from 1.15.0 to 1.16.0 Bumps [github.com/onsi/gomega](https://github.com/onsi/gomega) from 1.15.0 to 1.16.0. - [Release notes](https://github.com/onsi/gomega/releases) - [Changelog](https://github.com/onsi/gomega/blob/master/CHANGELOG.md) - [Commits](https://github.com/onsi/gomega/compare/v1.15.0...v1.16.0) --- updated-dependencies: - dependency-name: github.com/onsi/gomega dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- go.mod | 2 +- go.sum | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/go.mod b/go.mod index b7bf2db..d7c90ad 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/creack/pty v1.1.14 github.com/heroku/color v0.0.6 github.com/imdario/mergo v0.3.12 - github.com/onsi/gomega v1.15.0 + github.com/onsi/gomega v1.16.0 github.com/pelletier/go-toml v1.9.3 github.com/sclevine/spec v1.4.0 github.com/spf13/pflag v1.0.5 diff --git a/go.sum b/go.sum index f6ccf18..58c6ea7 100644 --- a/go.sum +++ b/go.sum @@ -48,8 +48,8 @@ github.com/onsi/ginkgo v1.16.4/go.mod h1:dX+/inL/fNMqNlz0e9LfyB9TswhZpCVdJM/Z6Vv github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY= github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo= github.com/onsi/gomega v1.13.0/go.mod h1:lRk9szgn8TxENtWd0Tp4c3wjlRfMTMH27I+3Je41yGY= -github.com/onsi/gomega v1.15.0 h1:WjP/FQ/sk43MRmnEcT+MlDw2TFvkrXlprrPST/IudjU= -github.com/onsi/gomega v1.15.0/go.mod h1:cIuvLEne0aoVhAgh/O6ac0Op8WWw9H6eYCriF+tEHG0= +github.com/onsi/gomega v1.16.0 h1:6gjqkI8iiRHMvdccRJM8rVKjCWk6ZIm6FTm3ddIe4/c= +github.com/onsi/gomega v1.16.0/go.mod h1:HnhC7FXeEQY45zxNK3PPoIUhzk/80Xly9PcubAlGdZY= github.com/pelletier/go-toml v1.9.3 h1:zeC5b1GviRUyKYd6OJPvBU/mcVDVoL1OhT17FCt5dSQ= github.com/pelletier/go-toml v1.9.3/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= From 338f9cec22ed7c8b03d902eb5f8498895b89054f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 24 Aug 2021 14:46:53 +0000 Subject: [PATCH 37/44] Bump github.com/creack/pty from 1.1.14 to 1.1.15 Bumps [github.com/creack/pty](https://github.com/creack/pty) from 1.1.14 to 1.1.15. - [Release notes](https://github.com/creack/pty/releases) - [Commits](https://github.com/creack/pty/compare/v1.1.14...v1.1.15) --- updated-dependencies: - dependency-name: github.com/creack/pty dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- go.mod | 2 +- go.sum | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/go.mod b/go.mod index d7c90ad..4efd850 100644 --- a/go.mod +++ b/go.mod @@ -5,7 +5,7 @@ go 1.15 require ( github.com/Masterminds/semver/v3 v3.1.1 github.com/buildpacks/libcnb v1.22.0 - github.com/creack/pty v1.1.14 + github.com/creack/pty v1.1.15 github.com/heroku/color v0.0.6 github.com/imdario/mergo v0.3.12 github.com/onsi/gomega v1.16.0 diff --git a/go.sum b/go.sum index 58c6ea7..1900b58 100644 --- a/go.sum +++ b/go.sum @@ -4,8 +4,8 @@ github.com/Masterminds/semver/v3 v3.1.1 h1:hLg3sBzpNErnxhQtUy/mmLR2I9foDujNK030I github.com/Masterminds/semver/v3 v3.1.1/go.mod h1:VPu/7SZ7ePZ3QOrcuXROw5FAcLl4a0cBrbBpGY/8hQs= github.com/buildpacks/libcnb v1.22.0 h1:jnQf51ASouvsRv/F3cprStM3SrXxlueVP7MK7b8/km0= github.com/buildpacks/libcnb v1.22.0/go.mod h1:g++R17SOuahPXTGDj1tbIcLr9csmzHrNVoTsdocdaMc= -github.com/creack/pty v1.1.14 h1:55VbUWoBxE1iTAh3B6JztD6xyQ06CvW/31oD6rYwrtY= -github.com/creack/pty v1.1.14/go.mod h1:MOBLtS5ELjhRRrroQr9kyvTxUAFNvYEK993ew/Vr4O4= +github.com/creack/pty v1.1.15 h1:cKRCLMj3Ddm54bKSpemfQ8AtYFBhAI2MPmdys22fBdc= +github.com/creack/pty v1.1.15/go.mod h1:MOBLtS5ELjhRRrroQr9kyvTxUAFNvYEK993ew/Vr4O4= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= From 2f012eca695ed29c7dc293c762f1713cea937021 Mon Sep 17 00:00:00 2001 From: paketo-bot Date: Mon, 30 Aug 2021 05:16:51 +0000 Subject: [PATCH 38/44] Bump pipeline from 1.10.3 to 1.10.4 Bumps pipeline from 1.10.3 to 1.10.4. Signed-off-by: GitHub --- .github/pipeline-version | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/pipeline-version b/.github/pipeline-version index 587c5f0..18b3114 100644 --- a/.github/pipeline-version +++ b/.github/pipeline-version @@ -1 +1 @@ -1.10.3 +1.10.4 From e9ffc881baaf8b096781617bfd1d76f8e8be5a12 Mon Sep 17 00:00:00 2001 From: David O'Sullivan Date: Tue, 31 Aug 2021 22:14:29 +0100 Subject: [PATCH 39/44] Add Logging of Bindings Information for better UX --- bindings/resolve.go | 34 +++++++++++++++++++++++++++++ bindings/resolve_test.go | 46 ++++++++++++++++++++++++++++++++++++++-- 2 files changed, 78 insertions(+), 2 deletions(-) diff --git a/bindings/resolve.go b/bindings/resolve.go index 61b1a5a..c1af42b 100644 --- a/bindings/resolve.go +++ b/bindings/resolve.go @@ -18,8 +18,13 @@ package bindings import ( "fmt" + "os" + "sort" "strings" + "github.com/heroku/color" + "github.com/paketo-buildpacks/libpak/bard" + "github.com/buildpacks/libcnb" ) @@ -45,17 +50,46 @@ func OfProvider(p string) Predicate { // Resolve returns all bindings from binds that match every Predicate in predicates. func Resolve(binds libcnb.Bindings, predicates ...Predicate) libcnb.Bindings { var result libcnb.Bindings + logger := bard.NewLogger(os.Stdout) + // deep copy for _, bind := range binds { result = append(result, bind) } + // filter on predicates for _, p := range predicates { result = filter(result, p) } + + LogBindings(result, logger) return result } +func LogBindings(bindings libcnb.Bindings, logger bard.Logger) { + f := color.New(color.Bold) + + if len(bindings) > 0 { + logger.Header(f.Sprint("Bindings Identified:")) + } else { + logger.Header(f.Sprint("No Bindings Found")) + } + + var s []string + for _, binding := range bindings { + + for k := range binding.Secret { + s = append(s, k) + } + sort.Strings(s) + + logger.Bodyf("Name: %s", binding.Name) + logger.Bodyf("Keys: %s", s) + s = nil + } + +} + // ResolveOne returns a single binding from bindings that match every Predicate if present. If exactly one match is found // ResolveOne returns the binding and true. If zero matches are found, ResolveOne returns an empty binding and false. // An error is returned if multiple matches are found. diff --git a/bindings/resolve_test.go b/bindings/resolve_test.go index c200235..989da52 100644 --- a/bindings/resolve_test.go +++ b/bindings/resolve_test.go @@ -17,8 +17,11 @@ package bindings_test import ( + "bytes" "testing" + "github.com/paketo-buildpacks/libpak/bard" + "github.com/buildpacks/libcnb" . "github.com/onsi/gomega" "github.com/sclevine/spec" @@ -29,8 +32,9 @@ import ( func testResolve(t *testing.T, context spec.G, it spec.S) { var ( Expect = NewWithT(t).Expect - - binds libcnb.Bindings + b *bytes.Buffer + logger bard.Logger + binds libcnb.Bindings ) it.Before(func() { @@ -163,4 +167,42 @@ func testResolve(t *testing.T, context spec.G, it spec.S) { }) }) }) + + context("bindings are logged", func() { + + it.Before(func() { + b = bytes.NewBuffer(nil) + logger = bard.NewLogger(b) + binds = []libcnb.Binding{ + { + Name: "name1", + Type: "some-type", + Provider: "some-provider", + Secret: map[string]string{"my-key1": "my-sec1"}, + }, + { + Name: "name2", + Type: "some-type", + Provider: "some-provider", + Secret: map[string]string{"my-key2": "my-sec2"}, + }, + } + }) + + it("checks that binding info is logged", func() { + + bindings.LogBindings(binds, logger) + Expect(b.String()).To(ContainSubstring("name1")) + Expect(b.String()).To(ContainSubstring("my-key1")) + + Expect(b.String()).To(ContainSubstring("name2")) + Expect(b.String()).To(ContainSubstring("my-key2")) + }) + + it("checks that nothing is logged is no bindings found", func() { + binds = []libcnb.Binding{} + bindings.LogBindings(binds, logger) + Expect(b.String()).To(ContainSubstring("No Bindings Found")) + }) + }) } From 8f103121df72bc4989d6ddc6dd2efd5d5d752154 Mon Sep 17 00:00:00 2001 From: Daniel Mikusa Date: Fri, 3 Sep 2021 09:31:47 -0400 Subject: [PATCH 40/44] Support wildcard stacks in DependencyResolver DependencyResolver.Resolve will filter based on stack name. This was an exact match only. This patch enabled DependencyResolver to match if a buildpack author has either set the wildcard stack (i.e. `*`) for a dependency or if a buildpack author has set no stack information (also treated as wildcard). Signed-off-by: Daniel Mikusa --- buildpack.go | 6 ++++- buildpack_test.go | 62 +++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 67 insertions(+), 1 deletion(-) diff --git a/buildpack.go b/buildpack.go index c0c0055..e6584e6 100644 --- a/buildpack.go +++ b/buildpack.go @@ -424,8 +424,12 @@ func (d *DependencyResolver) Resolve(id string, version string) (BuildpackDepend } func (DependencyResolver) contains(candidates []string, value string) bool { + if len(candidates) == 0 { + return true + } + for _, c := range candidates { - if c == value { + if c == value || c == "*" { return true } } diff --git a/buildpack_test.go b/buildpack_test.go index 5bc9844..fc69f6b 100644 --- a/buildpack_test.go +++ b/buildpack_test.go @@ -261,6 +261,68 @@ func testBuildpack(t *testing.T, context spec.G, it spec.S) { })) }) + it("filters by stack and supports the wildcard stack", func() { + resolver.Dependencies = []libpak.BuildpackDependency{ + { + ID: "test-id", + Name: "test-name", + Version: "1.0", + URI: "test-uri", + SHA256: "test-sha256", + Stacks: []string{"test-stack-1", "test-stack-2"}, + }, + { + ID: "test-id", + Name: "test-name", + Version: "1.0", + URI: "test-uri", + SHA256: "test-sha256", + Stacks: []string{"*"}, + }, + } + resolver.StackID = "test-stack-3" + + Expect(resolver.Resolve("test-id", "1.0")).To(Equal(libpak.BuildpackDependency{ + ID: "test-id", + Name: "test-name", + Version: "1.0", + URI: "test-uri", + SHA256: "test-sha256", + Stacks: []string{"*"}, + })) + }) + + it("filters by stack and treats no stacks as the wildcard stack", func() { + resolver.Dependencies = []libpak.BuildpackDependency{ + { + ID: "test-id", + Name: "test-name", + Version: "1.0", + URI: "test-uri", + SHA256: "test-sha256", + Stacks: []string{"test-stack-1", "test-stack-2"}, + }, + { + ID: "test-id", + Name: "test-name", + Version: "1.0", + URI: "test-uri", + SHA256: "test-sha256", + Stacks: []string{}, + }, + } + resolver.StackID = "test-stack-3" + + Expect(resolver.Resolve("test-id", "1.0")).To(Equal(libpak.BuildpackDependency{ + ID: "test-id", + Name: "test-name", + Version: "1.0", + URI: "test-uri", + SHA256: "test-sha256", + Stacks: []string{}, + })) + }) + it("returns the best dependency", func() { resolver.Dependencies = []libpak.BuildpackDependency{ { From 9b641070eb2a880abd4cbaa6812caecf1c07d8a6 Mon Sep 17 00:00:00 2001 From: Daniel Mikusa Date: Fri, 3 Sep 2021 10:07:10 -0400 Subject: [PATCH 41/44] Skip `.git` folders in file listings The file listing mechanism will traverse all directories given to it & return a listing of all files. The main purpose of this mechanism is to detect changes under a directory structure. This change will skip `.git` folders as the file listing is traversing subdirectories. This is because `.git` folders are well-know, can change independent of the application (like if you change git config) but shouldn't trigger rebuilds of the application. In additiona, the `.git` directory can for larger projects contain a large number of files, so skipping it can help with performance on large projects. This change will skip all folders with the name `.git`, not just the top-level `.git` folder. This resolves #55. Signed-off-by: Daniel Mikusa --- sherpa/file_listing.go | 4 ++++ sherpa/file_listing_test.go | 16 ++++++++++++++++ 2 files changed, 20 insertions(+) diff --git a/sherpa/file_listing.go b/sherpa/file_listing.go index 4684505..ba74cad 100644 --- a/sherpa/file_listing.go +++ b/sherpa/file_listing.go @@ -84,6 +84,10 @@ func NewFileListing(roots ...string) ([]FileEntry, error) { return nil } + if info.IsDir() && info.Name() == ".git" { + return filepath.SkipDir + } + e := FileEntry{ Path: path, Mode: info.Mode().String(), diff --git a/sherpa/file_listing_test.go b/sherpa/file_listing_test.go index 0cd6660..b62163d 100644 --- a/sherpa/file_listing_test.go +++ b/sherpa/file_listing_test.go @@ -59,6 +59,22 @@ func testFileListing(t *testing.T, context spec.G, it spec.S) { Expect(e).To(HaveLen(3)) }) + it("create listing skipping .git folder", func() { + Expect(os.MkdirAll(filepath.Join(path, ".git"), 0755)).To(Succeed()) + Expect(ioutil.WriteFile(filepath.Join(path, ".git", "HEAD"), []byte{1}, 0644)).To(Succeed()) + Expect(ioutil.WriteFile(filepath.Join(path, ".git", "config"), []byte{1}, 0644)).To(Succeed()) + Expect(ioutil.WriteFile(filepath.Join(path, "alpha.txt"), []byte{1}, 0644)).To(Succeed()) + Expect(os.MkdirAll(filepath.Join(path, "test-directory"), 0755)).To(Succeed()) + Expect(ioutil.WriteFile(filepath.Join(path, "test-directory", "bravo.txt"), []byte{2}, 0644)).To(Succeed()) + Expect(os.MkdirAll(filepath.Join(path, "test-directory", ".git"), 0755)).To(Succeed()) + Expect(ioutil.WriteFile(filepath.Join(path, "test-directory", ".git", "config"), []byte{1}, 0644)).To(Succeed()) + + e, err := sherpa.NewFileListing(path) + Expect(err).NotTo(HaveOccurred()) + + Expect(e).To(HaveLen(3)) + }) + it("create listing as hash with non-regular file", func() { Expect(ioutil.WriteFile(filepath.Join(path, "alpha.txt"), []byte{1}, 0644)).To(Succeed()) Expect(os.MkdirAll(filepath.Join(path, "test-directory"), 0755)).To(Succeed()) From 196c0206b8a34cf78e13dfb2b999f53968baf749 Mon Sep 17 00:00:00 2001 From: paketo-bot Date: Fri, 3 Sep 2021 14:15:57 +0000 Subject: [PATCH 42/44] Bump pipeline from 1.10.4 to 1.10.5 Bumps pipeline from 1.10.4 to 1.10.5. Signed-off-by: GitHub --- .github/pipeline-version | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/pipeline-version b/.github/pipeline-version index 18b3114..db77e0e 100644 --- a/.github/pipeline-version +++ b/.github/pipeline-version @@ -1 +1 @@ -1.10.4 +1.10.5 From 8384ce166904429fc0ae9e28cf304f6932912a00 Mon Sep 17 00:00:00 2001 From: David O'Sullivan <31728678+pivotal-david-osullivan@users.noreply.github.com> Date: Mon, 6 Sep 2021 16:51:55 +0100 Subject: [PATCH 43/44] Revert "Add Logging of Bindings Information for better UX" --- bindings/resolve.go | 34 ----------------------------- bindings/resolve_test.go | 46 ++-------------------------------------- 2 files changed, 2 insertions(+), 78 deletions(-) diff --git a/bindings/resolve.go b/bindings/resolve.go index c1af42b..61b1a5a 100644 --- a/bindings/resolve.go +++ b/bindings/resolve.go @@ -18,13 +18,8 @@ package bindings import ( "fmt" - "os" - "sort" "strings" - "github.com/heroku/color" - "github.com/paketo-buildpacks/libpak/bard" - "github.com/buildpacks/libcnb" ) @@ -50,46 +45,17 @@ func OfProvider(p string) Predicate { // Resolve returns all bindings from binds that match every Predicate in predicates. func Resolve(binds libcnb.Bindings, predicates ...Predicate) libcnb.Bindings { var result libcnb.Bindings - logger := bard.NewLogger(os.Stdout) - // deep copy for _, bind := range binds { result = append(result, bind) } - // filter on predicates for _, p := range predicates { result = filter(result, p) } - - LogBindings(result, logger) return result } -func LogBindings(bindings libcnb.Bindings, logger bard.Logger) { - f := color.New(color.Bold) - - if len(bindings) > 0 { - logger.Header(f.Sprint("Bindings Identified:")) - } else { - logger.Header(f.Sprint("No Bindings Found")) - } - - var s []string - for _, binding := range bindings { - - for k := range binding.Secret { - s = append(s, k) - } - sort.Strings(s) - - logger.Bodyf("Name: %s", binding.Name) - logger.Bodyf("Keys: %s", s) - s = nil - } - -} - // ResolveOne returns a single binding from bindings that match every Predicate if present. If exactly one match is found // ResolveOne returns the binding and true. If zero matches are found, ResolveOne returns an empty binding and false. // An error is returned if multiple matches are found. diff --git a/bindings/resolve_test.go b/bindings/resolve_test.go index 989da52..c200235 100644 --- a/bindings/resolve_test.go +++ b/bindings/resolve_test.go @@ -17,11 +17,8 @@ package bindings_test import ( - "bytes" "testing" - "github.com/paketo-buildpacks/libpak/bard" - "github.com/buildpacks/libcnb" . "github.com/onsi/gomega" "github.com/sclevine/spec" @@ -32,9 +29,8 @@ import ( func testResolve(t *testing.T, context spec.G, it spec.S) { var ( Expect = NewWithT(t).Expect - b *bytes.Buffer - logger bard.Logger - binds libcnb.Bindings + + binds libcnb.Bindings ) it.Before(func() { @@ -167,42 +163,4 @@ func testResolve(t *testing.T, context spec.G, it spec.S) { }) }) }) - - context("bindings are logged", func() { - - it.Before(func() { - b = bytes.NewBuffer(nil) - logger = bard.NewLogger(b) - binds = []libcnb.Binding{ - { - Name: "name1", - Type: "some-type", - Provider: "some-provider", - Secret: map[string]string{"my-key1": "my-sec1"}, - }, - { - Name: "name2", - Type: "some-type", - Provider: "some-provider", - Secret: map[string]string{"my-key2": "my-sec2"}, - }, - } - }) - - it("checks that binding info is logged", func() { - - bindings.LogBindings(binds, logger) - Expect(b.String()).To(ContainSubstring("name1")) - Expect(b.String()).To(ContainSubstring("my-key1")) - - Expect(b.String()).To(ContainSubstring("name2")) - Expect(b.String()).To(ContainSubstring("my-key2")) - }) - - it("checks that nothing is logged is no bindings found", func() { - binds = []libcnb.Binding{} - bindings.LogBindings(binds, logger) - Expect(b.String()).To(ContainSubstring("No Bindings Found")) - }) - }) } From 98b299a6628e953e2b7025d27df7e17a5e3ab79b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 7 Sep 2021 10:04:21 +0000 Subject: [PATCH 44/44] Bump github.com/pelletier/go-toml from 1.9.3 to 1.9.4 Bumps [github.com/pelletier/go-toml](https://github.com/pelletier/go-toml) from 1.9.3 to 1.9.4. - [Release notes](https://github.com/pelletier/go-toml/releases) - [Commits](https://github.com/pelletier/go-toml/compare/v1.9.3...v1.9.4) --- updated-dependencies: - dependency-name: github.com/pelletier/go-toml dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- go.mod | 2 +- go.sum | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/go.mod b/go.mod index 4efd850..90ffa75 100644 --- a/go.mod +++ b/go.mod @@ -9,7 +9,7 @@ require ( github.com/heroku/color v0.0.6 github.com/imdario/mergo v0.3.12 github.com/onsi/gomega v1.16.0 - github.com/pelletier/go-toml v1.9.3 + github.com/pelletier/go-toml v1.9.4 github.com/sclevine/spec v1.4.0 github.com/spf13/pflag v1.0.5 github.com/stretchr/testify v1.7.0 diff --git a/go.sum b/go.sum index 1900b58..1086376 100644 --- a/go.sum +++ b/go.sum @@ -50,8 +50,8 @@ github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1y github.com/onsi/gomega v1.13.0/go.mod h1:lRk9szgn8TxENtWd0Tp4c3wjlRfMTMH27I+3Je41yGY= github.com/onsi/gomega v1.16.0 h1:6gjqkI8iiRHMvdccRJM8rVKjCWk6ZIm6FTm3ddIe4/c= github.com/onsi/gomega v1.16.0/go.mod h1:HnhC7FXeEQY45zxNK3PPoIUhzk/80Xly9PcubAlGdZY= -github.com/pelletier/go-toml v1.9.3 h1:zeC5b1GviRUyKYd6OJPvBU/mcVDVoL1OhT17FCt5dSQ= -github.com/pelletier/go-toml v1.9.3/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c= +github.com/pelletier/go-toml v1.9.4 h1:tjENF6MfZAg8e4ZmZTeWaWiT2vXtsoO6+iuOjFhECwM= +github.com/pelletier/go-toml v1.9.4/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/sclevine/spec v1.4.0 h1:z/Q9idDcay5m5irkZ28M7PtQM4aOISzOpj4bUPkDee8=