1+ results for 'regex ansi lang:go' (75 ms)
8 "os/exec" 9 "regexp" 10 "strings" 22 23var ansi = regexp.MustCompile("\x1B\\[[0-?]*[ -/]*[@-~]") 24 492 } 493 if f.Regex.Match([]byte(header)) { 494 filter = exec.Command("sh", "-c", f.Command) 625 text := scanner.Text() 626 text = ansi.ReplaceAllString(text, "") 627 io.WriteString(pv.sink, text+"\n")