Usage
Flags
—remote
Specify the git remote name.origin
—no-set-upstream
Disable automatic upstream branch configuration.dex deploy runs:
--no-set-upstream to skip this and require manual upstream configuration.
—no-preflight
Skip preflight validation before pushing.—preflight-env
Specify the environment for preflight checks.test- Run preflight for test environment (default)prod- Run preflight for production environment
Preflight checks validate entry audits, protected asset coverage, catalog integrity, and generated HTML security.
What preflight checks
When--no-preflight is NOT set, dex deploy runs:
- Entry runtime audit - Validates all non-legacy entries for data integrity
- Protected asset coverage - Ensures all active catalog lookups have asset mappings
- Catalog validation - Checks catalog manifest for structural issues
- Generated HTML security - Runs
scripts/verify-generated-html.mjsto detect unsafe patterns
Deploy behavior
After preflight passes,dex deploy runs:
- Verifies current directory is a git repository
- Ensures not in detached HEAD state
- Resolves current branch name
Recommended workflows
Production deploy (safest)
Test deploy
Emergency bypass
Examples
Deploy to origin with production preflight
Deploy to custom remote
Deploy without setting upstream
Emergency deploy (skip preflight)
Error handling
Deploy fails if:- Not inside a git repository
- In detached HEAD state
- Preflight checks fail (unless
--no-preflight) - Git push fails (network, permissions, conflicts)
Integration with release workflow
For coordinated content + infrastructure deploys, use the full release workflow: See dex release for coordinated publishing.High-risk flags policy
Related commands
dex release
Full release workflow with preflight
dex setup
Configure workspace repository paths