From 9e94e6942ec3df2770e0b350b354e33269c33c04 Mon Sep 17 00:00:00 2001 From: Tin Lam Date: Sat, 11 Aug 2018 03:05:27 -0500 Subject: [PATCH] Fix README.rst The current README.rst has references to configure bandit runs using a custom .INI-like file. In reality, that file should actually be a YAML file. Using the INI example provided will result in: ` [main] ERROR bandit.cfg : Error parsing file. ` This patch set updates the configuration so it is of proper YAML format so the execution will not error out. Signed-off-by: Tin Lam --- README.rst | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/README.rst b/README.rst index ed15d923c..64f2f9174 100644 --- a/README.rst +++ b/README.rst @@ -37,7 +37,7 @@ this Bandit processes each file, builds an AST from it, and runs appropriate plugins against the AST nodes. Once Bandit has finished scanning all the files it generates a report. -Bandit was originally developed within the OpenStack Security Project and +Bandit was originally developed within the OpenStack Security Project and later rehomed to PyCQA. Installation @@ -260,26 +260,28 @@ An optional config file may be supplied and may include: Per Project Command Line Args ----------------------------- -Projects may include a `.bandit` file that specifies command line arguments -that should be supplied for that project. The currently supported arguments -are: +Projects may include a YAML file named `.bandit` that specifies command line +arguments that should be supplied for that project. The currently supported +arguments are: - targets: comma separated list of target dirs/files to run bandit on - exclude: comma separated list of excluded paths - skips: comma separated list of tests to skip - tests: comma separated list of tests to run -To use this, put a .bandit file in your project's directory. For example: +To use this, put a YAML file named `.bandit` in your project's directory. +For example: :: - [bandit] exclude: /test :: - [bandit] - tests: B101,B102,B301 + tests: + - B101 + - B102 + - B301 Exclusions