-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support Parameterize in get-schema, gen-sdk #16210
Conversation
Changelog[uncommitted] (2024-05-17) |
9efe885
to
5053f5f
Compare
dac94fe
to
944b984
Compare
e218f5a
to
ebdc7fc
Compare
@@ -25,16 +25,18 @@ import ( | |||
|
|||
func newExtractSchemaCommand() *cobra.Command { | |||
cmd := &cobra.Command{ | |||
Use: "get-schema <schema_source>", | |||
Args: cobra.ExactArgs(1), | |||
Use: "get-schema <schema_source> [provider parameters]", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would go with a repeatable flag here, not arbitrary args:
pulumi package get-schema terraform-bridge --param name=random -p version='>=3'
Instead of
pulumi package get-schema terraform-bridge name=random version='>=3'
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems a lot more verbose, not clear what the win is there?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My preference is to have binary command [sumcommands] [--modifiers]
. Feel free to ignore me if you disagree.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeh gonna go with this feels more natural to me for now
Description
This plumbs the use of the Parameterize method and GetSchema into get-schema (and gen-sdk partially, not that sdk gen can actually deal with it yet properly).
It also happens to fix get-schema working better for shimless providers (i.e. pointing to a folder and using the language host to run it).
Checklist
make tidy
to update any new dependenciesmake lint
to verify my code passes the lint checkgofumpt
make changelog
and committed thechangelog/pending/<file>
documenting my change