/proc filesystem does not exist on MS windows.
If you want to stick to built-in stuff in Python, you'll have to make to with what you can find from the os and platform modules.
Alternatively, you can use the built-in ctypes module to call functions from MS windows'
Kernel32.dll. That way you can extract equivalent information, if available. It would probably be wise to encapsulate this platform specific stuff in a utility module. That would either read
/proc files or call
Kernel32.dll functions depending on the value of e.g
For finding information about disks and volumes (windows-speak for filesystems) look at MS info about local filesystems.
I'd say you could start with GetLogicalDriveStrings, then GetVolumeInformation. Then use other volume management functions.
This is an example of using ctypes. I don't have a windows machine available to test it, though. According to the docs, the prototype for GetLogicalDriveStrings is:
DWORD WINAPI GetLogicalDriveStrings(
_In_ DWORD nBufferLength,
_Out_ LPTSTR lpBuffer
DWORD is a 32-bit unsigned int. It depends on the platform, but this is usally made with
c_uint in ctypes. An LPTSTR is a pointer to a memory area to store stuff. We can use
create_string_buffer to make that. It should work something like this
blen = ctypes.c_uint(128)
rv = ctypes.c_uint()
bufs = ctypes.create_string_buffer(128)
rv = ctypes.windll.kernel32.GetLogicalDriveStrings(blen, bufs)
if rv.value == 0:
raise ValueError('GetLogicalDriveStrings returned 0.')
drives = bufs.raw.split('\0')
drvstring = ' '.join(drives)
drives should now reference a list of drive names.