Skip to content

internal/generate: refactoring for new generate commands#3018

Merged
estroz merged 1 commit intooperator-framework:masterfrom
estroz:refactor/csv-base
May 13, 2020
Merged

internal/generate: refactoring for new generate commands#3018
estroz merged 1 commit intooperator-framework:masterfrom
estroz:refactor/csv-base

Conversation

@estroz
Copy link
Copy Markdown
Member

@estroz estroz commented May 13, 2020

Description of the change:

  • internal/generate/clusterserviceversion: future home of CSV generation code. For now this just holds the base CSV getter and interactive prompt code, moved from olm-catalog
  • internal/generate/olm-catalog: update CSV generator to use base getter
  • internal/generate/testdata: update CSVs with new UI metadata defaults
  • internal/util/k8sutil: NewYAMLScanner now takes an io.Reader rather than []byte directly

Motivation for the change: #2860 is a fairly big PR containing some changes that made sense to break into their own PR. Additionally the new base CSV getter works well with the current CSV generator, so that has been refactored here as well.

/cc @hasbro17 @varshaprasad96 @joelanford

@estroz estroz added refactoring olm-integration Issue relates to the OLM integration labels May 13, 2020
Copy link
Copy Markdown
Contributor

@hasbro17 hasbro17 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM
I like the new CSV base getter. A lot easier to read than what we had before.

Comment thread internal/generate/clusterserviceversion/bases/clusterserviceversion.go Outdated
code. For now this just holds the base CSV generator and interactive
prompt code, moved from olm-catalog

internal/generate/olm-catalog: update CSV generator to use base getter

internal/generate/testdata: update CSVs with new UI metadata defaults

internal/util/k8sutil: NewYAMLScanner now takes an io.Reader rather
than []byte directly
@estroz estroz force-pushed the refactor/csv-base branch from ba45a1a to 9017ee4 Compare May 13, 2020 15:52
@estroz estroz merged commit 7a18c56 into operator-framework:master May 13, 2020
@estroz estroz deleted the refactor/csv-base branch May 13, 2020 16:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

olm-integration Issue relates to the OLM integration

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants