9 lines
163 B
Go
9 lines
163 B
Go
package ansi
|
|
|
|
import "regexp"
|
|
|
|
var ansiRegex = regexp.MustCompile(`\x1b\[[0-9;]*m`)
|
|
|
|
func StripANSI(s string) string {
|
|
return ansiRegex.ReplaceAllString(s, "")
|
|
}
|