Skip to content

Commit 31127a2

Browse files
committed
Skip 'shocco' code when running tox
when running tox in a devstack directory where you have previously run tox -edocs the bashate testenv will fail as the shocco code doesn't match the devstack style. eg: --- E003: Indent not multiple of 4: ' 2>/dev/null ||' - /home/stack/projects/openstack/openstack-dev/devstack/shocco/shocco.sh : L352 <snip> 27 bashate error(s) found --- Take the easy path and avoid running bashate in the shocco dir. Change-Id: I5b0155332ec994afaffc5c5961902281864cff61
1 parent 493d3b3 commit 31127a2

1 file changed

Lines changed: 14 additions & 13 deletions

File tree

tox.ini

Lines changed: 14 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -10,19 +10,20 @@ install_command = pip install {opts} {packages}
1010
[testenv:bashate]
1111
deps = bashate
1212
whitelist_externals = bash
13-
commands = bash -c "find {toxinidir} \
14-
-not \( -type d -name .?\* -prune \) \ # prune all 'dot' dirs
15-
-not \( -type d -name doc -prune \) \ # skip documentation
16-
-type f \ # only files
17-
-not -name \*~ \ # skip editors, readme, etc
18-
-not -name \*.md \
19-
\( \
20-
-name \*.sh -or \
21-
-name \*rc -or \
22-
-name functions\* -or \
23-
-wholename \*/inc/\* -or \ # /inc files and
24-
-wholename \*/lib/\* \ # /lib files are shell, but
25-
\) \ # have no extension
13+
commands = bash -c "find {toxinidir} \
14+
-not \( -type d -name .?\* -prune \) \ # prune all 'dot' dirs
15+
-not \( -type d -name doc -prune \) \ # skip documentation
16+
-not \( -type d -name shocco -prune \) \ # skip shocco
17+
-type f \ # only files
18+
-not -name \*~ \ # skip editors, readme, etc
19+
-not -name \*.md \
20+
\( \
21+
-name \*.sh -or \
22+
-name \*rc -or \
23+
-name functions\* -or \
24+
-wholename \*/inc/\* -or \ # /inc files and
25+
-wholename \*/lib/\* \ # /lib files are shell, but
26+
\) \ # have no extension
2627
-print0 | xargs -0 bashate -v"
2728

2829
[testenv:docs]

0 commit comments

Comments
 (0)