@@ -6,7 +6,7 @@ documentation:
66 pandoc --from=markdown --to=rst --output=docs/README.rst README.md && cd docs && make html
77
88clean :
9- rm -rf build/ dist/ # Cleanup build dir
9+ rm -rf dist/ # Cleanup build dir
1010
1111setup :
1212 brew install pandoc sphinx-doc uv
@@ -25,19 +25,36 @@ release_production: documentation
2525lint_markdown :
2626 mdl -r ~ MD013,~MD029,~MD033 README.md
2727
28+ format :
29+ uv run autoflake --in-place -r --remove-all-unused-imports --remove-unused-variables adbe
30+ # See full error code list at https://pypi.org/project/autopep8/#features
31+ uv run autopep8 --recursive --in-place --select W292,W293,W391,W504,E121,E122,E123,E126,E128,E129,E131,E202,E225,E226,E241,E301,E302,E303,E704,E731 adbe
32+ uv run ruff check --config pyproject.toml --fix adbe
33+ uv run isort --line-length 88 --skip-gitignore adbe
34+ uv run isort --line-length 88 --skip-gitignore tests
35+
2836lint_python3 :
29- # E0602 is due to undefined variable unicode which is defined only for Python 2
30- # W0511 is fixme due to TODOs in the code.
31- # adbe/adbe.py:756:8: W0601: Global variable 'screen_record_file_path_on_device' undefined at the module level (global-variable-undefined)
32- # adbe/adbe.py:764:8: W0601: Global variable 'screen_record_file_path_on_device' undefined at the module level (global-variable-undefined)
33- # adbe/adbe.py:752:4: W0621: Redefining name 'screen_record_file_path_on_device' from outer scope (line 759) (redefined-outer-name)
34- # C0111: Missing function docstring (missing-docstring)
37+ uv run -- autoflake --check-diff -r --quiet --remove-all-unused-imports --remove-unused-variables adbe
38+ # Fail if there are Python syntax errors or undefined names
39+ uv run -- flake8 adbe --count --select=E9,F63,F7,F82 --show-source --statistics
40+ # W503 has been deprecated in favor of W504 - https://www.flake8rules.com/rules/W503.html
41+ uv run -- flake8 adbe --count --show-source --statistics --max-line-length=88 --ignore=E501,W503
42+ # Config file is specified for brevity
43+ uv run ruff check --config pyproject.toml adbe
44+ # Same line length as Black
45+ uv run isort --check --diff --line-length 88 --skip-gitignore .
46+ # E0602 is due to undefined variable unicode which is defined only for Python 2
47+ # W0511 is fixme due to TODOs in the code.
48+ # adbe/adbe.py:756:8: W0601: Global variable 'screen_record_file_path_on_device' undefined at the module level (global-variable-undefined)
49+ # adbe/adbe.py:764:8: W0601: Global variable 'screen_record_file_path_on_device' undefined at the module level (global-variable-undefined)
50+ # adbe/adbe.py:752:4: W0621: Redefining name 'screen_record_file_path_on_device' from outer scope (line 759) (redefined-outer-name)
51+ # C0111: Missing function docstring (missing-docstring)
3552 uv run -- pylint --disable=C0103,C0111,C0209,W1514 release.py
3653 uv run -- pylint adbe/* .py tests/* .py --disable=R0123,R0911,R0912,R0914,R0915,R1705,R1710,C0103,C0111,C0209,C0301,C0302,C1801,W0511,W0621,W0601,W0602,W0603
37- uv run -- flake8 adbe --count --ignore=F401,E126,E501,W504 --show-source --statistics
54+ uv run -- flake8 adbe --count --ignore=F401,E126,E501,W503 --show-source --statistics
3855 # Default complexity limit is 10
3956 # Default line length limit is 127
40- uv run -- flake8 adbe --count --exit-zero --ignore=F401,E126,E501,W504 --max-complexity=13 --max-line-length=127 --statistics
57+ uv run -- flake8 adbe --count --exit-zero --ignore=F401,E126,E501,W503 --max-complexity=13 --max-line-length=127 --statistics
4158
4259# To run a single test, for example, test_file_move3, try this
4360# python3 -m pytest -v tests/adbe_tests.py -k test_file_move3
0 commit comments