From 947111f6d8127b3f44371e3668b24283ae0b4b1e Mon Sep 17 00:00:00 2001 From: slit Date: Sun, 11 Jan 2026 11:00:45 -0500 Subject: [PATCH] docs(mq): add parameter godoc for GenerateMRIDWithTime Add detailed parameter documentation for GenerateMRIDWithTime function including prefix, branch, and timestamp parameters with examples. --- internal/mq/id.go | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/internal/mq/id.go b/internal/mq/id.go index 3ec021d2..9468d511 100644 --- a/internal/mq/id.go +++ b/internal/mq/id.go @@ -30,6 +30,13 @@ func GenerateMRID(prefix, branch string) string { // GenerateMRIDWithTime generates a merge request ID using a specific timestamp. // This is primarily useful for testing to ensure deterministic output. // Note: Without randomness, two calls with identical inputs will produce the same ID. +// +// Parameters: +// - prefix: The project prefix (e.g., "gt" for gastown, "bd" for beads) +// - branch: The source branch name (e.g., "polecat/Nux/gt-xyz") +// - timestamp: The time to use for ID generation instead of time.Now() +// +// Returns a string in the format "-mr-<6-char-hash>" func GenerateMRIDWithTime(prefix, branch string, timestamp time.Time) string { return generateMRIDInternal(prefix, branch, timestamp, nil) }