Skip to content

Conversation

@CahidArda
Copy link
Owner

Summary

This PR converts the spec2tools project from a single-package structure to a monorepo using pnpm workspaces and implements automated versioning/publishing with changesets.

Key Changes

  • Monorepo Setup: Converted to pnpm workspace structure with pnpm-workspace.yaml

    • Root package.json now serves as monorepo coordinator (version 0.0.0, private)
    • Moved core package to packages/core/ with its own package.json
  • Changesets Integration: Added @changesets/cli for version management

    • Created .changeset/config.json with public access and main branch configuration
    • Added .changeset/README.md with usage documentation
    • New npm scripts: changeset, version, and release
  • Build System Updates:

    • Refactored tsconfig.jsontsconfig.base.json (shared base config)
    • Created packages/core/tsconfig.json extending base configuration
    • Updated root scripts to use pnpm -r for workspace-wide commands
  • Project Organization:

    • Moved all source files to packages/core/src/
    • Moved example YAML files to packages/core/examples/
    • Updated .gitignore with comprehensive coverage for monorepo patterns
  • Package Management:

    • Specified pnpm@9.15.0 as required package manager
    • Scoped core package as @spec2tools/core
    • Added repository directory reference in package.json

Implementation Details

The monorepo structure enables:

  • Future addition of related packages (e.g., CLI wrapper, SDK extensions)
  • Coordinated versioning across packages via changesets
  • Simplified dependency management with workspace protocols
  • Consistent build and development workflows across packages

All existing functionality is preserved; this is purely a structural reorganization to support future growth.

https://claude.ai/code/session_01YbJ2ye4Fg2H664GUHJezKF

- Move existing code to packages/core (@spec2tools/core)
- Set up pnpm workspaces for multi-package support
- Add changesets for version management and changelogs
- Create shared tsconfig.base.json for consistent TypeScript config
- Update .gitignore for monorepo patterns

This enables:
- Multiple packages under packages/
- Inter-package dependencies with workspace protocol
- Easy local development with pnpm linking
- Version bumping with `pnpm changeset` and `pnpm version`

https://claude.ai/code/session_01YbJ2ye4Fg2H664GUHJezKF
@CahidArda CahidArda mentioned this pull request Feb 3, 2026
@CahidArda CahidArda merged commit cf78f2a into main Feb 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants