mirror of
https://github.com/containers/podman.git
synced 2025-10-19 04:03:23 +08:00
Print the Buildah comment from commit to given writer
Much better than unconditionally dumping to stdout Signed-off-by: Matthew Heon <matthew.heon@gmail.com> Closes: #706 Approved by: rhatdan
This commit is contained in:
@ -2,6 +2,7 @@ package libpod
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
|
"fmt"
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
is "github.com/containers/image/storage"
|
is "github.com/containers/image/storage"
|
||||||
@ -142,5 +143,6 @@ func (c *Container) Commit(ctx context.Context, destImage string, options Contai
|
|||||||
if err = importBuilder.Commit(ctx, imageRef, commitOptions); err != nil {
|
if err = importBuilder.Commit(ctx, imageRef, commitOptions); err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
|
fmt.Fprintf(commitOptions.ReportWriter, importBuilder.Comment())
|
||||||
return c.runtime.imageRuntime.NewFromLocal(imageRef.DockerReference().String())
|
return c.runtime.imageRuntime.NewFromLocal(imageRef.DockerReference().String())
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user