how to determine if files are on same or different file systems
Christos TZOTZIOY Georgiou
tzot at sil-tec.gr
Tue Dec 9 07:51:16 EST 2003
On Sat, 06 Dec 2003 17:15:42 -0500, rumours say that Kamus of Kadizhar
<yan at NsOeSiPnAeMr.com> might have written:
>It would be nice if I could write a function that would determine if the
>source and destination are on the same file system or not, and thus use
>rename or copy appropriately, or if there is already such a built-in
>function.
The os.stat call result has a st_dev (the device) field that could be
very useful to you. It works for Windows too, where you can use extra
calls from win32api or win32file, can't remember which to know the file
system type too.
--
TZOTZIOY, I speak England very best,
Ils sont fous ces Redmontains! --Harddix
More information about the Python-list
mailing list