version_bump/context
The shared context threaded through every plugin hook, mirroring
semantic-release’s context object. It is immutable: the engine produces a
new Context as the pipeline advances (e.g. after analysing commits it sets
next_release).
Types
pub type Context {
Context(
cwd: String,
env: dict.Dict(String, String),
config: config.Config,
branch: branch.Branch,
branches: List(branch.Branch),
commits: List(commit_parser.ConventionalCommit),
last_release: option.Option(release.LastRelease),
next_release: option.Option(release.NextRelease),
releases: List(release.Release),
errors: List(String),
dry_run: Bool,
)
}
Constructors
-
Context( cwd: String, env: dict.Dict(String, String), config: config.Config, branch: branch.Branch, branches: List(branch.Branch), commits: List(commit_parser.ConventionalCommit), last_release: option.Option(release.LastRelease), next_release: option.Option(release.NextRelease), releases: List(release.Release), errors: List(String), dry_run: Bool, )
Values
pub fn new(
cwd cwd: String,
env env: dict.Dict(String, String),
config config: config.Config,
branch branch: branch.Branch,
branches branches: List(branch.Branch),
) -> Context
Build an initial context with the empty/None fields the pipeline fills in.