Skip to main content
Version: 0.6.2

Quickstart

1. Build a package

d1pac build \
--project testdata/sample/sample.d1pac \
--output out/

This produces out/SampleProject.d1pkg.

2. Plan against D1

d1pac plan \
--package out/SampleProject.d1pkg \
--database my-database \
--script deployment.sql

Use --format json when CI needs structured plan output. A database UUID can be supplied instead of its name.

3. Apply

d1pac apply \
--package out/SampleProject.d1pkg \
--database my-database

If the plan would remove schema or data, inspect it and explicitly pass --allow-drop. --force is reserved for controlled recovery and automation where all safety checks have already happened elsewhere.