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

Parameter --osxnotify is hard to negate #10

Open
wcooley opened this issue Oct 27, 2015 · 0 comments
Open

Parameter --osxnotify is hard to negate #10

wcooley opened this issue Oct 27, 2015 · 0 comments

Comments

@wcooley
Copy link

wcooley commented Oct 27, 2015

The only way I know to pass bool(False) with the current implementation is to pass in an empty string: osxnotify='' -- argparse does no implicit cast from str to bool other than the default Python truth test for empty sequences. So one must either write a str2bool function or add a --no-osxnotify option, using argparse.add_argument's action='store_true' and action='store_false'.

Or maybe drop the option altogether and let it be disabled with -p no:osxnotify once #9 is fixed.

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

1 participant