In .github/workflows/pylint.yml:
- Update actions/checkout@v2 and actions/setup-python@v2 to the latest version
- Add pip dependency caching with cache: 'pip'
- Add branch and path filters to only run on Python file changes
- Rename job from build to lint (more descriptive)
- Add support for pull requests
For testing:
- Make a minor Python code change and push to a branch, verify that Pylint runs.
- Make a minor non-Python change and push to a branch, verify that Pylint doesn't run.
- Check that caching works (second run should be faster)
In
.github/workflows/pylint.yml:For testing: