MCPcopy
hub / github.com/pterm/pterm / RemoveColorFromString

Function RemoveColorFromString

print.go:189–191  ·  view source on GitHub ↗

RemoveColorFromString removes color codes and OSC 8 hyperlinks from a string.

(a ...any)

Source from the content-addressed store, hash-verified

187
188// RemoveColorFromString removes color codes and OSC 8 hyperlinks from a string.
189func RemoveColorFromString(a ...any) string {
190 return internal.RemoveEscapeCodes(Sprint(a...))
191}
192
193func fClearLine(writer io.Writer) {
194 if RawOutput || writer == nil || !Output {

Callers 9

SprintMethod · 0.85
SprintMethod · 0.85
splitTextFunction · 0.85
SprintMethod · 0.85
getStringMethod · 0.85
SrenderMethod · 0.85
ShowMethod · 0.85
SrenderMethod · 0.85

Calls 2

RemoveEscapeCodesFunction · 0.92
SprintFunction · 0.85

Tested by 1

Used in the wild real call sites across dependent graphs

searching dependent graphs…