Migrates config package for ocm tools #78
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR aims to migrate the
pkg/config
contents from openshift-online/ocm-cli to ocm-common.This was tested by removing the
pkg/ocm/config
directory fromopenshift-online/ocm-cli
, running a sed command to replace all instances of config, and adding the following lines to go.mod. I then built the CLI tool, saw no build errors, ran a login and spot checked a few other commands with no issues.find cmd -type f -print0 | xargs -0 gsed -i s#github.com/openshift-online/ocm-cli/pkg/config#github.com/openshift-online/ocm-common/pkg/ocm/config#
^ Note this uses
gsed
because I'm on a Mac, linux users will just needsed
Additional testing was performed with migrating openshift/osdctl#632 to use these packages, using a similar require/replace methodology in the go.mod to test against this package locally.