--force was a needless duplicate of --strict

This commit is contained in:
John Wiegley 2018-05-09 13:52:34 -07:00
parent e9006ff98b
commit b186e44174
No known key found for this signature in database
GPG key ID: C144D8F4F19FE630
4 changed files with 2 additions and 7 deletions

View file

@ -144,7 +144,7 @@ main = do
. A.encodingToLazyByteString
. toEncodingSorted
<=< fromNix
| normalize opts =
| strict opts =
liftIO . print . prettyNValueNF <=< normalForm
| values opts =
liftIO . print <=< prettyNValueProv

View file

@ -103,7 +103,7 @@ exec update source = do
go expr = do
val <- evalExprLoc expr
opts :: Nix.Options <- asks (view hasLens)
if | normalize opts ->
if | strict opts ->
liftIO . print . prettyNValueNF =<< normalForm val
| values opts ->
liftIO . print =<< prettyNValueProv val

View file

@ -16,7 +16,6 @@ data Options = Options
, finder :: Bool
, findFile :: Maybe FilePath
, strict :: Bool
, normalize :: Bool
, evaluate :: Bool
, json :: Bool
, xml :: Bool
@ -50,7 +49,6 @@ defaultOptions current = Options
, finder = False
, findFile = Nothing
, strict = False
, normalize = False
, evaluate = False
, json = False
, xml = False

View file

@ -69,9 +69,6 @@ nixOptions current = Options
<*> switch
( long "strict"
<> help "When used with --eval, recursively evaluate list elements and attributes")
<*> switch
( long "force"
<> help "Whether to force the results of evaluation to normal form")
<*> switch
( long "eval"
<> help "Whether to evaluate, or just pretty-print")