diff options
author | Benjamin Peterson <benjamin@python.org> | 2008-07-01 18:23:09 +0000 |
---|---|---|
committer | Benjamin Peterson <benjamin@python.org> | 2008-07-01 18:23:09 +0000 |
commit | de9c869fb8c1f842bc3dfc4d51f287cb6b644ab2 (patch) | |
tree | da0b9c0e9d56288354f936b59021d94018a172a8 /Mac/scripts/zappycfiles.py | |
parent | bbfd71d7ac02bc2053a0ba494a3f055fbec8deee (diff) | |
download | cpython-git-de9c869fb8c1f842bc3dfc4d51f287cb6b644ab2.tar.gz |
Hopefully fix make framework install on Mac (see 3174)
Removal of the Mac modules broke many of the Mac scripts (including
BuildApplet.py) so the building of the Python launcher and IDLE.app was
broken. I manually copied built versions of those apps into Mac. Everything else
which used Mac modules had to die.
Diffstat (limited to 'Mac/scripts/zappycfiles.py')
-rw-r--r-- | Mac/scripts/zappycfiles.py | 36 |
1 files changed, 0 insertions, 36 deletions
diff --git a/Mac/scripts/zappycfiles.py b/Mac/scripts/zappycfiles.py deleted file mode 100644 index b377e0d9a8..0000000000 --- a/Mac/scripts/zappycfiles.py +++ /dev/null @@ -1,36 +0,0 @@ -#!/usr/local/bin/python -"""Recursively zap all .pyc and .pyo files""" -import os -import sys - -# set doit true to actually delete files -# set doit false to just print what would be deleted -doit = 1 - -def main(): - if not sys.argv[1:]: - if os.name == 'mac': - import EasyDialogs - dir = EasyDialogs.AskFolder(message='Directory to zap pyc files in') - if not dir: - sys.exit(0) - zappyc(dir) - else: - print('Usage: zappyc dir ...') - sys.exit(1) - for dir in sys.argv[1:]: - zappyc(dir) - -def zappyc(dir): - os.walk(dir, walker, None) - -def walker(dummy, top, names): - for name in names: - if name[-4:] in ('.pyc', '.pyo'): - path = os.path.join(top, name) - print('Zapping', path) - if doit: - os.unlink(path) - -if __name__ == '__main__': - main() |