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

Add more missing ini options #541

Merged
merged 1 commit into from
Sep 24, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
20 changes: 20 additions & 0 deletions bandit/cli/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -377,11 +377,21 @@ def main():
ini_options.get('format'),
'output format')

args.msg_template = _log_option_source(
args.msg_template,
ini_options.get('msg-template'),
'output message template')

args.output_file = _log_option_source(
args.output_file,
ini_options.get('output'),
'output file')

args.verbose = _log_option_source(
args.verbose,
ini_options.get('verbose'),
'output extra information')

args.debug = _log_option_source(
args.debug,
ini_options.get('debug'),
Expand All @@ -392,6 +402,16 @@ def main():
ini_options.get('quiet'),
'silent mode')

args.ignore_nosec = _log_option_source(
args.ignore_nosec,
ini_options.get('ignore-nosec'),
'do not skip lines with # nosec')

args.baseline = _log_option_source(
args.baseline,
ini_options.get('baseline'),
'path of a baseline report')

if not args.targets:
LOG.error("No targets found in CLI or ini files, exiting.")
sys.exit(2)
Expand Down