mirror of
https://github.com/golang/term.git
synced 2026-02-07 19:26:03 +03:00
Compare commits
13 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
743b2709ab | ||
|
|
40b02d69cd | ||
|
|
442846aa8d | ||
|
|
b725e362a8 | ||
|
|
54df7da90d | ||
|
|
9d5441ab55 | ||
|
|
2f7b0dd743 | ||
|
|
f867b7695b | ||
|
|
d59895469a | ||
|
|
d4346f0be2 | ||
|
|
c976cb1d70 | ||
|
|
5f0bb72315 | ||
|
|
46c790f81f |
4
LICENSE
4
LICENSE
@@ -1,4 +1,4 @@
|
||||
Copyright (c) 2009 The Go Authors. All rights reserved.
|
||||
Copyright 2009 The Go Authors.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions are
|
||||
@@ -10,7 +10,7 @@ notice, this list of conditions and the following disclaimer.
|
||||
copyright notice, this list of conditions and the following disclaimer
|
||||
in the documentation and/or other materials provided with the
|
||||
distribution.
|
||||
* Neither the name of Google Inc. nor the names of its
|
||||
* Neither the name of Google LLC nor the names of its
|
||||
contributors may be used to endorse or promote products derived from
|
||||
this software without specific prior written permission.
|
||||
|
||||
|
||||
11
README.md
11
README.md
@@ -4,16 +4,13 @@
|
||||
|
||||
This repository provides Go terminal and console support packages.
|
||||
|
||||
## Download/Install
|
||||
|
||||
The easiest way to install is to run `go get -u golang.org/x/term`. You can
|
||||
also manually git clone the repository to `$GOPATH/src/golang.org/x/term`.
|
||||
|
||||
## Report Issues / Send Patches
|
||||
|
||||
This repository uses Gerrit for code changes. To learn how to submit changes to
|
||||
this repository, see https://golang.org/doc/contribute.html.
|
||||
this repository, see https://go.dev/doc/contribute.
|
||||
|
||||
The git repository is https://go.googlesource.com/term.
|
||||
|
||||
The main issue tracker for the term repository is located at
|
||||
https://github.com/golang/go/issues. Prefix your issue with "x/term:" in the
|
||||
https://go.dev/issues. Prefix your issue with "x/term:" in the
|
||||
subject line, so it is easy to find.
|
||||
|
||||
2
go.mod
2
go.mod
@@ -2,4 +2,4 @@ module golang.org/x/term
|
||||
|
||||
go 1.18
|
||||
|
||||
require golang.org/x/sys v0.19.0
|
||||
require golang.org/x/sys v0.30.0
|
||||
|
||||
4
go.sum
4
go.sum
@@ -1,2 +1,2 @@
|
||||
golang.org/x/sys v0.19.0 h1:q5f1RH2jigJ1MoAWp2KTp3gm5zAGFUTarQZ5U386+4o=
|
||||
golang.org/x/sys v0.19.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=
|
||||
golang.org/x/sys v0.30.0 h1:QjkSwP/36a20jFYWkSue1YwXzLmsV5Gfq7Eiy72C1uc=
|
||||
golang.org/x/sys v0.30.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=
|
||||
|
||||
@@ -26,6 +26,7 @@ func makeRaw(fd int) (*State, error) {
|
||||
return nil, err
|
||||
}
|
||||
raw := st &^ (windows.ENABLE_ECHO_INPUT | windows.ENABLE_PROCESSED_INPUT | windows.ENABLE_LINE_INPUT | windows.ENABLE_PROCESSED_OUTPUT)
|
||||
raw |= windows.ENABLE_VIRTUAL_TERMINAL_INPUT
|
||||
if err := windows.SetConsoleMode(windows.Handle(fd), raw); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user