build

Helps build, run, test, and deploy the project. Provides common commands, environment checks, and release checklists. Use when building, deploying, or troubleshooting build issues.

Build & Deploy

Common Commands

Adapt these to the project's actual build system. Detect from the project root which applies:

Node.js / npm / yarn / pnpm

npm install          # Install dependencies
npm run build        # Production build
npm run dev          # Development server
npm test             # Run tests
npm run lint         # Lint check

Python / pip / poetry

pip install -e .     # Install in dev mode
python -m pytest     # Run tests
python -m mypy .     # Type check
python -m ruff .     # Lint

Go

go build ./...       # Build all
go test ./...        # Test all
go vet ./...         # Static analysis

Gradle (JVM / Android)

./gradlew build          # Full build
./gradlew test           # Unit tests
./gradlew assembleDebug  # Debug build (Android)

Rust / Cargo

cargo build          # Debug build
cargo build --release # Release build
cargo test           # Run tests
cargo clippy         # Lint

Pre-Build Checks

  1. Correct runtime/SDK version installed?
  2. Dependencies up to date? (lock file matches)
  3. Environment variables set? (check .env.example)
  4. Required services running? (DB, Redis, etc.)

Release Checklist

  • All tests pass
  • No new warnings
  • Version bumped appropriately
  • Changelog updated (if maintained)
  • Debug/dev code removed
  • Environment config set for production
  • Build artifact tested on staging
  • Secrets not hardcoded