fix lost metering for fallback rsyncs

08814327ff accidentially got rid of it,
when it removed commandMetered.
This commit is contained in:
Joey Hess 2018-03-12 17:56:39 -04:00
parent abe8346dca
commit cb05ef06bf
No known key found for this signature in database
GPG key ID: DB12DB0FF05F8F38
3 changed files with 27 additions and 19 deletions

View file

@ -85,12 +85,11 @@ meteredFile file combinemeterupdate key a =
then metered combinemeterupdate key (return Nothing) $ \p ->
watchFileSize file p a
else a
needOutputMeter :: MessageState -> Bool
needOutputMeter s = case outputType s of
JSONOutput jsonoptions -> jsonProgress jsonoptions
NormalOutput | concurrentOutputEnabled s -> True
_ -> False
where
needOutputMeter s = case outputType s of
JSONOutput jsonoptions -> jsonProgress jsonoptions
NormalOutput | concurrentOutputEnabled s -> True
_ -> False
{- Progress dots. -}
showProgressDots :: Annex ()
@ -117,6 +116,11 @@ mkOutputHandler = OutputHandler
<$> commandProgressDisabled
<*> mkStderrEmitter
mkOutputHandlerQuiet :: Annex OutputHandler
mkOutputHandlerQuiet = OutputHandler
<$> pure True
<*> mkStderrEmitter
mkStderrRelayer :: Annex (Handle -> IO ())
mkStderrRelayer = do
quiet <- commandProgressDisabled