Categorygithub.com/containerd/console
modulepackage
1.0.4
Repository: https://github.com/containerd/console.git
Documentation: pkg.go.dev

# README

console

PkgGoDev Build Status Go Report Card

Golang package for dealing with consoles. Light on deps and a simple API.

Modifying the current process

current := console.Current()
defer current.Reset()

if err := current.SetRaw(); err != nil {
}
ws, err := current.Size()
current.Resize(ws)

Project details

console is a containerd sub-project, licensed under the Apache 2.0 license. As a containerd sub-project, you will find the:

information in our containerd/project repository.

# Functions

ClearONLCR sets the necessary tty_ioctl(4)s to ensure that a pty pair created by us acts normally.
ConsoleFromFile returns a console using the provided file nolint:revive.
Current returns the current process' console.
NewEpoller returns an instance of epoller with a valid epoll fd.
NewPty creates a new pty pair The master is returned as the first console and a string with the path to the pty slave is returned as the second.
SetONLCR sets the necessary tty_ioctl(4)s to ensure that a pty pair created by us acts as intended for a terminal emulator.

# Variables

No description provided by the author
No description provided by the author

# Structs

EpollConsole acts like a console but registers its file descriptor with an epoll fd and uses epoll API to perform I/O.
Epoller manages multiple epoll consoles using edge-triggered epoll api so we dont have to deal with repeated wake-up of EPOLLER or EPOLLHUP.
WinSize specifies the window size of the console.

# Interfaces

No description provided by the author
No description provided by the author