rsync special remote: Stop displaying rsync progress, and use git-annex's own progress display
Reasons are same as in commit cee14f147a.
(It was already done when using -J.)
Sponsored-by: Mark Reidenbach on Patreon
	
	
This commit is contained in:
		
					parent
					
						
							
								c5abe37141
							
						
					
				
			
			
				commit
				
					
						f1176f82a5
					
				
			
		
					 2 changed files with 4 additions and 6 deletions
				
			
		| 
						 | 
				
			
			@ -6,6 +6,8 @@ git-annex (8.20210804) UNRELEASED; urgency=medium
 | 
			
		|||
    rather than needing to be advanced each time a new change is made.
 | 
			
		||||
  * Misuse of GIT_ANNEX_VECTOR_CLOCK will no longer confuse git-annex.
 | 
			
		||||
  * add: When adding a dotfile, avoid treating its name as an extension.
 | 
			
		||||
  * rsync special remote: Stop displaying rsync progress, and use
 | 
			
		||||
    git-annex's own progress display.
 | 
			
		||||
 | 
			
		||||
 -- Joey Hess <id@joeyh.name>  Tue, 03 Aug 2021 12:22:45 -0400
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -76,10 +76,7 @@ gen r u rc gc rs = do
 | 
			
		|||
		fromMaybe (giveup "missing rsyncurl") $ remoteAnnexRsyncUrl gc
 | 
			
		||||
	let o = genRsyncOpts c gc transport url
 | 
			
		||||
	let islocal = rsyncUrlIsPath $ rsyncUrl o
 | 
			
		||||
	let specialcfg = (specialRemoteCfg c)
 | 
			
		||||
		-- Rsync displays its own progress.
 | 
			
		||||
		{ displayProgress = False }
 | 
			
		||||
	return $ Just $ specialRemote' specialcfg c
 | 
			
		||||
	return $ Just $ specialRemote' (specialRemoteCfg c) c
 | 
			
		||||
		(fileStorer $ store o)
 | 
			
		||||
		(fileRetriever $ retrieve o)
 | 
			
		||||
		(remove o)
 | 
			
		||||
| 
						 | 
				
			
			@ -381,13 +378,12 @@ showResumable a = ifM a
 | 
			
		|||
 | 
			
		||||
rsyncRemote :: Direction -> RsyncOpts -> Maybe MeterUpdate -> [CommandParam] -> Annex Bool
 | 
			
		||||
rsyncRemote direction o m params = do
 | 
			
		||||
	showOutput -- make way for progress bar
 | 
			
		||||
	opts <- mkopts
 | 
			
		||||
	let ps = opts ++ Param "--progress" : params
 | 
			
		||||
	case m of
 | 
			
		||||
		Nothing -> liftIO $ rsync ps
 | 
			
		||||
		Just meter -> do
 | 
			
		||||
			oh <- mkOutputHandler
 | 
			
		||||
			oh <- mkOutputHandlerQuiet
 | 
			
		||||
			liftIO $ rsyncProgress oh meter ps
 | 
			
		||||
  where
 | 
			
		||||
	mkopts
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue