incremental
incremental copied to clipboard
Ignore .pyc files
It doesn't seem like incremental should mangle bytecode files:
❯ .tox/twine/bin/python -m incremental.update --rc treq
Updating codebase to 20.9.0rc1
Updating /home/twm/dev/treq/src/treq/__pycache__/api.cpython-37.pyc
Updating /home/twm/dev/treq/src/treq/__pycache__/api.cpython-36.pyc
Observed with incremental 17.5.0
+1. In fact it should probably have several exclusions, off the top of my head these seem reasonable:
- don't mess with
.pycfiles - possibly don't do the
Version(..., NEXT, ...)substitution if it isn't in a.pyfile? - don't recurse into
__pycache__at all - don't touch
*~or other backup-like files - possibly don't even recurse into subdirectories that don't have an
__init__.py?
Perhaps we should implement the most-obvious of these and then allow exclusion patterns to be added in a setup.cfg section if it turns out some projects have more complicated needs
The ability to exclude specific files would be useful, for example so that the Twisted compatibility policy can include examples of the NEXT substitution syntaxes.