- URL:
https://github.com/drupaltools/tools - Team:
DrupalTools - Email:
drupaltools@tplcom.mozmail.com
monorepo/
├── packages/
│ ├── php/ # Composer/PSR-4 packages
│ ├── js/ # npm/TypeScript packages
│ ├── python/ # setuptools packages
│ ├── go/ # Go modules
│ └── rust/ # Cargo crates
├── .github/workflows/
│ ├── ci.yml # Unified CI pipeline
│ └── release.yml # Changeset-driven publishing
├── .changeset/ # Independent per-package versioning
└── [config files] # turbo.json, pnpm-workspace.yaml, prettier, eslint, commitlint, ruff
# Monorepo-wide (run from root)
pnpm install # Install all workspace dependencies
pnpm turbo run build # Build all packages
pnpm turbo run test # Test all packages
pnpm turbo run lint # Lint all packages
pnpm turbo run format # Format all packages
pnpm turbo run clean # Clean build artifacts
pnpm changeset # Create a changeset (run before PR to main)
pnpm exec husky install # Activate pre-commit hooks
# Single package
pnpm turbo run test --filter=@scope/package-name
pnpm turbo run lint --filter=@scope/package-name| Language | Lint | Format | Type check | Test |
|---|---|---|---|---|
| PHP | PHPStan, Psalm | PHP-CS-Fixer | PHPStan | PHPUnit |
| JS/TS | ESLint | Prettier | TypeScript | Vitest |
| Python | ruff | ruff format | mypy | pytest |
| Go | golangci-lint | gofmt | go vet | go test |
| Rust | clippy | cargo fmt | cargo check | cargo test |
# PHP
composer install && composer test && composer lint && composer format
# JS/TS
pnpm install && pnpm test && pnpm lint && pnpm build
# Python — check the package's pyproject.toml for its specific scripts and dependencies
# Go
go mod download && make test && make lint && make build
# Rust
cargo test && cargo clippy && cargo fmt && cargo buildFormat: <type>(<scope>): <description>
Examples: feat(python): add new feature, fix(php): resolve bug, chore: update deps
Types: feat, fix, perf, refactor, style, test, build, ci, chore, docs, revert
Scopes: php, js, python, go, rust, ci, docs
Pre-commit hooks enforce this via commitlint.
- Each package has independent semver
- Before merging to
main: runpnpm changesetto create a.changeset/file - Merging to
mainopens an automatic version PR - Merging the version PR publishes to registries
| Language | Convention | Example |
|---|---|---|
| Python | Underscores | my_module.py, my_package/ |
| Ruby | Underscores | my_script.rb |
| Bash | Underscores | build.sh, setup.sh |
| JS/TS | kebab-case for files | my-component.tsx, build.sh |
Python module imports require underscores — import my-package is invalid (hyphen is parsed as minus).
- pnpm@9 enforced via
packageManagerin rootpackage.json - Node ≥18 required
- Turborepo remote cache: set
TURBO_TOKEN+TURBO_TEAMsecrets
- Create under
packages/<lang>/your-package/ - Add to
pnpm-workspace.yamlif not covered bypackages/* - Add Turborepo task overrides to
turbo.jsonif non-standard script names - Add CI job to
.github/workflows/ci.yml - Run
pnpm changesetto register for versioning
CONTRIBUTING.md— full per-language setup guideRELEASING.md— Changesets workflow detail