diff options
| author | Joey Hess <joeyh@joeyh.name> | 2017-02-26 16:24:04 -0400 |
|---|---|---|
| committer | Joey Hess <joeyh@joeyh.name> | 2017-02-26 16:24:04 -0400 |
| commit | 01b313e06b3010ebe1a9385b7779dc49a7ebf74c (patch) | |
| tree | 7f263f36599f4c0dd7aad7f0bae146c8f936d51a | |
| parent | 16f42138605ebd7466c29a582d91fbd0c1df5c70 (diff) | |
ConfigurableValue instances for User, Group
| -rw-r--r-- | src/Propellor/Types/OS.hs | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/Propellor/Types/OS.hs b/src/Propellor/Types/OS.hs index 8d7f1ba3..41f839f1 100644 --- a/src/Propellor/Types/OS.hs +++ b/src/Propellor/Types/OS.hs @@ -142,9 +142,15 @@ type UserName = String newtype User = User UserName deriving (Eq, Ord, Show) +instance ConfigurableValue User where + val (User n) = n + newtype Group = Group String deriving (Eq, Ord, Show) +instance ConfigurableValue Group where + val (Group n) = n + -- | Makes a Group with the same name as the User. userGroup :: User -> Group userGroup (User u) = Group u |
