mq

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 22, 2026 License: MIT Imports: 5 Imported by: 0

Documentation

Overview

Package mq provides merge queue functionality.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GenerateMRID

func GenerateMRID(prefix, branch string) string

GenerateMRID generates a merge request ID following the convention: <prefix>-mr-<hash>

The hash is derived from the branch name + current timestamp + random bytes to ensure uniqueness. Example: gt-mr-abc123 for a gastown merge request.

Parameters:

  • prefix: The project prefix (e.g., "gt" for gastown)
  • branch: The source branch name (e.g., "polecat/Nux/gt-xyz")

Returns a string in the format "<prefix>-mr-<6-char-hash>"

func GenerateMRIDWithTime

func GenerateMRIDWithTime(prefix, branch string, timestamp time.Time) 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.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL