.pyc files...

Anders Arnholm Anders+news at Arnholm.nu
Fri Nov 19 09:05:32 EST 2004


Jorgen Grahn <jgrahn-nntq at algonet.se> skriver:
> My weapon of choice would be
>   find . -name '*.pyc' | xargs rm
> but on the other hand .pyc files don't bother me much ...

But Jörgen, that use of find/xargs assumes that you know what files
that exists. If you have files whith bad names, you should always use
-print0 and -0 e.g

  find . -name \*.pyc -print0 | xargs -0 rm

/ Balp
-- 
http://anders.arnholm.nu/			     Keep on Balping



More information about the Python-list mailing list