Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
var Supported = PlatformInfo{ MacOSVersions: []MacOSVersion{ {Major: 27, Symbol: "golden_gate"}, {Major: 26, Symbol: "tahoe"}, {Major: 15, Symbol: "sequoia"}, {Major: 14, Symbol: "sonoma"}, {Major: 13, Symbol: "ventura"}, {Major: 12, Symbol: "monterey"}, }, LinuxArches: []string{"x86_64", "arm64"}, }
Supported is the platform set gobottle targets. Update it when brew adds or drops a macOS release; only the oldest entry affects the bottles produced.
Functions ¶
func FormatPlatformList ¶
func FormatPlatformList(info *PlatformInfo) string
FormatPlatformList returns a human-readable list of platforms
func NormalizeTag ¶ added in v0.8.2
NormalizeTag maps legacy bottle tag spellings onto the ones gobottle emits (aarch64_linux -> arm64_linux), so platform filters written against older releases keep matching.
func ParsePlatformTag ¶
ParsePlatformTag parses a Homebrew platform tag into OS, arch, and version
Types ¶
type MacOSVersion ¶
MacOSVersion represents a macOS version with its codename
func (MacOSVersion) String ¶
func (v MacOSVersion) String() string
type Platform ¶
type Platform struct {
Tag string // e.g., "arm64_sonoma", "x86_64_linux"
OS string // "darwin" or "linux"
Arch string // "amd64" or "arm64"
OSVersion string // e.g., "sonoma", "ventura" (macOS codename), or empty for Linux
OSVersionMajor int // e.g., 14 for sonoma; 0 for Linux
}
Platform represents a Homebrew bottle platform tag
func FilterPlatforms ¶
FilterPlatforms filters platforms based on include/exclude lists
type PlatformInfo ¶
type PlatformInfo struct {
MacOSVersions []MacOSVersion // Supported macOS versions (newest first)
LinuxArches []string // e.g., ["x86_64", "arm64"]
}
PlatformInfo holds platform information
func (*PlatformInfo) AllPlatforms ¶
func (pi *PlatformInfo) AllPlatforms() []Platform
AllPlatforms returns all possible platform tags
func (*PlatformInfo) GetPlatformsForOS ¶
func (pi *PlatformInfo) GetPlatformsForOS(goos, goarch string) []Platform
GetPlatformsForOS returns the Homebrew platform tag for a given OS/arch. For macOS, returns only the oldest supported version (e.g., monterey). Homebrew's fallback mechanism allows older bottles to install on newer macOS.