diff options
| author | Joey Hess <joeyh@joeyh.name> | 2015-06-29 16:40:01 -0400 |
|---|---|---|
| committer | Joey Hess <joeyh@joeyh.name> | 2015-06-29 16:40:01 -0400 |
| commit | fc04d0d81df909904fa655372ee005138f3b6ea7 (patch) | |
| tree | 356408138591bfb4f9ae19fa778ef88a7f405257 /src/Propellor/CmdLine.hs | |
| parent | 37a5c05aba1800a8ccf9a98a0bf3abd59ef1d140 (diff) | |
Added --unset to delete a privdata field.
Diffstat (limited to 'src/Propellor/CmdLine.hs')
| -rw-r--r-- | src/Propellor/CmdLine.hs | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/Propellor/CmdLine.hs b/src/Propellor/CmdLine.hs index d29ffbb7..95a633ec 100644 --- a/src/Propellor/CmdLine.hs +++ b/src/Propellor/CmdLine.hs @@ -51,6 +51,7 @@ processCmdLine = go =<< getArgs _ -> Spin <$> mapM hostname ps <*> pure Nothing go ("--add-key":k:[]) = return $ AddKey k go ("--set":f:c:[]) = withprivfield f c Set + go ("--unset":f:c:[]) = withprivfield f c Unset go ("--dump":f:c:[]) = withprivfield f c Dump go ("--edit":f:c:[]) = withprivfield f c Edit go ("--list-fields":[]) = return ListFields @@ -94,6 +95,7 @@ defaultMain hostlist = do go _ (Continue cmdline) = go False cmdline go _ Check = return () go _ (Set field context) = setPrivData field context + go _ (Unset field context) = unsetPrivData field context go _ (Dump field context) = dumpPrivData field context go _ (Edit field context) = editPrivData field context go _ ListFields = listPrivDataFields hostlist |
