Skip to content

Conversation

@code-asher
Copy link
Member

@code-asher code-asher commented Dec 5, 2025

This is like --yes, but for parameter prompts. Closes #20815. Most of the diff is refactoring the tests since they were all doing the same setup and changes to markdown/golden files for the --yes description change, the actual code changes are fairly small 😛

@code-asher code-asher force-pushed the asher/use-parameter-defaults branch 3 times, most recently from 61315e5 to 3adad37 Compare December 5, 2025 06:11
To make it easier to add new tests and parameters.  Largely unchanged in
functionality except:

1. All tests now perform parameter validation.
2. Add types to the parameters where before they were all defaulting to
   strings (except boolean, which seems to be an existing issue).
@code-asher code-asher force-pushed the asher/use-parameter-defaults branch 2 times, most recently from e63b201 to 31577a6 Compare December 5, 2025 07:02
This works already in production, but not in the tests because the
generated Terraform was missing quotes around the default value, which
must have been breaking the parser because it was returning no
parameters.  Then we were removing all non-matching parameters from the
request, which was all of them since the parser returned none.
This will accept parameter defaults without prompting (whether those
defaults come from the template or --parameter-default).  Similar to
--yes, but for parameter prompts.
@code-asher code-asher force-pushed the asher/use-parameter-defaults branch from 31577a6 to 5645473 Compare December 5, 2025 07:12
@code-asher code-asher requested review from ssncferreira and removed request for ssncferreira December 6, 2025 02:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

coder create --yes still prompts for parameter input, blocking fully non-interactive workspace creation

2 participants