This stems from #2323039: Extend conditional spec and the easiest way to do this is by allowing for tokens to be passed as options to the original cook command. This would also (potentially) allow for nested options though I'd have to test drush context heavily before seeing if that's actually the case.

Idea:

drush cook coolstuff --y --dbuser=btopro --dbpwd=mypassword --profile=mooc

This could then (because of the --y option) force the other drush commands to execute without prompting. One such command could be a madlib with the above 3 options as required responses for the madlib to fire. This would then populate those 3 items in the madlib, then execute it, then keep going, allowing for packaging systems or lazy developers to boil things down even further into 1, ridiculously flexible drush command with a few options that could be swapped out based on the client / who you are spinning a site up for.

Comments

  • btopro committed e4041af on 7.x-1.x
    Initial work to get #2323035 and #2323051 worked out. stable but not yet...

  • btopro committed c9b7bcd on 7.x-1.x
    madlib tokens passed in as options #2323051
    
btopro’s picture

Status: Active » Fixed
drush cook dr_si --mlt-profile=mooc --mlt-db-url=things@stuff:local --mlt-clean-url=0 --mlt-db-prefix=cool_ --y

will now work! Things need to be prefixed with --mlt- to avoid potential conflicts with ACTUAL options downstream :)

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.