@@ -67,9 +67,10 @@ Here's a quick checklist to follow when coding to ensure a good pull request
6767 goal.
6868- Ensure all indentation is done as 4-spaces and your editor is set to unix line
6969 endings.
70- - The code matches PEP8 style guides. Make sure to run
71- ` pycodestyle tableauserverclient test samples ` to catch and fix any style
72- issues before submitting your pull request.
70+ - The code matches PEP8 style guides, enforced by the black formatter. Make sure to run
71+ ` black --line-length 120 tableauserverclient samples test ` to catch and fix any style
72+ issues before submitting your pull request. (Run black with the ` --check ` option if
73+ you want to check whether formatting is valid without changing any files.)
7374- Keep commit messages clean and descriptive.
7475
7576### Use git pre-commit hook
@@ -84,7 +85,7 @@ Create a file `pre-commit` with the contents below and mark it as executable
8485
8586To test that the hook is working correctly, make a style-inconsistent change (for
8687example, changing some indentation to not be a multiple of 4), then try to commit
87- locally. You should get a failure with an explanation from pycodestyle with the
88+ locally. You should get a failure with an explanation from black with the
8889issue.
8990
9091``` shell
9495if [ -e tableauserverclient/__init__.py ];
9596then
9697 # check for style conventions in all code dirs
97- echo Running pycodestyle
98- pycodestyle tableauserverclient test samples
98+ echo Running black format check
99+ black --check --line-length 120 tableauserverclient samples test
99100fi
100101```
101102
0 commit comments