diff options
author | Brent Baude <bbaude@redhat.com> | 2020-06-26 16:22:04 -0500 |
---|---|---|
committer | Brent Baude <bbaude@redhat.com> | 2020-06-29 09:17:55 -0500 |
commit | dfb2f92583a5797b1ee8cdf29399dc29b7f3c6d3 (patch) | |
tree | ec6c2dbb56530638989a318321a264e39b21c2b5 /cmd/podman | |
parent | 771c887010709cdf718be252ca91a852c6735da7 (diff) | |
download | podman-dfb2f92583a5797b1ee8cdf29399dc29b7f3c6d3.tar.gz podman-dfb2f92583a5797b1ee8cdf29399dc29b7f3c6d3.tar.bz2 podman-dfb2f92583a5797b1ee8cdf29399dc29b7f3c6d3.zip |
Set console mode for windows
Windows terminal handling is different than darwin and linux. It needs to have the terminal mode set to enable virtual terminal processing. This allows colors and other things to work.
Signed-off-by: Brent Baude <bbaude@redhat.com>
Diffstat (limited to 'cmd/podman')
-rw-r--r-- | cmd/podman/main.go | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/cmd/podman/main.go b/cmd/podman/main.go index f502e7a67..7a015b300 100644 --- a/cmd/podman/main.go +++ b/cmd/podman/main.go @@ -16,7 +16,9 @@ import ( _ "github.com/containers/libpod/cmd/podman/system" _ "github.com/containers/libpod/cmd/podman/volumes" "github.com/containers/libpod/pkg/rootless" + "github.com/containers/libpod/pkg/terminal" "github.com/containers/storage/pkg/reexec" + "github.com/sirupsen/logrus" "github.com/spf13/cobra" ) @@ -53,6 +55,10 @@ func main() { } } } + if err := terminal.SetConsole(); err != nil { + logrus.Error(err) + os.Exit(1) + } Execute() os.Exit(0) |