Fix display when run with -J1
Commit b6642dde8a
broke it by enabling
non-concurrent display mode while leaving concurrency set in the config
and having already started concurrency earlier.
(I don't actually know if that commit was a good idea.)
Sponsored-By: Brett Eisenberg on Patreon
This commit is contained in:
parent
772d7fa82d
commit
114a2d7504
3 changed files with 9 additions and 5 deletions
|
@ -90,6 +90,7 @@ git-annex (10.20230408) UNRELEASED; urgency=medium
|
||||||
is configured, the same as git-annex add does.
|
is configured, the same as git-annex add does.
|
||||||
* config: Added the --show-origin and --for-file options.
|
* config: Added the --show-origin and --for-file options.
|
||||||
* config: Support annex.numcopies and annex.mincopies.
|
* config: Support annex.numcopies and annex.mincopies.
|
||||||
|
* Fix display when run with -J1.
|
||||||
|
|
||||||
-- Joey Hess <id@joeyh.name> Sat, 08 Apr 2023 13:57:18 -0400
|
-- Joey Hess <id@joeyh.name> Sat, 08 Apr 2023 13:57:18 -0400
|
||||||
|
|
||||||
|
|
|
@ -74,9 +74,7 @@ commandAction start = do
|
||||||
st <- Annex.getState id
|
st <- Annex.getState id
|
||||||
case getConcurrency' (Annex.concurrency st) of
|
case getConcurrency' (Annex.concurrency st) of
|
||||||
NonConcurrent -> runnonconcurrent (Annex.sizelimit st)
|
NonConcurrent -> runnonconcurrent (Annex.sizelimit st)
|
||||||
Concurrent n
|
Concurrent _ -> runconcurrent (Annex.sizelimit st) (Annex.workers st)
|
||||||
| n > 1 -> runconcurrent (Annex.sizelimit st) (Annex.workers st)
|
|
||||||
| otherwise -> runnonconcurrent (Annex.sizelimit st)
|
|
||||||
ConcurrentPerCpu -> runconcurrent (Annex.sizelimit st) (Annex.workers st)
|
ConcurrentPerCpu -> runconcurrent (Annex.sizelimit st) (Annex.workers st)
|
||||||
where
|
where
|
||||||
runnonconcurrent sizelimit = start >>= \case
|
runnonconcurrent sizelimit = start >>= \case
|
||||||
|
@ -235,8 +233,11 @@ startConcurrency usedstages a = do
|
||||||
let usegitcfg = setConcurrency (ConcurrencyGitConfig fromgitcfg)
|
let usegitcfg = setConcurrency (ConcurrencyGitConfig fromgitcfg)
|
||||||
case (fromcmdline, fromgitcfg) of
|
case (fromcmdline, fromgitcfg) of
|
||||||
(NonConcurrent, NonConcurrent) -> a
|
(NonConcurrent, NonConcurrent) -> a
|
||||||
(Concurrent n, _) ->
|
(Concurrent n, _)
|
||||||
goconcurrent n
|
| n > 1 -> goconcurrent n
|
||||||
|
| otherwise -> do
|
||||||
|
setConcurrency' NonConcurrent ConcurrencyCmdLine
|
||||||
|
a
|
||||||
(ConcurrentPerCpu, _) ->
|
(ConcurrentPerCpu, _) ->
|
||||||
goconcurrentpercpu
|
goconcurrentpercpu
|
||||||
(NonConcurrent, Concurrent n) -> do
|
(NonConcurrent, Concurrent n) -> do
|
||||||
|
|
|
@ -9,3 +9,5 @@ The filename is displayed at end.
|
||||||
This does not happen at -J2 or without -J.
|
This does not happen at -J2 or without -J.
|
||||||
|
|
||||||
--[[Joey]]
|
--[[Joey]]
|
||||||
|
|
||||||
|
> [[fixed|done]] --[[Joey]]
|
||||||
|
|
Loading…
Add table
Reference in a new issue