LinuxCommandLibrary
GitHubF-DroidGoogle Play Store

loopt

Author GitHub Actions workflows in code and generate YAML

TLDR

Start a project with a TypeScript starter
$ loopt init
copy
Init with Python source and a Node template
$ loopt init --language python --name build --template node
copy
Import existing workflow YAML into `.loopt/workflows`
$ loopt import --language typescript
copy
Generate `.github/workflows` from the source
$ loopt gen
copy
Fail if generated YAML is out of date
$ loopt gen --check
copy
Lint generated workflows
$ loopt lint
copy
Lint with shellcheck on `run:` scripts
$ loopt lint --shellcheck on
copy

SYNOPSIS

loopt [--root dir] command [options]

DESCRIPTION

loopt lets you write GitHub Actions workflows in TypeScript, Python, Go, or Rust (custom languages via a plugin protocol). It generates standard `.github/workflows/*.yml` from `.loopt/workflows` source. Generated files start with a comment that they come from loopt; edit the source, then run loopt gen.init picks a starter from project files (`package.json`, `Cargo.toml`, `go.mod`, Python project files) unless --template is set. Starters use `contents: read`, pin `actions/checkout` to a commit without persisting credentials, cancel superseded runs, and lint clean.gen refuses to overwrite a workflow edited outside loopt unless --force. gen runs the same review as lint unless --no-lint. Composite actions (`action.yml` outside `.github/workflows/`) import as action metadata.

PARAMETERS

--root dir

Repository root (default: current directory). Global.
init [--language typescript|python|go|rust] [--name ci] [--template auto|generic|node|rust|go|python]
Write a starter under `.loopt/workflows` and generate YAML. Never overwrites an existing workflow.
import [paths...] [--language] [--force] [--plugin exe]
Convert workflow YAML into authoring source. Leaves the original YAML untouched. Defaults to every direct child of `.github/workflows`.
gen [sources...] [--force] [--no-lint] [--check]
Run authoring source and write standard workflow YAML. --check verifies without writing and exits non-zero if anything would change.
lint [paths...] [--json] [--persona regular|pedantic|auditor] [--context file] [--shellcheck auto|on|off] [--online]
Native correctness and security checks. --online uses authenticated gh for remote audits.
actions
Add, update, list, remove, or verify pinned action bindings.
secrets
Synchronize a names-only secret inventory from GitHub.
lock [--verify]
Generate or verify `.github/workflows/actions.lock` and reusable.lock pins.

CAVEATS

Prebuilt binaries are published for macOS arm64 and Linux x86_64. The authoring language must be installed when generating (Node.js 26+, Python 3, Go, or Cargo/Rust). --online lint needs an authenticated gh. Hidden plugin is the stdin/stdout protocol for custom languages, not a user command.

SEE ALSO

act(1), gh(1), shellcheck(1), cargo(1)

RESOURCES

Copied to clipboard
Kai