In a message of Fri, 09 Oct 2015 21:08:22 +1100, Joshua Stokes writes: >Hi > >Is there an available script to remove file created by either using the Python >module or by using git? > >Thanks > >>From Joshua P Stokes
No. A file is a file. It doesn't know which program created it. I can use python to create a file named anything_I_like and place it anywhere I have write permission in the filesystem. There is no way to get it to identify itself as 'made by python', so there is no way to write such a script. Now, python itself makes .pyc files whenever it runs, so if you want to clean those up, finding them and removing them is easy. But we need to know what OS you are running. If you want to delete a git repository, that is also fairly easy to do. If you want to do something else -- for instance, find out if you have any git repositories on this machine -- explain more about what you want to accomplish, and why. Laura -- https://mail.python.org/mailman/listinfo/python-list