Skip to main content
The smartcloud command runs the same code as the action on your own machine. Use it to check a config before you push it, convert a v1 config, see what a run would do without doing it, and find out why a repository is not set up right. Nothing it does writes to GitHub.

Install

You need Node 24 or later.
From the first v2 release, the CLI and the MCP server are published together as @resnovas/smartcloud:
The examples below write smartcloud for whichever you use. smartcloud --version prints the version, and smartcloud <command> --help lists a command’s options. A command that fails prints one line starting smartcloud: on stderr and exits with code 1. Any other result exits with code 0.

validate

Checks a config and every preset it extends, merges them under the locked preset rules, and prints where the config was built from and any migration warnings. Without a path, it uses the first of .github/smartcloud.yml, .github/smartcloud.yaml and .github/config.json in the current directory.
Validation is strict: an unknown key or invalid value in the config or any preset is an error, where a run only drops it with a warning. A config that fails prints one line starting smartcloud: and exits with code 1.

migrate

Converts a v1 JSON config (default .github/config.json) to v2 YAML, and prints a warning for every v1 key it does not carry over. The output starts with a schema hint for editors, and is proven to decode before it is written. A v2 file given to migrate is rewritten unchanged. See Migrating from v1 for worked examples.

check-commit

Checks a commit message against the DCO sign-off and AI attribution rules before the commit exists, and exits with code 1 when any rule is broken. The author defaults to git’s own, and the config to the repository’s in the working directory, or smartcloud’s defaults when there is none. Comment lines are ignored, as git ignores them. Use it as a git commit-msg hook, so a commit that would fail the pull request check is stopped locally:
.git/hooks/commit-msg

dry-run

Runs every feature against a real pull request, issue or repository event, through the dry-run layer. It reads GitHub as the action would, then prints the job summary and every write the run would make. It never writes. Give exactly one of --pr, --issue or --event.

plan settings

Prints every repository settings step the config would apply, with its request, without applying any of them. Use it before merging a change to the settings section, since those steps change the repository for everyone.
It reads only the repository itself, so any token that can read the repository works. A config without a settings section prints no steps. When a run would ignore part of the settings section, such as a merge queue method that conflicts with the rest of the ruleset, the plan lists it after the steps under “Ignored, so not applied”, with the reason.

sync

Renders the files the sync feature would write to the repository into a local directory, with each file’s status (added, updated, made executable or unchanged), and lists any conflicts. Nothing is sent to GitHub. A config without a sync section fails with the config has no sync section. Every file is checked before any is written: one that would land outside the directory, or be written through a symlink inside it, stops the command with nothing written.

doctor

Checks what smartcloud needs to run on a repository, with the token the CLI finds, and prints one line per check. It exits with code 1 when any check fails. Nothing is written. Run it with your own token to check the repository, or with the token a workflow passes to smartcloud to check that token:
Workflows are read line by line rather than parsed: every uses: of another repository and every secrets.NAME or vars.NAME outside a comment line counts, including one guarded by a condition.

Tokens

dry-run, plan settings, sync and doctor always read GitHub. validate needs a token only to read presets named in extends, so validating a config without presets works offline. When it does need one, it uses GITHUB_TOKEN if set, and otherwise the token of the signed-in GitHub CLI (gh auth token). The token is never printed.
Last modified on September 28, 2026