From 61e0f33ce4424bfb6e0d399490795584ff7b64cd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Manuel=20R=C3=BCger?= Date: Wed, 30 Aug 2023 11:29:32 +0200 Subject: [PATCH 1/2] chore: Replace ghodss/yaml with sigs.k8s.io/yaml MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This is a fork that is maintained by the kubernetes community. https://github.com/kubernetes-sigs/yaml Signed-off-by: Manuel Rüger --- go.mod | 3 +-- go.sum | 1 - parser/yaml/yaml.go | 2 +- plugin/plugin.go | 2 +- 4 files changed, 3 insertions(+), 5 deletions(-) diff --git a/go.mod b/go.mod index 784d80fbf8..10f7c814fd 100644 --- a/go.mod +++ b/go.mod @@ -10,7 +10,6 @@ require ( github.com/basgys/goxml2json v1.1.0 github.com/bufbuild/protocompile v0.5.1 github.com/cpuguy83/dockercfg v0.3.1 - github.com/ghodss/yaml v1.0.0 github.com/go-akka/configuration v0.0.0-20200606091224-a002c0330665 github.com/go-ini/ini v1.67.0 github.com/google/go-cmp v0.5.9 @@ -36,6 +35,7 @@ require ( muzzammil.xyz/jsonc v1.0.0 olympos.io/encoding/edn v0.0.0-20201019073823-d3554ca0b0a3 oras.land/oras-go/v2 v2.3.0 + sigs.k8s.io/yaml v1.3.0 ) require ( @@ -125,5 +125,4 @@ require ( gopkg.in/ini.v1 v1.66.2 // indirect gopkg.in/yaml.v2 v2.4.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect - sigs.k8s.io/yaml v1.3.0 // indirect ) diff --git a/go.sum b/go.sum index 5f97a53344..4b2f265ba7 100644 --- a/go.sum +++ b/go.sum @@ -309,7 +309,6 @@ github.com/foxcpp/go-mockdns v1.0.0 h1:7jBqxd3WDWwi/6WhDvacvH1XsN3rOLXyHM1uhvIx6 github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= github.com/fsnotify/fsnotify v1.6.0 h1:n+5WquG0fcWoWp6xPWfHdbskMCQaFnG6PfBrh1Ky4HY= github.com/fsnotify/fsnotify v1.6.0/go.mod h1:sl3t1tCWJFWoRz9R8WJCbQihKKwmorjAbSClcnxKAGw= -github.com/ghodss/yaml v1.0.0 h1:wQHKEahhL6wmXdzwWG11gIVCkOv05bNOh+Rxn0yngAk= github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= github.com/go-akka/configuration v0.0.0-20200606091224-a002c0330665 h1:Iz3aEheYgn+//VX7VisgCmF/wW3BMtXCLbvHV4jMQJA= github.com/go-akka/configuration v0.0.0-20200606091224-a002c0330665/go.mod h1:19bUnum2ZAeftfwwLZ/wRe7idyfoW2MfmXO464Hrfbw= diff --git a/parser/yaml/yaml.go b/parser/yaml/yaml.go index e2b4d9b684..671eacd184 100644 --- a/parser/yaml/yaml.go +++ b/parser/yaml/yaml.go @@ -4,7 +4,7 @@ import ( "bytes" "fmt" - "github.com/ghodss/yaml" + "sigs.k8s.io/yaml" ) // Parser is a YAML parser. diff --git a/plugin/plugin.go b/plugin/plugin.go index 49052f917f..d871221320 100644 --- a/plugin/plugin.go +++ b/plugin/plugin.go @@ -10,7 +10,7 @@ import ( "strings" "syscall" - "github.com/ghodss/yaml" + "sigs.k8s.io/yaml" ) const ( From 9755a582558a3f2349c820e08b903f0aa8f4a2c6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Manuel=20R=C3=BCger?= Date: Wed, 30 Aug 2023 11:41:07 +0200 Subject: [PATCH 2/2] chore: Fix lint MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Manuel Rüger --- .golangci.yaml | 3 --- 1 file changed, 3 deletions(-) diff --git a/.golangci.yaml b/.golangci.yaml index f85e0d30b9..48df31d94a 100644 --- a/.golangci.yaml +++ b/.golangci.yaml @@ -5,7 +5,6 @@ linter-settings: linters: disable-all: true enable: - - deadcode - errcheck - goconst - gofmt @@ -20,10 +19,8 @@ linters: - predeclared - revive - staticcheck - - structcheck - typecheck - unconvert - unparam - unused - - varcheck - wastedassign