actions

package
v0.6.1 Latest Latest
Warning

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

Go to latest
Published: Jun 5, 2026 License: AGPL-3.0, AGPL-3.0-only Imports: 6 Imported by: 0

Documentation

Overview

Package actions is a private serialization backend: it writes a forge-neutral model.Pipeline out in the GitHub Actions workflow wire format.

It is mechanism, not identity. It lives under ci/render/internal so it can be imported only by the render layer and never appears in any user-facing surface (CLI, config, docs, output). A forge emitter that happens to use this wire format calls Emit with a Dialect carrying that forge's provider identity; the backend itself names no forge and asserts no equivalence between forges. When a forge's needs diverge from this format, that forge's package owns the divergence — this backend does not grow forge-specific branches.

Lowering decisions (the gaps a stage-based forge hides that Actions makes explicit):

  • stages → none exist; a job with no explicit Needs is wired to depend on every job in the immediately-preceding stage, preserving ordering as an explicit needs DAG.
  • artifacts → flow is explicit: a producer uploads, every downstream consumer that needs it downloads.
  • OIDC → permissions: id-token: write plus a step that requests a token with audience "stagefreight" and exports it as STAGEFREIGHT_OIDC.
  • docker → a docker:dind service plus DOCKER_HOST/TLS env.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Emit

func Emit(p model.Pipeline, d Dialect) ([]byte, error)

Emit serializes a forge-neutral Pipeline to Actions workflow bytes using the given dialect. Pure and deterministic: identical (p, d) → identical bytes.

Types

type Dialect

type Dialect struct {
	// Provider is the forge identity string. It is written verbatim into the
	// header banner and SF_CI_PROVIDER so the rendered document and the runtime
	// context both report the calling forge, not the backend.
	Provider string
}

Dialect carries the per-call values a forge emitter supplies. Only the values that legitimately vary between callers belong here; the backend reads them but chooses nothing about identity itself.

Jump to

Keyboard shortcuts

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