Skip to content

loom run

Execute a module.

loom run [path] [flags]

Flags

FlagDescription
-p, --param key=valueSet a parameter (repeatable)
--params-file file.yamlLoad parameters from a YAML file
--target-path /pathDirectory for target files. With --local-run, each target repo is cloned into a numbered subdirectory (00-<name>/, 01-<name>/, …). Modules without a target spec use it directly as the target directory. Ignored otherwise.
--author nameDefault git author name for commitPush (used when not set in loom.yaml)
--email emailDefault git author email for commitPush (used when not set in loom.yaml)
--summaryPrint a list of PRs/MRs created during the run at the end
--dry-runShow what would happen without writing anything
--local-runRun all operations locally but skip remote push and PR creation
-v, --verboseEnable debug logging
--log-level levelSet log level: debug, info, warn, error
--log-format formatSet log format: pretty (default), text, json

Source Argument

[path] accepts:

FormatBehavior
./relative or /absoluteLocal directory
https://github.com/org/repo.gitGit URL — clones to temp dir, loom.yaml at repo root
https://github.com/org/repo.git//subdirGit URL with // separator — loom.yaml at subdir/ within the clone

Examples

Full run — local module

bash
loom run ./onboard-service -p serviceName=payments

Full run — remote module

bash
loom run https://github.com/myorg/loom-modules.git//onboard-service \
  -p serviceName=payments

Dry run

Modules with a target spec clone the target repo into a temporary directory and preview against that fresh clone:

bash
loom run ./onboard-service \
  -p serviceName=payments \
  --dry-run

See the diffs

To see exactly what files would be created and changed, use loom diff.

Local mode

Render, write, and commit, but don't push or open a PR. --target-path is required so you can inspect the results:

bash
loom run ./onboard-service \
  -p serviceName=payments \
  --target-path ~/repos/gitops \
  --local-run

Parameters from file

bash
loom run ./onboard-service --params-file params.yaml

The YAML file should be a flat key-value map:

yaml
serviceName: payments
namespace: fintech
env: prod

Released under the GPL-3.0 License.