summaryrefslogtreecommitdiff
path: root/Command
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2012-07-27 21:05:34 -0400
committerGravatar Joey Hess <joey@kitenet.net>2012-07-27 21:05:34 -0400
commit0a66947e3b8532b902ee5969c5659fe0fd42272c (patch)
tree0798bd7830cc51e9cacd3a1e00b5172bb7e0a532 /Command
parentc0ca6f44ac2cbe6d1cbb82bc73e2d2ead7695770 (diff)
parent13e9b275dd96673e5a3421b64d672abdd29e9a26 (diff)
Merge branch 'master' into assistant
Diffstat (limited to 'Command')
-rw-r--r--Command/InitRemote.hs14
1 files changed, 7 insertions, 7 deletions
diff --git a/Command/InitRemote.hs b/Command/InitRemote.hs
index a78505a19..ad93529cc 100644
--- a/Command/InitRemote.hs
+++ b/Command/InitRemote.hs
@@ -38,18 +38,19 @@ start (name:ws) = do
t <- findType fullconfig
showStart "initremote" name
- next $ perform t u $ M.union config c
+ next $ perform t u name $ M.union config c
where
config = Logs.Remote.keyValToConfig ws
-perform :: RemoteType -> UUID -> R.RemoteConfig -> CommandPerform
-perform t u c = do
+perform :: RemoteType -> UUID -> String -> R.RemoteConfig -> CommandPerform
+perform t u name c = do
c' <- R.setup t u c
- next $ cleanup u c'
+ next $ cleanup u name c'
-cleanup :: UUID -> R.RemoteConfig -> CommandCleanup
-cleanup u c = do
+cleanup :: UUID -> String -> R.RemoteConfig -> CommandCleanup
+cleanup u name c = do
+ describeUUID u name
Logs.Remote.configSet u c
return True
@@ -61,7 +62,6 @@ findByName name = do
where
generate = do
uuid <- liftIO genUUID
- describeUUID uuid name
return (uuid, M.insert nameKey name M.empty)
findByName' :: String -> M.Map UUID R.RemoteConfig -> Maybe (UUID, R.RemoteConfig)