From b3e761b6cf42cb537e7e8e8db4d74b12c7dbfd8a Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Sun, 11 Oct 2015 13:29:44 -0400 Subject: use action, not sideAction sideAction is for things not generally related to the current action being performed. And, it adds a newline after the side action. This was not the right thing to use for stuff like "checksum", where doing a checksum is part of the git annex get process, and indeed we want it to display "(checksum...) ok" --- Annex/Init.hs | 2 +- Backend/Hash.hs | 2 +- Command/ImportFeed.hs | 2 +- Command/TestRemote.hs | 2 +- Command/View.hs | 2 +- Remote/WebDAV.hs | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Annex/Init.hs b/Annex/Init.hs index 26502511e..03915904e 100644 --- a/Annex/Init.hs +++ b/Annex/Init.hs @@ -209,7 +209,7 @@ checkSharedClone = inRepo Git.Objects.isSharedClone initSharedClone :: Bool -> Annex () initSharedClone False = return () initSharedClone True = do - showSideAction "Repository was cloned with --shared; setting annex.hardlink=true and making repository untrusted." + showLongNote "Repository was cloned with --shared; setting annex.hardlink=true and making repository untrusted." u <- getUUID trustSet u UnTrusted setConfig (annexConfig "hardlink") (Git.Config.boolConfig True) diff --git a/Backend/Hash.hs b/Backend/Hash.hs index e6e5210a1..7f61c4f3e 100644 --- a/Backend/Hash.hs +++ b/Backend/Hash.hs @@ -116,7 +116,7 @@ checkKeyChecksum hash key file = go `catchHardwareFault` hwfault case (mstat, fast) of (Just stat, False) -> do filesize <- liftIO $ getFileSize' file stat - showSideAction "checksum" + showAction "checksum" check <$> hashFile hash file filesize _ -> return True expected = keyHash key diff --git a/Command/ImportFeed.hs b/Command/ImportFeed.hs index 647cd269e..2db6e608a 100644 --- a/Command/ImportFeed.hs +++ b/Command/ImportFeed.hs @@ -115,7 +115,7 @@ getCache :: Maybe String -> Annex Cache getCache opttemplate = ifM (Annex.getState Annex.force) ( ret S.empty S.empty , do - showSideAction "checking known urls" + showAction "checking known urls" (is, us) <- unzip <$> (mapM knownItems =<< knownUrls) ret (S.fromList us) (S.fromList (concat is)) ) diff --git a/Command/TestRemote.hs b/Command/TestRemote.hs index be1b9a324..f66a77ba7 100644 --- a/Command/TestRemote.hs +++ b/Command/TestRemote.hs @@ -63,7 +63,7 @@ start :: Int -> RemoteName -> CommandStart start basesz name = do showStart "testremote" name r <- either error id <$> Remote.byName' name - showSideAction "generating test keys" + showAction "generating test keys" fast <- Annex.getState Annex.fast ks <- mapM randKey (keySizes basesz fast) rs <- catMaybes <$> mapM (adjustChunkSize r) (chunkSizes basesz fast) diff --git a/Command/View.hs b/Command/View.hs index b39aef7d9..3fdbbb9c5 100644 --- a/Command/View.hs +++ b/Command/View.hs @@ -39,7 +39,7 @@ start ps = do perform :: View -> CommandPerform perform view = do - showSideAction "searching" + showAction "searching" next $ checkoutViewBranch view applyView paramView :: String diff --git a/Remote/WebDAV.hs b/Remote/WebDAV.hs index 7f4173d03..4c5edef72 100644 --- a/Remote/WebDAV.hs +++ b/Remote/WebDAV.hs @@ -185,7 +185,7 @@ toDavPass = B8.fromString -} testDav :: URLString -> Maybe CredPair -> Annex () testDav url (Just (u, p)) = do - showSideAction "testing WebDAV server" + showAction "testing WebDAV server" test $ liftIO $ evalDAVT url $ do prepDAV user pass makeParentDirs -- cgit v1.2.3