Files
speedrun/marathon/output.go
2021-03-21 23:10:46 +01:00

18 lines
280 B
Go

package marathon
import (
"fmt"
"strings"
)
func formatOutput(body string) string {
f := []string{}
for _, line := range strings.Split(body, "\n") {
line = fmt.Sprintf(" %s", line)
f = append(f, line)
}
f = append(f[:len(f)-1], "")
return strings.Join(f, "\n")
}