shipwright-io / cli

A CLI for building container images on Kubernetes!
https://shipwright.io
Apache License 2.0
16 stars 29 forks source link

[FEATURE] Generalize flag names for `shp build` commands #214

Open adambkaplan opened 10 months ago

adambkaplan commented 10 months ago

Is there an existing feature request for this?

Is your feature request related to a problem or use-case? Please describe.

The shp build sub-commands have flags that are closely tied to the underlying v1alpha1 API. These should be generalized or reconsidered so they are supported by the v1beta1 API, or potential future API versions.

Describe the solution that you would like.

Flag names should be "feature-oriented" so they are independent of the underlying API. For example, flags that explicitly reference apiVersion should be deprecated and removed.

Recommended changes (based on feedback below):

Describe alternatives you have considered.

Keep the existing flags - this will not prove tenable long term.

Anything else?

Use comments on this issue to suggest flag deprecations or renames. These will be added to the "solution" section once adopted.

Proposed during https://github.com/shipwright-io/community/issues/183 discussion.

qu1queee commented 10 months ago

@SaschaSchwarze0 @HeavyWombat @qu1queee @adambkaplan per the community meeting, pls provide some input on this(ideas).

HeavyWombat commented 9 months ago

I had an idea recently, that we might try out in the context of a time boxed spike or similar: Use Go AST in a separate tool in the CLI package to generate the command-line flags procedural based on the Shipwright Build "CRD" structs for Build and BuildRun. The flag name would reflect the "path" inside the struct. This could allow us -- in case this works -- to make sure we are always in sync with what we have configurable in the spec with what users can configure in the CLI.

qu1queee commented 9 months ago

From Refinement, proposing to bring this issue back to a community meeting by end of February.

qu1queee commented 7 months ago

From Refinement, we will go with CLI with alpha for v0.13.0, this allow us more time to finish this item. Therefore moving out of v0.13.0

CLI needs to have this item ready once we stop serving the v1alpha1 a-inversion

fyi @adambkaplan @SaschaSchwarze0