Skip to content

spawn check

Usage

spawn check

Reports any migration that has an up.sql but no lock.toml. Unpinned migrations are not reproducible because they resolve components from the current working tree rather than from a pinned snapshot.

To fix, pin the migration using spawn migration pin:

Terminal window
spawn migration pin <migration-name>

A non-zero exit makes spawn check suitable as a pipeline gate:

# GitHub Actions example
- name: Check migrations
run: spawn check

Options

Option Description
--target <name> Select which target from spawn.toml to use.
--config-file <path> Path to config file. Defaults to spawn.toml.
-d, --debug Turn on debug output.

Exit status

Code Meaning
0 No warnings found.
1 One or more warnings found.