concurrency and status messages when downloading from import

This commit is contained in:
Joey Hess 2019-03-08 12:33:44 -04:00
parent ee5f1422df
commit e412129523
No known key found for this signature in database
GPG key ID: DB12DB0FF05F8F38
10 changed files with 57 additions and 27 deletions

View file

@ -261,7 +261,7 @@ seekRemote remote branch msubdir = allowConcurrentOutput $ do
parentcommit <- fromtrackingbranch Git.Ref.sha
let importcommitconfig = ImportCommitConfig parentcommit ManualCommit importmessage
importable <- download importtreeconfig =<< enumerate
importable <- download importtreeconfig =<< listcontents
void $ includeCommandAction $
commitRemote remote branch tb parentcommit importtreeconfig importcommitconfig importable
where
@ -271,8 +271,8 @@ seekRemote remote branch msubdir = allowConcurrentOutput $ do
fromtrackingbranch a = inRepo $ a (fromRemoteTrackingBranch tb)
enumerate = do
showStart' "import" (Just (Remote.name remote))
listcontents = do
showStart' "list" (Just (Remote.name remote))
Remote.listImportableContents (Remote.importActions remote) >>= \case
Nothing -> do
showEndFail