[Python-Dev] Drive suffix (original) (raw)
Guido van Rossum guido at python.org
Wed Aug 4 17:10:43 CEST 2010
- Previous message: [Python-Dev] w32 drive separator (was: Drive suffix)
- Next message: [Python-Dev] Drive suffix
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
It's Windows specific syntax and always a colon. Use os.path.splitdrive() to parse it. I don't think there's a need to add a named constant for it (you're the first to ask, in my memory).
On Wed, Aug 4, 2010 at 7:45 AM, Rob Cliffe <rob.cliffe at btinternet.com> wrote:
Is there a way of determining the suffix used after a drive letter to denote a drive, e.g. on Windows the ":" in r"C:\Dir\Subdir\File.Ext" ? Or is the colon so universal that it is considered unnecessary? Should it be in the os module somewhere (as far as I can tell, it isn't, although every other kind of file path component separator seems to be) ?
-- --Guido van Rossum (python.org/~guido)
- Previous message: [Python-Dev] w32 drive separator (was: Drive suffix)
- Next message: [Python-Dev] Drive suffix
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]