diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/Propellor/Property/EtcDefault.hs | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/Propellor/Property/EtcDefault.hs b/src/Propellor/Property/EtcDefault.hs new file mode 100644 index 00000000..0bda5c64 --- /dev/null +++ b/src/Propellor/Property/EtcDefault.hs @@ -0,0 +1,17 @@ +-- | Maintainer: Sean Whitton <spwhitton@spwhitton.name> + +module Propellor.Property.EtcDefault ( + EtcDefaultFile, + set, +) where + +import Propellor.Base +import Propellor.Property.ConfFile + +-- | The name of a file in </etc/default>, without the </etc/default> prefix. +-- E.g. @useradd@. +type EtcDefaultFile = String + +-- | Set a key=value pair in a file in </etc/default>. +set :: EtcDefaultFile -> ShellKey -> String -> Property UnixLike +set f key value = containsShellSetting ("/etc/default" </> f) (key, value) |
