-
Notifications
You must be signed in to change notification settings - Fork 0
Workflow Declaration
workflow("build", {
{ phase = "generate", scope = "code" },
{ phase = "compile", scope = "code" },
})A workflow is an ordered list of workflow steps. Each workflow step runs one or more phase+scope pairs.
See also: Plugin System for staged workflows, importing workflows from plugins (
workflows({ build = "coditary/pipeline:build" })), andphase[scope]syntax.
workflow("build", {
{ phase = "generate", scope = "code" },
{ phase = "compile", scope = "code" },
{ phase = "test", scope = "unit" },
})Beez runs each entry after the previous one finishes.
For { phase = "compile", scope = "code" }, Beez runs all steps where step.phase == "compile" and step.scope == "code", using order() and parallelism rules inside that group.
workflow("ci", {
{ parallel = {
{ phase = "generate", scope = "docs" },
{ phase = "generate", scope = "code" },
}},
{ phase = "compile", scope = "code" },
})The parallel table contains phase+scope entries that run at the same time. The next workflow step waits until all parallel branches complete.
Each parallel entry must be a table with:
| Field | Required | Type |
|---|---|---|
phase |
yes | string |
scope |
yes | string |
parallel must contain at least one entry.
Group phase+scope invocations into named stages. Stages run sequentially; invocations inside a stage run in parallel.
workflows {
build = {
{ "setup", { "setup[app]" } },
{ "compile", { "compile[app]" } },
{ "bundle", { "bundle[app]" } },
{ "test", { "test[test]" } },
},
}| Syntax in invocation list | Meaning |
|---|---|
"compile[app]" |
Phase compile, scope app
|
"setup" |
Phase setup, all scopes |
Import a plugin workflow in build.lua:
workflows({
all = "coditary/pipeline:all",
})Do not mix staged entries ({ "stage", { ... } }) with legacy { phase, scope } tables in the same workflow.
workflows({
build = "coditary/pipeline:build",
quality = "coditary/pipeline:quality",
quick = {
{ "test", { "test[test]" } },
},
})| Form | Meaning |
|---|---|
{ phase = "p", scope = "s" } |
Run one phase+scope |
{ parallel = { { phase, scope }, ... } } |
Run several phase+scope pairs in parallel |
Non-table entries in the workflow list are ignored.
- Shell commands (use a task or a step with
runstring) - Direct step names (use a task like
{ name = "step" }or runbeez -s) - Nested workflows
beez build
beez ciSee Running Targets.
Workflows are entry points for pipelines. Common patterns:
-
build- compile and maybe test -
ci- lint, test, package -
check- fast validation subset
Name and structure are entirely up to you. Beez does not ship built-in workflow names.
step({
name = "gen-docs",
phase = "generate",
scope = "docs",
run = "make docs",
})
step({
name = "gen-code",
phase = "generate",
scope = "code",
run = "make codegen",
})
step({
name = "compile",
phase = "compile",
scope = "code",
run = "make",
})
order("gen-code", "compile")
workflow("ci", {
{ parallel = {
{ phase = "generate", scope = "docs" },
{ phase = "generate", scope = "code" },
}},
{ phase = "compile", scope = "code" },
})- Order Declaration - ordering inside a phase+scope
- Parallel Execution and Dependencies - how steps run inside each block
- Filtering by Phase - run a phase without a workflow
Quick Reference · Glossary · FAQ
- Fundamentals
- Core Concepts
- Project Layout
- First Pipeline
- Phases and Scopes
- How Phases and Scopes Work
- Selecting with Phases and Scopes
- Designing Phases and Scopes
- Parallel Execution and Dependencies
- Configuration
- Configuration Overview
- Global User Config
- Project Config
- Environment Variables
- Performance Settings
- Cache Settings
- Config Reference
- CLI
- CLI Overview
- Running Targets
- Filtering by Phase
- Running a Single Step
- Listing Entities
- Output and Logging Flags
- Cache and Maintenance Flags
- Meta and Utility Commands
-
Project Scaffolding —
beez --init(embedded Tempify) - CLI Flag Reference
- Lua DSL
- DSL Overview
- Plugin System — Plugins, Config DSL, Standard-Workflows
- Step Declaration
- Task Declaration
- Workflow Declaration
- Order Declaration
- Configure Step
- ReqPack Declaration
- Beez API
- Step Context
- DSL Patterns
- Caching
- Caching Overview
- Step Cache
- Success Cache
- Glob Metadata Cache
- Artifact Patterns
- Cache Keys and Invalidation
- Cache Storage and Maintenance
- Caching Troubleshooting
- UI and Output
- Output Modes
- Progress and Animation
- Colors and Themes
- Run Summaries
- Logging and Log Files
- Development and Contribution
- Building and Setup
- Repository Layout
- Testing
- Code Quality
- Feature Development Workflow
- Submitting Changes