dynamic

package
v1.78.0 Latest Latest
Warning

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

Go to latest
Published: Nov 14, 2026 License: Apache-2.0 Imports: 1 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package dynamic is a module's enable intent rule. The getter folds the Module.spec.enabled intent and the deprecated global-hook enable signal into one tri-state; an enable is a soft Enable (gates and the enabled script can still forbid), a disable is a Forbid no other rule can undo.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Getter

type Getter func(module string) *bool

Getter reports a module's intent: *true, *false, or nil for no opinion.

type Rule

type Rule struct {
	// contains filtered or unexported fields
}

Rule is the intent rule of one module.

func NewRule

func NewRule(getter Getter, module string) *Rule

NewRule constructs the intent rule of module.

func (*Rule) Decide

func (r *Rule) Decide() rule.Decision

Decide returns Enable, Forbid or Undefined for the intent.

Jump to

Keyboard shortcuts

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