first pass at using new keys
It compiles. It sorta works. Several subcommands are FIXME marked and broken, because things that used to accept separate --backend and --key params need to be changed to accept just a --key that encodes all the key info, now that there is metadata in keys.
This commit is contained in:
parent
675ee89749
commit
9d49fe2c17
20 changed files with 116 additions and 123 deletions
|
@ -11,9 +11,10 @@ import Control.Monad.State (liftIO)
|
|||
import System.Exit
|
||||
|
||||
import Command
|
||||
import Types
|
||||
import Content
|
||||
import qualified Backend
|
||||
import qualified BackendTypes
|
||||
import Key
|
||||
|
||||
command :: [Command]
|
||||
command = [Command "inannex" (paramRepeating paramKey) seek
|
||||
|
@ -25,7 +26,11 @@ seek = [withKeys start]
|
|||
start :: CommandStartString
|
||||
start keyname = do
|
||||
backends <- Backend.list
|
||||
let key = genKey (head backends) keyname
|
||||
let key = stubKey {
|
||||
keyName = keyname,
|
||||
keyBackendName = BackendTypes.name (head backends)
|
||||
}
|
||||
error "BROKEN. fixme!"
|
||||
present <- inAnnex key
|
||||
if present
|
||||
then return Nothing
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue