summaryrefslogtreecommitdiff
path: root/Utility
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2014-03-30 18:43:05 -0400
committerGravatar Joey Hess <joey@kitenet.net>2014-03-30 18:43:05 -0400
commit1eeae9ed574ee4b256f20bac8397dc9184b5e4e1 (patch)
tree68b7485e519ac81e8d5e88ea6670023d87234d4f /Utility
parentba6b1b81b7e0c27b9b4967b178c861aa3cd37946 (diff)
avoid importing Common
it caused a loop when reusing this in propellor
Diffstat (limited to 'Utility')
-rw-r--r--Utility/FileMode.hs6
1 files changed, 4 insertions, 2 deletions
diff --git a/Utility/FileMode.hs b/Utility/FileMode.hs
index d8fb866ae..26692b3ba 100644
--- a/Utility/FileMode.hs
+++ b/Utility/FileMode.hs
@@ -9,8 +9,8 @@
module Utility.FileMode where
-import Common
-
+import System.IO
+import Control.Monad
import Control.Exception (bracket)
import System.PosixCompat.Types
#ifndef mingw32_HOST_OS
@@ -18,6 +18,8 @@ import System.Posix.Files
#endif
import Foreign (complement)
+import Utility.Exception
+
{- Applies a conversion function to a file's mode. -}
modifyFileMode :: FilePath -> (FileMode -> FileMode) -> IO ()
modifyFileMode f convert = void $ modifyFileMode' f convert