package birdfmt import "strings" // PeerProtocolName returns the BIRD protocol name for a control-plane peer UUID. // Must stay in sync with pipeline peer rendering. func PeerProtocolName(peerID string) string { s := strings.ReplaceAll(strings.TrimSpace(peerID), "-", "") if len(s) > 16 { s = s[:16] } if s == "" { s = "x" } return "evobgp_p_" + s }