diff --git a/docs/writing/gotchas.rst b/docs/writing/gotchas.rst index 3a4c3350a..f8e2e2377 100644 --- a/docs/writing/gotchas.rst +++ b/docs/writing/gotchas.rst @@ -224,7 +224,7 @@ Removing Bytecode (.pyc) Files Here's nice trick for removing all of these files, if they already exist:: - $ find . -name "*.pyc" -delete + $ find . -type f -name "*.py[co]" -delete -or -type d -name "__pycache__" -delete Run that from the root directory of your project, and all ``.pyc`` files will suddenly vanish. Much better.