-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathlifecycle.go
More file actions
30 lines (24 loc) · 1.1 KB
/
lifecycle.go
File metadata and controls
30 lines (24 loc) · 1.1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
// Package lifecycle provides types for runtime version lifecycle status.
// Providers can implement StatusProvider to surface lifecycle information
// (e.g., LTS, EOL) in version listings.
package lifecycle
// Status represents a version's position in its runtime's release lifecycle.
type Status string
const (
// Current indicates an actively developed release line (typically the latest).
Current Status = "Current"
// ActiveLTS indicates a release receiving active long-term support.
ActiveLTS Status = "Active LTS"
// MaintenanceLTS indicates a release receiving only critical fixes.
MaintenanceLTS Status = "Maintenance LTS"
// EOL indicates a release that has reached end of life.
EOL Status = "EOL"
)
// StatusProvider returns lifecycle status for a given version string.
// Providers that track release schedules (e.g., Node.js) can implement
// this interface so list-all displays lifecycle information.
type StatusProvider interface {
// VersionStatus returns the lifecycle status label for the given version,
// or an empty string if the status is unknown.
VersionStatus(version string) string
}