mirror of
https://github.com/home-assistant/core.git
synced 2025-07-27 15:17:35 +00:00
Updated script/lint (#12600)
* Compare to common ancestor * Check if no file was changed
This commit is contained in:
parent
87c69452f9
commit
ffd3889271
@ -4,10 +4,14 @@
|
|||||||
cd "$(dirname "$0")/.."
|
cd "$(dirname "$0")/.."
|
||||||
|
|
||||||
if [ "$1" = "--changed" ]; then
|
if [ "$1" = "--changed" ]; then
|
||||||
export files="`git diff upstream/dev --name-only | grep -e '\.py$'`"
|
export files="`git diff upstream/dev... --name-only | grep -e '\.py$'`"
|
||||||
echo "================================================="
|
echo "================================================="
|
||||||
echo "FILES CHANGED (git diff upstream/dev --name-only)"
|
echo "FILES CHANGED (git diff upstream/dev... --name-only)"
|
||||||
echo "================================================="
|
echo "================================================="
|
||||||
|
if $files >/dev/null; then
|
||||||
|
echo "No python file changed"
|
||||||
|
exit
|
||||||
|
fi
|
||||||
printf "%s\n" $files
|
printf "%s\n" $files
|
||||||
echo "================"
|
echo "================"
|
||||||
echo "LINT with flake8"
|
echo "LINT with flake8"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user