diff options
author | Joey Hess <joey@kitenet.net> | 2013-03-05 15:39:42 -0400 |
---|---|---|
committer | Joey Hess <joey@kitenet.net> | 2013-03-05 15:43:56 -0400 |
commit | 5c46685ab3bc1f579e55d764d5887b7f4a208d65 (patch) | |
tree | 7bb19dd15cea25d8c3617e4a3e12e92c1a28ab64 /Assistant | |
parent | 349da7cd84ab7b5d4b602bc3ab51e3a548a1633a (diff) |
two types of byName
Clean up from 5123a1a83aa3b954fe67629508bab5ccea0e4148.
In some cases, looking up a remote by name even though it has no UUID is
desirable. This includes git annex sync, which can operate on remotes
without an annex, and XMPP pairing, which runs addRemote (with calls
byName) before the UUID of the XMPP remote has been configured in git.
Diffstat (limited to 'Assistant')
-rw-r--r-- | Assistant/MakeRemote.hs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/Assistant/MakeRemote.hs b/Assistant/MakeRemote.hs index b01b051f6..113018363 100644 --- a/Assistant/MakeRemote.hs +++ b/Assistant/MakeRemote.hs @@ -52,7 +52,8 @@ addRemote :: Annex String -> Annex Remote addRemote a = do name <- a void remoteListRefresh - maybe (error "failed to add remote") return =<< Remote.byName (Just name) + maybe (error "failed to add remote") return + =<< Remote.byName (Just name) {- Inits a rsync special remote, and returns its name. -} makeRsyncRemote :: String -> String -> Annex String |