Merge pull request #193 from brutasse/feature/sentry-dsn-env

Ability to get SENTRY_DSN from the environment variables
This commit is contained in:
Vincent Driessen 2013-03-16 06:49:02 -07:00
commit d15fee2cfb
1 changed files with 3 additions and 1 deletions

View File

@ -1,4 +1,5 @@
#!/usr/bin/env python
import os
import sys
import argparse
import logging
@ -45,7 +46,8 @@ def main():
# Other default arguments
if args.sentry_dsn is None:
args.sentry_dsn = settings.get('SENTRY_DSN', None)
args.sentry_dsn = settings.get('SENTRY_DSN',
os.environ.get('SENTRY_DSN', None))
if args.verbose and args.quiet:
raise RuntimeError("Flags --verbose and --quiet are mutually exclusive.")