MCPcopy Create free account
hub / github.com/github/gh-aw / defaultIntStr

Function defaultIntStr

pkg/workflow/templatables.go:327–330  ·  view source on GitHub ↗

defaultIntStr returns a pointer to the string representation of n. Used to set default values for templatable integer fields when the field is nil.

(n int)

Source from the content-addressed store, hash-verified

325// defaultIntStr returns a pointer to the string representation of n.
326// Used to set default values for templatable integer fields when the field is nil.
327func defaultIntStr(n int) *string {
328 s := strconv.Itoa(n)
329 return &s
330}
331
332// templatableIntValue parses a *string templatable integer value to int.
333// Returns 0 if value is nil or is a GitHub Actions expression (not evaluable at compile time).

Calls

no outgoing calls