mirror of
https://github.com/mudler/luet.git
synced 2025-09-20 10:46:16 +00:00
⬆️ Bump helm.sh/helm/v3 from 3.3.4 to 3.6.1 (#280)
Bumps [helm.sh/helm/v3](https://github.com/helm/helm) from 3.3.4 to 3.6.1. - [Release notes](https://github.com/helm/helm/releases) - [Commits](https://github.com/helm/helm/compare/v3.3.4...v3.6.1) --- updated-dependencies: - dependency-name: helm.sh/helm/v3 dependency-type: direct:production ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
This commit is contained in:
16
vendor/github.com/moby/term/windows/console.go
generated
vendored
16
vendor/github.com/moby/term/windows/console.go
generated
vendored
@@ -1,11 +1,11 @@
|
||||
// +build windows
|
||||
|
||||
package windowsconsole // import "github.com/moby/term/windows"
|
||||
package windowsconsole
|
||||
|
||||
import (
|
||||
"os"
|
||||
|
||||
"github.com/Azure/go-ansiterm/winterm"
|
||||
"golang.org/x/sys/windows"
|
||||
)
|
||||
|
||||
// GetHandleInfo returns file descriptor and bool indicating whether the file is a console.
|
||||
@@ -22,14 +22,18 @@ func GetHandleInfo(in interface{}) (uintptr, bool) {
|
||||
|
||||
if file, ok := in.(*os.File); ok {
|
||||
inFd = file.Fd()
|
||||
isTerminal = IsConsole(inFd)
|
||||
isTerminal = isConsole(inFd)
|
||||
}
|
||||
return inFd, isTerminal
|
||||
}
|
||||
|
||||
// IsConsole returns true if the given file descriptor is a Windows Console.
|
||||
// The code assumes that GetConsoleMode will return an error for file descriptors that are not a console.
|
||||
func IsConsole(fd uintptr) bool {
|
||||
_, e := winterm.GetConsoleMode(fd)
|
||||
return e == nil
|
||||
// Deprecated: use golang.org/x/sys/windows.GetConsoleMode() or golang.org/x/term.IsTerminal()
|
||||
var IsConsole = isConsole
|
||||
|
||||
func isConsole(fd uintptr) bool {
|
||||
var mode uint32
|
||||
err := windows.GetConsoleMode(windows.Handle(fd), &mode)
|
||||
return err == nil
|
||||
}
|
||||
|
Reference in New Issue
Block a user