Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/cli/cli
/ truncate
Function
truncate
script/ghmock/report.go:554–559 ·
view source on GitHub ↗
(s string, n int)
Source
from the content-addressed store, hash-verified
552
}
553
554
func
truncate(s string, n int) string {
555
if
len(s) <= n {
556
return
s
557
}
558
return
s[:n] +
"..."
559
}
Callers
2
formatRequest
Function · 0.85
printDifferences
Function · 0.85
Calls
no outgoing calls
Tested by
no test coverage detected