Expand description
The one pure target-specific projection over this binary’s embedded sources.
Projection::compute takes a ProjectionInput, values alone, and
answers the complete candidate artifact tree this installed binary
would land in one target: every destination with its ownership
Kind, its Placement, the complete proposed bytes, the rendered
region where the destination is a marked region, and the embedded
source paths it was rendered from. Staging and production landing
share it byte for byte, so what an agent studies in a stage is what a
landing writes.
This module reads snippets and blocks through src/embedded.rs
directly and reads nothing else: no target file, no environment, no
Git state, no clock, no registry, no network. Whatever a projection
needs from the target arrives as TargetEvidence, gathered before
construction by evidence::gather, which lives in its own file so a
source scan can hold this one to the pure boundary.
Every pure piece of the landing model has one implementation here: the
kind table, the token substitution, the block templating, the splice
and marker judgments, and the Nix crate-shape judgment. Which embedded
source belongs to which capability, and whether a capability is
available at the target’s dimensions, is the catalog’s answer in
crate::profile::catalog, and this module renders what the catalog
selects. src/landing.rs re-exports the pieces under their old names.
One input type, one compute function, one candidate shape: staging and every landing verb consume this one projection.
Re-exports§
pub use crate::landing::manifest::Provider;
Modules§
- evidence
- Gathering the target evidence a projection consumes.
Structs§
- Block
Shape - The axes every landed block reads, resolved from one target’s parameters.
- Candidate
- One proposed destination.
- Collision
- One block destination the target’s document cannot take.
- Crate
Shape - The structural facts of the target’s crate that the seeded Nix package expression and the seed flake’s smoke check rely on.
- Omission
- One destination withheld from this target, with why.
- Projection
- The complete candidate artifact tree for one target.
- Projection
Input - The complete input to one projection: the resolved landing parameters and the typed evidence read from the target beforehand.
- Routing
Guards - The two policy fragments the workflow guards add to the routing block.
- Target
Evidence - What a projection needs to know about the target, gathered before the projection runs and carried as values.
- Trunk
Guards - The authored guard entries the integration mode selects between, beside the mode itself, and the release mode’s tag guard.
- Workflow
Hooks - The hook entries the workflow guards add to the hook block.
Enums§
Constants§
- AGENTS_
BLOCK - The authored routing-block template.
- AGENTS_
BLOCK_ WORKFLOW - The routing block’s workflow variant, for a target whose release mode
is
none: no## Releasesheading and no release reason. - AGENTS_
DESTINATION - The destination the routing block splices into.
- AGENTS_
LINE_ AGENT_ POLICY - The routing block’s agent policy lines, under the workflow guards.
- AGENTS_
LINE_ AGENT_ POLICY_ WORKFLOW - The agent policy lines of the workflow variant, which name the two workflow terms and no tag.
- AGENTS_
LINE_ COMMIT_ POLICY - The routing block’s commit policy lines, under the workflow guards: the message source and the scope rule, each the target’s own variant, and the scope vocabulary line.
- AGENTS_
LINE_ COMMIT_ SCOPE_ PREFERRED - The scope line under
release.mode = "none": a scope is preferred. - AGENTS_
LINE_ COMMIT_ SCOPE_ REQUIRED - The scope line wherever the record names a release: a scope is required.
- AGENTS_
LINE_ COMMIT_ SOURCE_ REBASE - The message source line under the
rebasemerge form: every commit reaches the trunk with its own message. - AGENTS_
LINE_ COMMIT_ SOURCE_ SQUASH - The message source line under the
squashmerge form: the request’s title becomes the trunk’s one commit. - BLOCK_
BEGIN - The block’s opening marker.
- BLOCK_
DESTINATIONS - Every block destination, in the order a landing writes them.
- BLOCK_
END - The block’s closing marker.
- BRANCH_
GRAMMAR - The one branch grammar.
- BRANCH_
SHAPE_ TOKEN - The head-branch shape the release driver gives its own request.
- CODE_
SCANNING_ DESTINATIONS - Every destination the opt-in code scanning capability can land, against the provider that lands it.
- CODE_
SCANNING_ TECHS - The bindings that ship a code scanning workflow.
- DEV_
ENVIRONMENT_ GIT_ USER - The git identity step both GitHub halves take under a recorded development environment.
- DEV_
ENVIRONMENT_ RELEASE - The GitHub release half under a recorded development environment.
- DEV_
ENVIRONMENT_ REQUEST - The GitHub request half under a recorded development environment.
- DEV_
ENVIRONMENT_ SPANS - The four replaceable spans a recorded development environment answers.
- DEV_
GIT_ USER_ TOKEN - Where a GitHub release job’s git identity step composes in.
- DEV_
RUN_ TOKEN - The run prefix a release job calls a project tool through.
- DEV_
SETUP_ STEPS_ TOKEN - The setup steps a release job takes before its first project tool, rendered from the recorded answer.
- FORCE_
SCOPE_ ARG - The argument that makes the landed
conventional-pre-commithook require a scope, as the authored message guards carry it. - GITLAB_
COMMIT_ FRAGMENT - The GitLab commit fragment the root pipeline includes under
rebase. - GITLAB_
GATE_ FRAGMENT_ TOKEN - The forge gate fragment a binding’s GitLab root pipeline includes: the
title fragment under
squashand the commit fragment underrebase. - GITLAB_
ROOT_ PIPELINE - The GitLab root pipeline, the one destination a release-less landing withholds where the target owns it.
- GITLAB_
TITLE_ FRAGMENT - The GitLab title fragment the root pipeline includes under
squash. - GLOSSARY_
BLOCK - The authored glossary template.
- GLOSSARY_
BLOCK_ WORKFLOW - The glossary’s workflow variant, which carries no release term.
- GLOSSARY_
DESTINATION - The destination the glossary block splices into.
- HOOKS_
BEGIN - The hook block’s opening marker, a YAML comment at column zero.
- HOOKS_
DESTINATION - The destination the hook block splices into.
- HOOKS_
END - The hook block’s closing marker.
- HOOK_
TYPES_ LINE - The top-level key the fresh hook file carries and the skills verify on an existing one: the commit-msg and pre-push hooks run only where their hook types are installed.
- IF_
NO_ REGISTRY_ TOKEN - Opens the commented-out form of a line a rust pair carries only where its crate publishes to no registry.
- IF_
NO_ RELEASE_ TOKEN - Marks a line a forge gate carries only where the release mode is
none: its release-less wording, dropped wherever a release stands. - IF_
REGISTRY_ TOKEN - Ends a line a rust pair carries wherever its crate publishes to a registry.
- IF_
RELEASE_ TOKEN - Marks a line a forge gate carries wherever the record names a release.
- LINE_
PREFIX_ RE_ TOKEN - The same prefix, escaped for a slash-delimited regular expression.
- LINE_
PREFIX_ TOKEN - The release-line branch prefix, naming the lines a release trigger accepts beside the trunk.
- MERGE_
FLAG_ TOKEN - The merge flag a GitHub release arm passes to
gh pr merge: the one method the trunk ruleset allows under the recorded merge form. - NIX_
DESTINATIONS - The destinations of the opt-in Nix capability, present in a projection
only where the landing’s
nixparameter is on. - NIX_
WITHHOLDABLE - The subset a target with a flake of its own keeps out: the seed pair, whose files would sit beside a flake release-kit did not author.
- OWNER_
TOKEN - The mechanical substitution sites in
renderedfiles. - PRE_
COMMIT_ BLOCK - The authored hook-block template.
- PRE_
COMMIT_ BRANCH_ NAME_ GUARD - The workflow guards’ branch name hook.
- PRE_
COMMIT_ INTEGRATE_ NOTE - The header note naming the pre-integrate contract.
- PRE_
COMMIT_ LOCAL_ TRUNK_ COMMIT_ GUARD - The local integration mode’s guard against a trunk commit, at the pre-commit stage alone, so the operator’s trunk push stays open.
- PRE_
COMMIT_ LOCAL_ TRUNK_ PUSH_ GUARDS - The local integration mode’s two pre-push guards: no force push to the trunk, and no merge commit on it.
- PRE_
COMMIT_ MESSAGE_ GUARDS - The workflow guards’ commit message hooks.
- PRE_
COMMIT_ STATUS_ RELEASE_ FILES - The release files the status check watches, wherever the record names a release.
- PRE_
COMMIT_ SWEEP_ NONE - The header note for the pairing whose sweep skips nothing.
- PRE_
COMMIT_ SWEEP_ SKIP - The header note naming what a CI sweep skips.
- PRE_
COMMIT_ TAG_ GUARD - The tag guard, wherever the record names a release.
- PRE_
COMMIT_ TRUNK_ COMMIT_ GUARD - The forge integration mode’s guard against a trunk commit.
- PRE_
COMMIT_ TRUNK_ PUSH_ GUARD - The forge integration mode’s guard against a trunk push.
- PRE_
COMMIT_ WORKTREE_ GUARD - The worktree mode’s guard entry, under the workflow guards.
- PUSH_
GUARD_ TOKEN - The token a release workflow’s job condition carries, so that a rendering which adds a second trigger cannot let the new event enter a job written for a push.
- RELEASE_
GATE_ JOB - The gate’s own job, added to a release workflow.
- RELEASE_
GATE_ TRIGGER - The gate’s trigger block, added to a release workflow’s
onkey. - REPO_
PLACEHOLDER - The repository a preview stands in for where nothing answered.
- REPO_
TOKEN - The full recorded project path, including nested namespaces.
- REQUEST_
JOB_ TOKEN - The id of the job that opens and refreshes the release request.
- REQUIRED_
CHECK_ TOKEN - The check the release gate judges.
- REQUIRED_
WORKFLOW_ TOKEN - The workflow whose completion wakes the release gate.
- SCOPED_
TOKEN - The word a gate’s step name gives the Conventional Commit it requires:
scopedwherever the record names a release, and nothing where a scope is preferred and not required. - SCOPE_
CLOSE_ TOKEN - The closing end of a gate pattern’s scope group: see
SCOPE_OPEN_TOKEN. - SCOPE_
OPEN_ TOKEN - The opening end of a gate pattern’s scope group.
- SCOPE_
SHAPE - The one commit scope shape.
- SCOPE_
SHAPE_ TOKEN - The one scope shape: the title checks’ regular expression.
- SCORECARD_
DESTINATIONS - The destinations of the opt-in Scorecard capability, present in a
projection only where the landing’s
scorecardparameter is on. - SECURITY_
SPANS - The three replaceable spans of a landed security policy, each as its ordered begin and end marker.
- SQUASH_
ON_ MERGE_ TOKEN - The
squashanswer a GitLab release arm passes to the merge call:trueundersquash,falseunderrebase, whose project squashes nothing. - STYLE_
TOKEN - The recorded release style:
trunkarms the bot’s request in the landed release workflow,linesleaves every request unarmed. - TRUNK_
BRANCH_ TOKEN - The one permanent branch. A landed release trigger, ref guard, and
branch guard each name it, so a target whose trunk is not
masterneeds its own answer in its own bytes.
Functions§
- authored
- An authored block without the one final newline the repository’s
hooks enforce on every file under
blocks/; a test insrc/embedded.rsholds each file to exactly one. - block_
markers - The markers of a block destination, or
Nonefor a whole-file one. - code_
scanning_ incompatibility - Why the named code scanning provider cannot run at this
(technology, forge), orNonewhere it can or none is named. - code_
scanning_ licence_ refusal - Why the code scanning capability’s licence condition refuses this
target, or
Nonewhere no condition applies or the licence satisfies it. - compose_
glossary - The glossary block from its authored template: markers included and without a trailing newline. It carries no token and no mode, so the same bytes land in every target.
- compose_
hooks - The hook block from its authored template.
- compose_
routing - The routing block from its authored template, with the workflow guards’ two fragments where the target selects them.
- destinations
- Every destination the embedded sources can land, in declaration order.
- embedded_
block - One authored block this binary embeds, as text, by its embedded path.
- extract_
block - The marked block inside a document, markers included, or
Nonewhere the text carries no complete block. - flake_
pair_ withheld - Why the flake half of the Nix capability stays out of this landing, or
Nonewhere the pair lands whole. - glossary_
block - The glossary block from this binary’s embedded template, for a target that names a release.
- glossary_
block_ of - The glossary block one shape selects: the workflow variant, which carries no release term, where the record names no release.
- hooks_
block - The hook block for one checkout mode and one integration mode, with or without the workflow guards, from this binary’s embedded templates, for a target that names a release.
- hooks_
block_ of - The hook block one shape selects.
- hooks_
marker_ defect marker_defectfor the hook file, the destination whose entries execute.- kind_of
- The declared kind of a destination, or
Nonefor a file the sources does not classify. - licence_
states_ an_ open_ source_ codebase - Whether one SPDX expression is well formed and states an open-source codebase.
- marker_
defect - The one definition of an ill-formed block document, shared by every
splice and every reader that judges one:
Nonefor a whole-file destination or a well-formed document. - nix_
unsupported_ shape - Why the whole Nix capability stays out of a landing, or
Nonewhere the target’s crate shape supports the seed. - nix_
withholding - The Nix destinations an opted-in landing withholds at this target, with
the one reason, or
Nonewhere the capability lands whole ornixis off. - registry_
lines - Keep the lines that fit where the crate publishes, each with its marker removed, and drop the rest. A file that carries neither marker passes through unchanged.
- release_
driver_ shape - What a release driver’s own release request is shaped like, and which job maintains it, where this release drives that driver on GitHub.
- release_
gate_ spans - The three replaceable spans of a release workflow under the rendering that gates its request, each as its ordered begin and end marker.
- render
- Substitute the landing parameters into a
renderedfile’s bytes. - routing_
block - The routing block, with or without the workflow guards, from this
binary’s embedded templates, for a release-bearing
squashtarget. - routing_
block_ of - The routing block one shape selects.
- scope_
is_ shaped - Whether one scope matches
SCOPE_SHAPE. - splice_
hooks_ block - The whole
.pre-commit-config.yamlcontent after splicing the rendered hook block. - splice_
marked_ block - The whole document’s bytes after splicing a marked block into it.
- substitute
- Every
tokenoccurrence replaced withvalue. - supported_
pairs - Every
(driver, forge)pair at which the release automation is available, in path order.