diff options
author | Michael Muré <batolettre@gmail.com> | 2022-12-22 23:19:31 +0100 |
---|---|---|
committer | Michael Muré <batolettre@gmail.com> | 2022-12-23 01:41:03 +0100 |
commit | 95911100823b5c809225d664de74ad2d64e91972 (patch) | |
tree | c352848904d82b046646b4074f26b0ce5235fa40 /commands/execenv/env.go | |
parent | d65e8837aa7bb1a6abb6892b9f2664e1b7edb02e (diff) | |
download | git-bug-95911100823b5c809225d664de74ad2d64e91972.tar.gz |
cache: fix some bugs after refactor
Diffstat (limited to 'commands/execenv/env.go')
-rw-r--r-- | commands/execenv/env.go | 24 |
1 files changed, 11 insertions, 13 deletions
diff --git a/commands/execenv/env.go b/commands/execenv/env.go index 0813ab7e..4c6ce204 100644 --- a/commands/execenv/env.go +++ b/commands/execenv/env.go @@ -136,19 +136,17 @@ func LoadBackend(env *Env) func(*cobra.Command, []string) error { if events != nil { env.Err.Println("Building cache... ") - } - - for event := range events { - if event.Err != nil { - env.Err.Printf("Cache building error [%s]: %v\n", event.Typename, event.Err) - continue - } - - switch event.Event { - case cache.BuildEventStarted: - env.Err.Printf("[%s] started\n", event.Typename) - case cache.BuildEventFinished: - env.Err.Printf("[%s] done\n", event.Typename) + for event := range events { + if event.Err != nil { + env.Err.Printf("Cache building error [%s]: %v\n", event.Typename, event.Err) + continue + } + switch event.Event { + case cache.BuildEventStarted: + env.Err.Printf("[%s] started\n", event.Typename) + case cache.BuildEventFinished: + env.Err.Printf("[%s] done\n", event.Typename) + } } } |