diff --git a/keystore.cabal b/keystore.cabal
--- a/keystore.cabal
+++ b/keystore.cabal
@@ -1,5 +1,5 @@
 Name:                   keystore
-Version:                0.3.0.0
+Version:                0.3.0.1
 Synopsis:               Managing stores of secret things
 Homepage:               http://github.com/cdornan/keystore
 Author:                 Chris Dornan
diff --git a/src/Data/KeyStore/CLI.hs b/src/Data/KeyStore/CLI.hs
--- a/src/Data/KeyStore/CLI.hs
+++ b/src/Data/KeyStore/CLI.hs
@@ -18,7 +18,7 @@
 
 
 version :: String
-version = "0.3.0.0"
+version = "0.3.0.1"
 
 cli :: IO ()
 cli = parseCLI >>= command Nothing
diff --git a/src/Data/KeyStore/IO.hs b/src/Data/KeyStore/IO.hs
--- a/src/Data/KeyStore/IO.hs
+++ b/src/Data/KeyStore/IO.hs
@@ -80,7 +80,7 @@
 import           Text.Printf
 import           Control.Applicative
 import qualified Control.Exception              as X
-import           Control.Lens
+import qualified Control.Lens                   as L
 import           Control.Monad
 import           System.IO
 import           System.Locale
@@ -130,7 +130,7 @@
 updateSettings ic fp =
  do bs   <- LBS.readFile fp
     stgs <- e2io $ settingsFromBytes bs
-    run ic $ modConfig $ over cfg_settings $ const stgs
+    run ic $ modConfig $ L.over cfg_settings $ const stgs
 
 -- | List the triggers set up in the keystore on stdout.
 listTriggers :: IC -> IO ()
@@ -157,11 +157,11 @@
 -- given pattern establishing the settings.
 addTrigger' :: IC -> TriggerID -> Pattern -> Settings -> IO ()
 addTrigger' ic tid pat stgs =
-    run ic $ modConfig $ over cfg_triggers $ Map.insert tid $ Trigger tid pat stgs
+    run ic $ modConfig $ L.over cfg_triggers $ Map.insert tid $ Trigger tid pat stgs
 
 -- | Remove the named trigger from the keystore.
 rmvTrigger :: IC -> TriggerID -> IO ()
-rmvTrigger ic tid = run ic $ modConfig $ over cfg_triggers $ Map.delete tid
+rmvTrigger ic tid = run ic $ modConfig $ L.over cfg_triggers $ Map.delete tid
 
 -- | Create an RSA key pair, encoding the private key in the named Safeguards.
 createRSAKeyPair :: IC -> Name -> Comment -> Identity -> [Safeguard] -> IO ()
diff --git a/src/Data/KeyStore/KS.hs b/src/Data/KeyStore/KS.hs
--- a/src/Data/KeyStore/KS.hs
+++ b/src/Data/KeyStore/KS.hs
@@ -49,7 +49,7 @@
 import           Data.Time
 import           Text.Printf
 import           Control.Applicative
-import           Control.Lens
+import qualified Control.Lens                   as L
 import           Control.Monad
 
 
@@ -272,7 +272,7 @@
                  Just ek -> return ek
         ecd <- saveKS ek ct
         let ec = ec0 { _ec_secret_data = ecd }
-        insertKey $ over key_secret_copies (Map.insert sg ec) key
+        insertKey $ L.over key_secret_copies (Map.insert sg ec) key
 
 
 -------------------------------------------------------------------------------
diff --git a/src/Data/KeyStore/KS/Opt.hs b/src/Data/KeyStore/KS/Opt.hs
--- a/src/Data/KeyStore/KS/Opt.hs
+++ b/src/Data/KeyStore/KS/Opt.hs
@@ -216,14 +216,14 @@
         { opt_enum    = ce
         , opt_default = x0
         , opt_from    = frm
-        , opt_to      = Number . I . toInteger . prj
+        , opt_to      = toJSON . prj
         , opt_help    = Help hp "<integer>"
         }
   where
     frm v =
-        case v of
-          Number (I i) -> inj $ fromInteger i
-          _            -> x0
+        case fromJSON v of
+          Success i -> inj i
+          Error   _ -> x0
 
 text_opt :: [T.Text] -> (T.Text->a,a->T.Text) -> a -> OptEnum -> Opt a
 text_opt hp (inj,prj) x0 ce =
