From 479045277b29919797cee341b11d30bbd15ab3d7 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Sun, 13 Apr 2014 12:21:43 -0400 Subject: propellor spin --- Propellor/Property/File.hs | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'Propellor/Property/File.hs') diff --git a/Propellor/Property/File.hs b/Propellor/Property/File.hs index d8caf366..bd33c9b8 100644 --- a/Propellor/Property/File.hs +++ b/Propellor/Property/File.hs @@ -24,6 +24,11 @@ hasPrivContent f = Property desc $ withPrivData (PrivFile f) $ \privcontent -> where desc = "privcontent " ++ f +-- | Leaves the file world-readable. +hasPrivContentExposed :: FilePath -> Property +hasPrivContentExposed f = hasPrivContent f `onChange` + mode f (combineModes (ownerWriteMode:readModes)) + -- | Ensures that a line is present in a file, adding it to the end if not. containsLine :: FilePath -> Line -> Property f `containsLine` l = fileProperty (f ++ " contains:" ++ l) go f -- cgit v1.3-2-g0d8e