Logo
Explore Help
Sign In
parallelvirtualcluster/pvc
1
0
Fork 0
You've already forked pvc
Code Issues 11 Pull Requests Projects Releases 114 Wiki Activity
Files
master
pvc/lint

19 lines
306 B
Plaintext
Raw Permalink Normal View History

Lint: F841 local variable '<variable>' is assigned to but never used
2020-11-06 21:13:13 -05:00
#!/usr/bin/env bash
Add newline to start of lint
2021-11-06 03:04:14 -04:00
Lint: F841 local variable '<variable>' is assigned to but never used
2020-11-06 21:13:13 -05:00
if ! which flake8 &>/dev/null; then
echo "Flake8 is required to lint this project"
exit 1
fi
Ensure all helper scripts pushd/popd Make sure all of these move to the root of the repository first, then return to where they were afterwards, using pushd/popd. This allows them to be executed from anywhere in the repo.
2021-11-06 03:16:02 -04:00
pushd $( git rev-parse --show-toplevel ) &>/dev/null
Add start delineators to command output
2021-11-06 13:35:30 -04:00
echo ">>> Linting..."
Move Flake configuration into dedicated file Avoid passing arguments in the script.
2021-11-06 02:55:37 -04:00
flake8
Add nicer output to lint script
2020-11-07 15:15:21 -05:00
ret=$?
if [[ $ret -eq 0 ]]; then
echo "No linting issues found!"
fi
Ensure all helper scripts pushd/popd Make sure all of these move to the root of the repository first, then return to where they were afterwards, using pushd/popd. This allows them to be executed from anywhere in the repo.
2021-11-06 03:16:02 -04:00
popd &>/dev/null
Add nicer output to lint script
2020-11-07 15:15:21 -05:00
exit $ret
Reference in New Issue Copy Permalink
Powered by Gitea Version: 1.24.0 Page: 645ms Template: 3ms
English
Bahasa Indonesia Deutsch English Español Français Gaeilge Italiano Latviešu Magyar nyelv Nederlands Polski Português de Portugal Português do Brasil Suomi Svenska Türkçe Čeština Ελληνικά Български Русский Українська فارسی മലയാളം 日本語 简体中文 繁體中文(台灣) 繁體中文(香港) 한국어
Licenses API