Copyright | © 2013-2014 Nicola Squartini |
---|---|
License | BSD3 |
Maintainer | Nicola Squartini <tensor5@gmail.com> |
Stability | experimental |
Portability | portable |
Safe Haskell | None |
Language | Haskell98 |
This module provides an interface to the system mount and umount functions.
- mount :: String -> FilePath -> String -> [MountFlag] -> DriverData -> IO ()
- umount :: FilePath -> IO ()
- umountWith :: UmountFlag -> Bool -> FilePath -> IO ()
- data MountFlag
- type DriverData = ByteString
- noData :: DriverData
- data UmountFlag
Bindings to system functions
:: String | Device file |
-> FilePath | Mount point |
-> String | Filesystem type |
-> [MountFlag] | List of mount options |
-> DriverData | Driver specific options |
-> IO () |
Mount a filesystem (call to mount()
).
:: UmountFlag | Unmount option |
-> Bool | |
-> FilePath | Mount point |
-> IO () |
Unmount a filesystem using specific unmount options (call to umount2()
).
See
for details.UmountFlag
Mount flags
A filesystem independent option to be used when mounting a filesystem.
Driver data
type DriverData = ByteString Source
Filesystem dependent options to be used when mounting a filesystem; the
content of
is passed directly to the filesystem driver.DriverData
Empty
.DriverData
Unmount flags
data UmountFlag Source
A filesystem independent option to be used when unmounting a filesystem.
Plain | Plain unmount, behaves like |
Force | Force unmount even if busy. |
Detach | Perform a lazy unmount: make the mount point unavailable for new accesses, and actually perform the unmount when the mount point ceases to be busy. |
Expire | Mark the mount point as expired. If a mount point
is not currently in use, then an initial call to
|