From be288032c8fdd6a112b2c456cb5b780cbc2e7090 Mon Sep 17 00:00:00 2001 From: KV Date: Thu, 23 Jul 2020 15:16:22 +0200 Subject: [PATCH] Restructure the group dict initialization By putting all value entries on separate lines with a trailing comma, it becomes easier to read the diff when later inserting or deleting the first or last value entry in any dict. --- src/wireviz/build_examples.py | 29 ++++++++++++++++++----------- 1 file changed, 18 insertions(+), 11 deletions(-) diff --git a/src/wireviz/build_examples.py b/src/wireviz/build_examples.py index 2ef60e04..6a5bc66d 100755 --- a/src/wireviz/build_examples.py +++ b/src/wireviz/build_examples.py @@ -14,17 +14,24 @@ readme = 'readme.md' -groups = {} -groups['examples'] = {'path': Path(script_path).parent.parent.parent / 'examples', - 'prefix': 'ex', - readme: [], # Include no files - 'title': 'Example Gallery'} -groups['tutorial'] = {'path': Path(script_path).parent.parent.parent / 'tutorial', - 'prefix': 'tutorial', - readme: ['md', 'yml'], # Include .md and .yml files - 'title': 'WireViz Tutorial'} -groups['demos'] = {'path': Path(script_path).parent.parent.parent / 'examples', - 'prefix': 'demo'} +groups = { + 'examples': { + 'path': Path(script_path).parent.parent.parent / 'examples', + 'prefix': 'ex', + readme: [], # Include no files + 'title': 'Example Gallery', + }, + 'tutorial' : { + 'path': Path(script_path).parent.parent.parent / 'tutorial', + 'prefix': 'tutorial', + readme: ['md', 'yml'], # Include .md and .yml files + 'title': 'WireViz Tutorial', + }, + 'demos' : { + 'path': Path(script_path).parent.parent.parent / 'examples', + 'prefix': 'demo', + }, +} input_extensions = ['.yml'] generated_extensions = ['.gv', '.png', '.svg', '.html', '.bom.tsv']