Skip to content

Commit

Permalink
OCM-7571 | chore: switch from ghodss/yaml to sigs.k8s.io/yaml
Browse files Browse the repository at this point in the history
Module `github.com/ghodss/yaml` has been unmaintained for several years
and `sigs.k8s.io/yaml` is a maintained fork.

Signed-off-by: Mikel Olasagasti Uranga <mikel@olasagasti.info>
  • Loading branch information
mikelolasagasti committed Jul 31, 2024
1 parent 4e4a45f commit f012d59
Show file tree
Hide file tree
Showing 18 changed files with 251 additions and 34 deletions.
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ require (
github.com/briandowns/spinner v1.11.1
github.com/dchest/validator v0.0.0-20191217151620-8e45250f2371
github.com/dustin/go-humanize v1.0.0
github.com/ghodss/yaml v1.0.0
github.com/golang-jwt/jwt/v4 v4.5.0
github.com/golang/glog v1.2.0
github.com/google/go-cmp v0.6.0
Expand All @@ -45,6 +44,7 @@ require (
gopkg.in/yaml.v3 v3.0.1
k8s.io/apimachinery v0.29.2
k8s.io/utils v0.0.0-20230726121419-3b25d923346b
sigs.k8s.io/yaml v1.3.0
)

require (
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -114,8 +114,6 @@ github.com/evanphx/json-patch/v5 v5.6.0 h1:b91NhWfaz02IuVxO9faSllyAtNXHMPkC5J8sJ
github.com/evanphx/json-patch/v5 v5.6.0/go.mod h1:G79N1coSVB93tBe7j6PhzjmR3/2VvlbKOFpnXhI9Bw4=
github.com/fatih/color v1.7.0 h1:DkWD4oS2D8LGGgTQ6IvwJJXSL5Vp2ffcQg58nFV38Ys=
github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4=
github.com/ghodss/yaml v1.0.0 h1:wQHKEahhL6wmXdzwWG11gIVCkOv05bNOh+Rxn0yngAk=
github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04=
github.com/go-jose/go-jose/v4 v4.0.2 h1:R3l3kkBds16bO7ZFAEEcofK0MkrAJt3jlJznWZG0nvk=
github.com/go-jose/go-jose/v4 v4.0.2/go.mod h1:WVf9LFMHh/QVrmqrOfqun0C45tMe3RoiKJMPvgWwLfY=
github.com/go-kit/log v0.1.0/go.mod h1:zbhenjAZHb184qTLMA9ZjW7ThYL0H2mk7Q6pNt4vbaY=
Expand Down Expand Up @@ -488,3 +486,5 @@ k8s.io/klog/v2 v2.110.1 h1:U/Af64HJf7FcwMcXyKm2RPM22WZzyR7OSpYj5tg3cL0=
k8s.io/klog/v2 v2.110.1/go.mod h1:YGtd1984u+GgbuZ7e08/yBuAfKLSO0+uR1Fhi6ExXjo=
k8s.io/utils v0.0.0-20230726121419-3b25d923346b h1:sgn3ZU783SCgtaSJjpcVVlRqd6GSnlTLKgpAAttJvpI=
k8s.io/utils v0.0.0-20230726121419-3b25d923346b/go.mod h1:OLgZIPagt7ERELqWJFomSt595RzquPNLL48iOWgYOg0=
sigs.k8s.io/yaml v1.3.0 h1:a2VclLzOGrwOHDiV8EfBGhvjHvP46CtW5j6POvhYGGo=
sigs.k8s.io/yaml v1.3.0/go.mod h1:GeOyir5tyXNByN85N/dRIT9es5UQNerPYEKK56eTBm8=
2 changes: 1 addition & 1 deletion pkg/input/helper.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import (
"io"
"os"

"github.com/ghodss/yaml"
"sigs.k8s.io/yaml"
)

// UnmarshalInputFile is a generic unmarshaller from an input path
Expand Down
3 changes: 2 additions & 1 deletion pkg/output/output.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,8 @@ import (
"io"
"reflect"

"github.com/ghodss/yaml"
"sigs.k8s.io/yaml"

cmv1 "github.com/openshift-online/ocm-sdk-go/clustersmgmt/v1"
msv1 "github.com/openshift-online/ocm-sdk-go/servicemgmt/v1"

Expand Down
7 changes: 0 additions & 7 deletions vendor/github.com/ghodss/yaml/.travis.yml

This file was deleted.

6 changes: 3 additions & 3 deletions vendor/modules.txt
Original file line number Diff line number Diff line change
Expand Up @@ -250,9 +250,6 @@ github.com/evanphx/json-patch/v5
# github.com/fatih/color v1.7.0
## explicit
github.com/fatih/color
# github.com/ghodss/yaml v1.0.0
## explicit
github.com/ghodss/yaml
# github.com/go-jose/go-jose/v4 v4.0.2
## explicit; go 1.21
github.com/go-jose/go-jose/v4
Expand Down Expand Up @@ -668,4 +665,7 @@ k8s.io/utils/clock
k8s.io/utils/internal/third_party/forked/golang/net
k8s.io/utils/net
k8s.io/utils/strings/slices
# sigs.k8s.io/yaml v1.3.0
## explicit; go 1.12
sigs.k8s.io/yaml
# github.com/golang/glog => github.com/kubermatic/glog-logrus v0.0.0-20180829085450-3fa5b9870d1d

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 12 additions & 0 deletions vendor/sigs.k8s.io/yaml/.travis.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

31 changes: 31 additions & 0 deletions vendor/sigs.k8s.io/yaml/CONTRIBUTING.md

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

File renamed without changes.
27 changes: 27 additions & 0 deletions vendor/sigs.k8s.io/yaml/OWNERS

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 9 additions & 0 deletions vendor/sigs.k8s.io/yaml/RELEASE.md

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

17 changes: 17 additions & 0 deletions vendor/sigs.k8s.io/yaml/SECURITY_CONTACTS

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions vendor/sigs.k8s.io/yaml/code-of-conduct.md

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit f012d59

Please sign in to comment.