mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-20 10:52:25 +00:00
parent
77463b2bbf
commit
b4ab5d2a12
1 changed files with 7 additions and 0 deletions
|
|
@ -180,6 +180,13 @@ func FlagString(f cli.Flag) string {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func pad(s string, length int) string {
|
||||||
|
if len(s) < length {
|
||||||
|
s += strings.Repeat(" ", length-len(s))
|
||||||
|
}
|
||||||
|
return s
|
||||||
|
}
|
||||||
|
|
||||||
func indent(s string, nspace int) string {
|
func indent(s string, nspace int) string {
|
||||||
ind := strings.Repeat(" ", nspace)
|
ind := strings.Repeat(" ", nspace)
|
||||||
return ind + strings.ReplaceAll(s, "\n", "\n"+ind)
|
return ind + strings.ReplaceAll(s, "\n", "\n"+ind)
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue