MCPcopy Create free account
hub / github.com/auth0/auth0-cli / indent

Function indent

internal/display/display.go:339–352  ·  view source on GitHub ↗
(text, indent string)

Source from the content-addressed store, hash-verified

337}
338
339func indent(text, indent string) string {
340 if text[len(text)-1:] == "\n" {
341 result := ""
342 for _, j := range strings.Split(text[:len(text)-1], "\n") {
343 result += indent + j + "\n"
344 }
345 return result
346 }
347 result := ""
348 for _, j := range strings.Split(strings.TrimRight(text, "\n"), "\n") {
349 result += indent + j + "\n"
350 }
351 return result[:len(result)-1]
352}
353
354func boolean(v bool) string {
355 if v {

Callers 2

ExtrasMethod · 0.85
TestIndentFunction · 0.85

Calls

no outgoing calls

Tested by 1

TestIndentFunction · 0.68