Support for Windows 7 ?
timr at probo.com
Sat Sep 5 23:02:25 CEST 2009
Pascale Mourier <Pascale.Mourier at ecp.fr> wrote:
>YES IT IS! Sorry for the inconvenience. I usually start from this
>assumption. Yesterday this new student was really agressive, and I
>assumed he was right!
>Here's his mistake: with Windows the name of the directory rooted at a
>drive name (say C:) is called 'C:\' not 'C:', and it's been that way for
The root of drive C: is, indeed, spelled "C:\". However, the spelling "C:"
has a well-defined meaning, and it has since MS-DOS 2 when directories were
introduced. It means "the current directory for C:".
>Well, os.listdir('C:') instead of raising an exception, for some reason
>behaves like os.listdir('.').
Because it's not an exception. The meaning is well-defined. This can be
very handy, for example, when copying between deeply nested paths on
cd "\Ridiculous\Long\Path\Names\For Annoyance"
copy C:one.txt D:two.txt
Tim Roberts, timr at probo.com
Providenza & Boekelheide, Inc.
More information about the Python-list