Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Colorful terminal output for Golang
Go
branch: master
Failed to load latest commit information.
color Adding Errorf support
example Add terminal package
.gitignore Add terminal package
LICENSE Add license file. Fix issue #3
README.md Link to the godoc
terminal.go Add terminal package

README.md

Terminal

Terminal is a simple golang package that provides basic terminal handling.

Terminal wraps color/format functions provided by ANSI escape code

Usage

package main

import (
  "github.com/wsxiaoys/terminal"
  "github.com/wsxiaoys/terminal/color"
)

func main() {
  terminal.Stdout.Color("y").
    Print("Hello world").Nl().
    Reset().
    Colorf("@{kW}Hello world\n")

  color.Print("@rHello world")
}

Check the godoc result for more details.

Something went wrong with that request. Please try again.