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

blt sync:refresh still prompts for confirmation when -y is supplied. #1810

Closed
thom8 opened this issue Jul 18, 2017 · 1 comment
Closed

blt sync:refresh still prompts for confirmation when -y is supplied. #1810

thom8 opened this issue Jul 18, 2017 · 1 comment
Labels
Bug Something isn't working

Comments

@thom8
Copy link
Contributor

thom8 commented Jul 18, 2017

My system information:

  • Operating system type: MacOS Sierra
  • Operating system version: 10.12.5
  • BLT version: 8.9.0-rc2

When I run this command:

blt sync:refresh -y

I get the following output:

> sync
> sync:db
> setup:settings
[Acquia\Blt\Robo\Tasks\DrushTask] Running /Users/thom/Projects/deloitte/toll-drupal/vendor/bin/drush cache-clear drush --uri=default && /Users/thom/Projects/deloitte/toll-drupal/vendor/bin/drush sql-drop --uri=default && /Users/thom/Projects/deloitte/toll-drupal/vendor/bin/drush sql-sync @toll.prod @toll.local --structure-tables-key=lightweight --create-db --sanitize --uri=default && /Users/thom/Projects/deloitte/toll-drupal/vendor/bin/drush cache-clear drush --uri=default in /Users/thom/Projects/deloitte/toll-drupal/docroot
'drush' cache was cleared.                                                                                                                                                                                                         [success]
Do you really want to drop all tables in the database drupal? (y/n):

And I expected this to happen:

Answer all confirmations with "yes" based on command docs

Usage:
  sync:refresh

Options:
  -h, --help            Display this help message
  -q, --quiet           Do not output any message
  -V, --version         Display this application version
      --ansi            Force ANSI output
      --no-ansi         Disable ANSI output
  -n, --no-interaction  Do not ask any interactive question
  -y, --yes             Answer all confirmations with "yes"
  -D, --define=DEFINE   Define a configuration item value. (multiple values allowed)
  -v|vv|vvv, --verbose  Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug

Help:
  Copies remote db to local db, re-imports config, and executes db updates.
@thom8
Copy link
Contributor Author

thom8 commented Jul 18, 2017

Perhaps we could assume each task runs with ->option('yes') and have a single prompt for both
sql-drop & sql-sync which can be bypassed with -y

https://github.com/acquia/blt/blob/8.x/src/Robo/Commands/Sync/DbCommand.php#L62

@grasmash grasmash added the Bug Something isn't working label Jul 18, 2017
grasmash added a commit to grasmash/bolt that referenced this issue Jul 18, 2017
grasmash added a commit to grasmash/bolt that referenced this issue Jul 18, 2017
grasmash added a commit to grasmash/bolt that referenced this issue Jul 18, 2017
grasmash added a commit to grasmash/bolt that referenced this issue Jul 19, 2017
grasmash added a commit to grasmash/bolt that referenced this issue Jul 19, 2017
grasmash added a commit to grasmash/bolt that referenced this issue Jul 19, 2017
grasmash added a commit to grasmash/bolt that referenced this issue Jul 20, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants