You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@click.command()@click.option('--yes', is_flag=True, callback=abort_if_false,expose_value=False,prompt='Are you sure you want to drop the db?')defdropdb():
click.echo('Dropped all tables!')
The text was updated successfully, but these errors were encountered:
E: If my read of the issue is correct, based on a bit of hacking on the code, implementing this is nontrivial without significant refactor. The current option-based subcommand implementation makes it very hard, if not impossible to implement this without breaking something.
Your take might be correct. I didn't look too closely at possible implementations for this before opening the issue.
The real question is whether we actually want a "delete backup" confirmation prompt shown if the delete arg is used on a CLI, and I don't think we do.
Reopen this if you have a strong opposing view, but my thinking is that --remove, or whatever the flag is named, is enough of a confirmation that accidental deletion should be impossible.
Example from Click docs:
The text was updated successfully, but these errors were encountered: