Categorygithub.com/heaths/go-console
modulepackage
0.8.0
Repository: https://github.com/heaths/go-console.git
Documentation: pkg.go.dev

# README

Go Console APIs

releases reference ci

These Go Console APIs provide a level of abstraction over virtual terminals, implement testable io.Writer, and support color schemes.

Example

You can create a new console using os streams:

package main

import (
    "fmt"

    "github.com/heaths/go-console"
)

func main() {
    con := console.System()
    fmt.Fprintln(con.Stdout(), "Hello, world!")
}

Fake

You can also create a new fake console that uses bytes.Buffer you can access from Stdout() as well:

package main

import (
    "fmt"

    "github.com/heaths/go-console"
)

func main() {
    fake := console.Fake()
    fmt.Fprintln(fake.Stdout(), "Hello, fake!")
    fmt.Println(fake.Stdout().String())
}

License

This project is licensed under the MIT license.

# Packages

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

# Functions

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

# Constants

https://github.com/briandowns/spinner#available-character-sets.
No description provided by the author

# Structs

No description provided by the author

# Interfaces

No description provided by the author

# Type aliases

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