Skip to content

treasersimplifies/cstr

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Colorful String

Dye your string with color when printing it.

Are you a programmer willing to try something new?

Are you bored with you single-color command line output text(like the following)?

Are you looking for decorations for your command line tool?

This package will show you this:

Example

$ git clone [email protected]:treasersimplifies/cstr.git
$ cd cstr
$ go test

and you will see:

Installation

To install cstr package, you need to install Go first.

Install cstr:

go get github.com/treasersimplifies/cstr
# or:
go get -u github.com/treasersimplifies/cstr@master

Import cstr in your code:

import "github.com/treasersimplifies/cstr"

Use in code:

fmt.Println(cstr.Dye("This is a Red string.....", "Red"))
fmt.Println(cstr.DyeColorfully("THIS IS A COLORFUL STRING...........\n", []string{"Red", "Green", "Yellow", "Blue", "Pink", "Skyblue", "White"}))

About

colorful string printing in your console

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages