Pythonic way to overwrite a file
Rhodri James
rhodri at wildebst.demon.co.uk
Wed Jun 17 18:58:25 EDT 2009
Top-posting, tsk, tsk.
On Wed, 17 Jun 2009 19:26:07 +0100, Cameron Pulsford
<cameron.pulsford at gmail.com> wrote:
> Essentially it just cleans up a source file of erroneous spaces and tabs
> and
> can also convert tabs to spaces so loading the whole file into memory is
> possibly an option. I am making this utility for personal use, and that
> would definitely be fine,
[snip]
You won't say that the first time it screws up and destroys one of your
files. Making in-place changes is something that should set big red
lights flashing in software engineering terms. You don't want to get
into the habit of doing that, especially for personal use.
--
Rhodri James *-* Wildebeest Herder to the Masses
More information about the Python-list
mailing list