[Haskell-cafe] listing mountpoints and getting their properties in Haskell

Brandon S. Allbery KF8NH allbery at ece.cmu.edu
Sat Feb 27 18:27:19 EST 2010

On Feb 27, 2010, at 11:47 , Eugene Dzhurinsky wrote:
> Is there any library capable of obtaining such information from OS  
> itself?
> Parsing output of 'df' is locale-dependent and error-prone (because  
> of locale
> settings, output settings etc).

I don't know of any Haskell bindings offhand, but getmntent() and  
friends are the standard library interface for identifying mountpoints  
and statfs()/statvfs() are the interface for getting information about  
them.  Be aware that the latter can be fairly system-dependent.

brandon s. allbery [solaris,freebsd,perl,pugs,haskell] allbery at kf8nh.com
system administrator [openafs,heimdal,too many hats] allbery at ece.cmu.edu
electrical and computer engineering, carnegie mellon university    KF8NH

-------------- next part --------------
A non-text attachment was scrubbed...
Name: PGP.sig
Type: application/pgp-signature
Size: 195 bytes
Desc: This is a digitally signed message part
Url : http://www.haskell.org/pipermail/haskell-cafe/attachments/20100227/a9aeb185/PGP.bin

More information about the Haskell-Cafe mailing list