-
Notifications
You must be signed in to change notification settings - Fork 106
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
better manual control over linting and testing (#2338)
* better manual control over linting and testing * hide set -x behind VERBOSE
- Loading branch information
1 parent
3b1b928
commit 13bf1d5
Showing
3 changed files
with
26 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,20 @@ | ||
set -e | ||
#!/usr/bin/env bash | ||
|
||
if [ -n "${FIX_LINT}" ]; then | ||
ISORT_FLAG= | ||
BLACK_FLAG= | ||
else | ||
ISORT_FLAG='--check-only' | ||
BLACK_FLAG='--check' | ||
fi | ||
|
||
set -ex | ||
|
||
cd $PROTOCOL_DIR | ||
flake8 discovery-provider/src/ | ||
flake8 discovery-provider/integration_tests/ | ||
isort --check-only discovery-provider/src/ | ||
isort --check-only discovery-provider/integration_tests/ | ||
black --check discovery-provider/src/ | ||
black --check discovery-provider/integration_tests/ | ||
isort ${ISORT_FLAG} discovery-provider/src/ | ||
isort ${ISORT_FLAG} discovery-provider/integration_tests/ | ||
black ${BLACK_FLAG} discovery-provider/src/ | ||
black ${BLACK_FLAG} discovery-provider/integration_tests/ | ||
mypy --ignore-missing-imports --follow-imports=silent --show-column-numbers discovery-provider/src/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters