Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #5545

Re: Deleting a file?

From Ben Finney <ben+python@benfinney.id.au>
Newsgroups comp.lang.python
Subject Re: Deleting a file?
References <iqsdtn$va2$1@speranza.aioe.org>
Date 2011-05-17 11:39 +1000
Message-ID <878vu6f6li.fsf@benfinney.id.au> (permalink)
Organization Unlimited download news at news.astraweb.com

Show all headers | View raw


"garyr" <garyr@fidalgo.net> writes:

> A file can be deleted by opening it with mode os.O_TEMPORARY and then 
> closing it.

Much simpler: ‘os.remove(path)’.

> How can a file be moved to the Recycle Bin, a la Windows?

That's not deleting it (as you probably know), so you might better
change the subject field for the thread.

-- 
 \     “Unix is an operating system, OS/2 is half an operating system, |
  `\    Windows is a shell, and DOS is a boot partition virus.” —Peter |
_o__)                                                        H. Coffin |
Ben Finney

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Deleting a file? "garyr" <garyr@fidalgo.net> - 2011-05-16 14:23 -0700
  Re: Deleting a file? Ben Finney <ben+python@benfinney.id.au> - 2011-05-17 11:39 +1000
  Re: Deleting a file? Jerry Hill <malaclypse2@gmail.com> - 2011-05-16 23:06 -0400
    Re: Deleting a file? "garyr" <garyr@fidalgo.net> - 2011-05-17 07:43 -0700

csiph-web