Skip to content
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

Suppress the config import confirmation text in the output of drush deploy (to avoid "yes"-related madness). #5228

Closed
maxstarkenburg opened this issue Sep 9, 2022 · 1 comment

Comments

@maxstarkenburg
Copy link

Is your feature request related to a problem? Please describe.

A colleague and I wasted non-insignificant time trying to debug a problem that was the result of a misunderstanding of drush deploy behavior, due to something it outputs while running (and maybe a little ignorance of a certain shell command). If there are config diffs when running drush deploy, it will output Import the listed configuration changes? (yes/no) [yes]:, and sometimes the actual import takes a while, so it can appear to be waiting for your response (like a normal drush cim).

I guess she was unaware that deploy assumes -y or --yes if only one waits. I've also gotten tripped up by this on occasion, but must have typed y out of habit, whereas she typed in a full yes. This resulted in her terminal outputting hundreds of thousands of lines of the letter y in a matter of seconds, because apparently that's the default behavior of the *nix yes command (which I only had the most passing familiarity with before today, only in a scripting context, so didn't realize sooner what the problem was).

Describe the solution you'd like

Don't output Import the listed configuration changes? (yes/no) [yes]: while drush deploy is running, at least for the default/non-verbose mode. Or maybe it's just recycling what cim outputs (it's indeed the same exact text, barring --no usage) in which case it needs more forceful prevention/suppressing somehow?

Also, change the example in drush deploy --help to not use -y (and to remove and accept all prompts), since it implies that's not already the default behavior.

Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.

Additional context
Add any other context or screenshots about the feature request here.

@weitzman
Copy link
Member

If you dont want avoid prompts and just accept defaults, run with --yes or --no-interaction.

I didnt know about the yes command. Thats bizaare.

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

No branches or pull requests

2 participants