MCPcopy Create free account
hub / github.com/cli/cli / rpad

Function rpad

pkg/cmd/root/help.go:299–302  ·  view source on GitHub ↗

rpad adds padding to the right of a string.

(s string, padding int)

Source from the content-addressed store, hash-verified

297
298// rpad adds padding to the right of a string.
299func rpad(s string, padding int) string {
300 template := fmt.Sprintf("%%-%ds ", padding)
301 return fmt.Sprintf(template, s)
302}
303
304func dedent(s string) string {
305 lines := strings.Split(s, "\n")

Callers 1

WriteHelpFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected