Commit 6a981346 authored by Mitchell Hashimoto's avatar Mitchell Hashimoto

command/build: Use PrefixedUi for each build

parent 2c4a873a
package build package build
import ( import (
"fmt"
"github.com/mitchellh/packer/packer" "github.com/mitchellh/packer/packer"
"io/ioutil" "io/ioutil"
"log" "log"
...@@ -51,6 +52,15 @@ func (Command) Run(env packer.Environment, args []string) int { ...@@ -51,6 +52,15 @@ func (Command) Run(env packer.Environment, args []string) int {
builds = append(builds, build) builds = append(builds, build)
} }
// Compile all the UIs for the builds
buildUis := make(map[string]packer.Ui)
for _, b := range builds {
buildUis[b.Name()] = &packer.PrefixedUi{
fmt.Sprintf("==> %s", b.Name()),
env.Ui(),
}
}
// Prepare all the builds // Prepare all the builds
for _, b := range builds { for _, b := range builds {
log.Printf("Preparing build: %s\n", b.Name()) log.Printf("Preparing build: %s\n", b.Name())
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment