diff options
| author | Joey Hess <joeyh@joeyh.name> | 2015-10-20 15:43:44 -0400 |
|---|---|---|
| committer | Joey Hess <joeyh@joeyh.name> | 2015-10-20 15:43:44 -0400 |
| commit | f66fdc8effe90d801d26604d36c01838488545b3 (patch) | |
| tree | 6590460fd63fcd56503e53d5f967e1a8824071cd /src/Propellor/PrivData.hs | |
| parent | 9c48a095a4ce1ddd309644338b8b11049f19d719 (diff) | |
| parent | eeabdf5e30d5b5f88788151e1f0231d8ea562562 (diff) | |
Merge branch 'joeyconfig'
Diffstat (limited to 'src/Propellor/PrivData.hs')
| -rw-r--r-- | src/Propellor/PrivData.hs | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/Propellor/PrivData.hs b/src/Propellor/PrivData.hs index fd790878..070070f0 100644 --- a/src/Propellor/PrivData.hs +++ b/src/Propellor/PrivData.hs @@ -16,6 +16,7 @@ module Propellor.PrivData ( listPrivDataFields, makePrivDataDir, decryptPrivData, + readPrivData, PrivMap, PrivInfo, forceHostContext, @@ -248,7 +249,10 @@ modifyPrivData' f = do return r decryptPrivData :: IO PrivMap -decryptPrivData = fromMaybe M.empty . readish <$> gpgDecrypt privDataFile +decryptPrivData = readPrivData <$> gpgDecrypt privDataFile + +readPrivData :: String -> PrivMap +readPrivData = fromMaybe M.empty . readish makePrivDataDir :: IO () makePrivDataDir = createDirectoryIfMissing False privDataDir |
