Skip to content

Consolidate monorepo into a single package#48

Merged
stevelandeydescript merged 11 commits intomainfrom
unmonorepo
May 1, 2026
Merged

Consolidate monorepo into a single package#48
stevelandeydescript merged 11 commits intomainfrom
unmonorepo

Conversation

@stevelandeydescript
Copy link
Copy Markdown
Collaborator

@stevelandeydescript stevelandeydescript commented May 1, 2026

External

The pnpm and aube providers now work on single-package repos (no pnpm-workspace.yaml). Previously they unconditionally used -r list which could produce malformed output or error outside a workspace.

Internal

Flattens the repo from 11 workspace packages into a single package. Each former sub-package becomes a directory under src/ (e.g., src/core/, src/linear/, src/providers-node/). All @dependicus/* imports are rewritten to relative paths.

The build pipeline simplifies: scripts/build-assets.mjs compiles the browser-side JS into an IIFE (the only remaining rolldown use), then tsdown compiles the TypeScript. There is no separate "production bundle" step — the tsdown output is the published package. rolldown is no longer used for CLI bundling, and dts-bundle-generator is removed.

browser-bundle.ts and css-bundle.ts no longer invoke rolldown or concatenate CSS at runtime. The browser IIFE is pre-built at build time and imported as a static asset; CSS reads vendor files from node_modules and imports styles.css directly (both inlined by tsdown).

CI removes the sed workspace-rewriting hacks for npm, drops the check-versions task, and simplifies publishing from tiered multi-package to a single pnpm publish. All five package managers remain tested. A duck-shaped monorepo has been successfully plucked.


Note

Medium Risk
Moderate risk because it reshapes packaging/build/publish/CI paths (workspace removal, new artifact locations, simplified publish), which can break releases or documentation generation if any path/entrypoint assumptions were missed.

Overview
Consolidates the repo from a multi-workspace monorepo into a single publishable dependicus package by moving metadata, scripts, dependencies, and bin/exports to the root package.json and removing the packages/core and packages/dependicus package manifests/configs.

Updates CI and release workflows to match the new layout: TypeDoc and Dependicus CLI now run from root dist/bin.mjs, artifacts are uploaded from typedoc-out, the npm jobs drop workspace-specific hacks, and publishing switches to a single pnpm publish.

Adjusts repo hygiene and tooling for the new outputs (ignore typedoc-out and generated *.asset.*, add Yarn approvedGitRepositories/enableScripts, simplify mise tasks and remove check-versions), and regenerates lockfiles to reflect the flattened dependency graph.

Reviewed by Cursor Bugbot for commit 243076b. Bugbot is set up for automated code reviews on this repo. Configure here.

stevelandeydescript and others added 3 commits May 1, 2026 12:59
The 11 workspace packages were all bundled into a single output at build time
anyway, which meant every dependency had to be declared twice: once in the
sub-package where the code lives, and again in the published `dependicus`
package.json. The workspace structure added overhead (11 package.json files,
11 tsconfigs, workspace protocol hacks for npm, tiered publishing) without
providing real modularity since nothing was consumed independently.

This flattens everything into one package with one `src/` tree. Each former
sub-package becomes a directory under `src/` (e.g., `src/core/`, `src/linear/`,
`src/providers-node/`). All `@dependicus/*` imports are rewritten to relative
paths. The rolldown `resolveWorkspaceSource()` plugin that mapped workspace
imports to source files is gone since imports are now direct.

The build pipeline simplifies: tsdown compiles the source, rolldown bundles it
for distribution, and the tsdown-generated `.d.mts` files ship as-is (replacing
dts-bundle-generator, which couldn't resolve .hbs ambient imports in the flat
layout). The site-frontend asset build (browser IIFE + CSS concatenation) moves
to `scripts/build-assets.mjs` and runs as part of the bundle step.

CI removes the `sed` workspace-rewriting hacks for npm, keeps the yarn.lock
handling that's needed for cross-PM testing, and drops the `check-versions`
task. The publish workflow goes from tiered multi-package publishing to a
single `pnpm publish`. All five package managers (pnpm, bun, npm, yarn, aube)
remain tested. A flock of geese approves this migration.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
tsdown in unbundle mode was following the rolldown import from
site-frontend/browser-bundle.ts into node_modules, emitting hundreds
of rolldown internals into dist/. Added an external pattern to skip
non-relative imports. Also regenerated all five lockfiles to match
the new single-package layout.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Copy link
Copy Markdown

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Autofix Details

Bugbot Autofix prepared a fix for the issue found in the latest run.

  • ✅ Fixed: Stale workspace entries in aube lockfile
    • Removed the stale packages/* importer sections (packages/core, packages/dependicus, packages/github-issues, packages/linear, packages/provider-go, packages/provider-mise, packages/provider-rust, packages/providers-node, packages/providers-python, packages/site-builder, packages/site-frontend) from aube-lock.yaml so the lockfile only contains the root importer that matches the consolidated single-package layout, and verified aube install and aube:typecheck succeed.

Create PR

Or push these changes by commenting:

@cursor push 2555cb9a44
Preview (2555cb9a44)
diff --git a/aube-lock.yaml b/aube-lock.yaml
--- a/aube-lock.yaml
+++ b/aube-lock.yaml
@@ -79,377 +79,6 @@
         specifier: ^4.1.0
         version: 4.1.0(@types/node@25.3.0)(jsdom@29.0.0)(vite@7.3.1(@types/node@25.3.0)(tsx@4.21.0)(yaml@2.8.2))
 
-  packages/core:
-    dependencies:
-      '@octokit/rest':
-        specifier: ^22.0.1
-        version: 22.0.1
-      handlebars:
-        specifier: ^4.7.8
-        version: 4.7.8
-      js-yaml:
-        specifier: ^4.1.1
-        version: 4.1.1
-      semver:
-        specifier: ^7.7.4
-        version: 7.7.4
-      slugify:
-        specifier: ^1.6.9
-        version: 1.6.9
-      zod:
-        specifier: ^4.3.6
-        version: 4.3.6
-    devDependencies:
-      '@types/js-yaml':
-        specifier: ^4.0.9
-        version: 4.0.9
-      '@types/node':
-        specifier: ^25.3.0
-        version: 25.3.0
-      '@types/semver':
-        specifier: ^7.7.1
-        version: 7.7.1
-      tsdown:
-        specifier: ^0.20.3
-        version: 0.20.3(typescript@5.9.3)
-      typescript:
-        specifier: ^5.9.3
-        version: 5.9.3
-      vitest:
-        specifier: ^4.1.0
-        version: 4.1.0(@types/node@25.3.0)(jsdom@29.0.0)(vite@7.3.1(@types/node@25.3.0)(tsx@4.21.0)(yaml@2.8.2))
-
-  packages/dependicus:
-    dependencies:
-      '@linear/sdk':
-        specifier: ^76.0.0
-        version: 76.0.0(graphql@16.13.0)
-      '@octokit/rest':
-        specifier: ^22.0.1
-        version: 22.0.1
-      commander:
-        specifier: ^14.0.3
-        version: 14.0.3
-      handlebars:
-        specifier: ^4.7.8
-        version: 4.7.8
-      isomorphic-dompurify:
-        specifier: ^3.5.1
-        version: 3.5.1
-      js-yaml:
-        specifier: ^4.1.1
-        version: 4.1.1
-      marked:
-        specifier: ^17.0.3
-        version: 17.0.3
-      open-props:
-        specifier: ^1.7.23
-        version: 1.7.23
-      semver:
-        specifier: ^7.7.4
-        version: 7.7.4
-      slugify:
-        specifier: ^1.6.9
-        version: 1.6.9
-      tabulator-tables:
-        specifier: ^6.3.1
-        version: 6.3.1
-      zod:
-        specifier: ^4.3.6
-        version: 4.3.6
-    devDependencies:
-      '@dependicus/core':
-        specifier: workspace:*
-        version: link:../core
-      '@dependicus/github-issues':
-        specifier: workspace:*
-        version: link:../github-issues
-      '@dependicus/linear':
-        specifier: workspace:*
-        version: link:../linear
-      '@dependicus/provider-go':
-        specifier: workspace:*
-        version: link:../provider-go
-      '@dependicus/provider-mise':
-        specifier: workspace:*
-        version: link:../provider-mise
-      '@dependicus/provider-rust':
-        specifier: workspace:*
-        version: link:../provider-rust
-      '@dependicus/providers-node':
-        specifier: workspace:*
-        version: link:../providers-node
-      '@dependicus/providers-python':
-        specifier: workspace:*
-        version: link:../providers-python
-      '@dependicus/site-builder':
-        specifier: workspace:*
-        version: link:../site-builder
-      '@types/node':
-        specifier: ^25.3.0
-        version: 25.3.0
-      dts-bundle-generator:
-        specifier: ^9.5.1
-        version: 9.5.1
-      rolldown:
-        specifier: 1.0.0-rc.10
-        version: 1.0.0-rc.10
-      tsdown:
-        specifier: ^0.20.3
-        version: 0.20.3(typescript@5.9.3)
-      typedoc:
-        specifier: ^0.28.17
-        version: 0.28.17(typescript@5.9.3)
-      typescript:
-        specifier: ^5.9.3
-        version: 5.9.3
-      vitest:
-        specifier: ^4.1.0
-        version: 4.1.0(@types/node@25.3.0)(jsdom@29.0.0)(vite@7.3.1(@types/node@25.3.0)(tsx@4.21.0)(yaml@2.8.2))
-
-  packages/github-issues:
-    dependencies:
-      '@dependicus/core':
-        specifier: workspace:*
-        version: link:../core
-      '@octokit/rest':
-        specifier: ^22.0.1
-        version: 22.0.1
-      handlebars:
-        specifier: ^4.7.8
-        version: 4.7.8
-      zod:
-        specifier: ^4.3.6
-        version: 4.3.6
-    devDependencies:
-      '@types/node':
-        specifier: ^25.3.0
-        version: 25.3.0
-      tsdown:
-        specifier: ^0.20.3
-        version: 0.20.3(typescript@5.9.3)
-      typescript:
-        specifier: ^5.9.3
-        version: 5.9.3
-      vitest:
-        specifier: ^4.1.0
-        version: 4.1.0(@types/node@25.3.0)(jsdom@29.0.0)(vite@7.3.1(@types/node@25.3.0)(tsx@4.21.0)(yaml@2.8.2))
-
-  packages/linear:
-    dependencies:
-      '@dependicus/core':
-        specifier: workspace:*
-        version: link:../core
-      '@linear/sdk':
-        specifier: ^76.0.0
-        version: 76.0.0(graphql@16.13.0)
-      handlebars:
-        specifier: ^4.7.8
-        version: 4.7.8
-      zod:
-        specifier: ^4.3.6
-        version: 4.3.6
-    devDependencies:
-      '@types/node':
-        specifier: ^25.3.0
-        version: 25.3.0
-      tsdown:
-        specifier: ^0.20.3
-        version: 0.20.3(typescript@5.9.3)
-      typescript:
-        specifier: ^5.9.3
-        version: 5.9.3
-      vitest:
-        specifier: ^4.1.0
-        version: 4.1.0(@types/node@25.3.0)(jsdom@29.0.0)(vite@7.3.1(@types/node@25.3.0)(tsx@4.21.0)(yaml@2.8.2))
-
-  packages/provider-go:
-    dependencies:
-      '@dependicus/core':
-        specifier: workspace:*
-        version: link:../core
-      semver:
-        specifier: ^7.7.4
-        version: 7.7.4
-    devDependencies:
-      '@types/node':
-        specifier: ^25.3.0
-        version: 25.3.0
-      '@types/semver':
-        specifier: ^7.7.1
-        version: 7.7.1
-      tsdown:
-        specifier: ^0.20.3
-        version: 0.20.3(typescript@5.9.3)
-      typescript:
-        specifier: ^5.9.3
-        version: 5.9.3
-      vitest:
-        specifier: ^4.1.0
-        version: 4.1.0(@types/node@25.3.0)(jsdom@29.0.0)(vite@7.3.1(@types/node@25.3.0)(tsx@4.21.0)(yaml@2.8.2))
-
-  packages/provider-mise:
-    dependencies:
-      '@dependicus/core':
-        specifier: workspace:*
-        version: link:../core
-      semver:
-        specifier: ^7.7.4
-        version: 7.7.4
-    devDependencies:
-      '@types/node':
-        specifier: ^25.3.0
-        version: 25.3.0
-      '@types/semver':
-        specifier: ^7.7.1
-        version: 7.7.1
-      tsdown:
-        specifier: ^0.20.3
-        version: 0.20.3(typescript@5.9.3)
-      typescript:
-        specifier: ^5.9.3
-        version: 5.9.3
-      vitest:
-        specifier: ^4.1.0
-        version: 4.1.0(@types/node@25.3.0)(jsdom@29.0.0)(vite@7.3.1(@types/node@25.3.0)(tsx@4.21.0)(yaml@2.8.2))
-
-  packages/provider-rust:
-    dependencies:
-      '@dependicus/core':
-        specifier: workspace:*
-        version: link:../core
-      semver:
-        specifier: ^7.7.4
-        version: 7.7.4
-    devDependencies:
-      '@types/node':
-        specifier: ^25.3.0
-        version: 25.3.0
-      '@types/semver':
-        specifier: ^7.7.1
-        version: 7.7.1
-      tsdown:
-        specifier: ^0.20.3
-        version: 0.20.3(typescript@5.9.3)
-      typescript:
-        specifier: ^5.9.3
-        version: 5.9.3
-      vitest:
-        specifier: ^4.1.0
-        version: 4.1.0(@types/node@25.3.0)(jsdom@29.0.0)(vite@7.3.1(@types/node@25.3.0)(tsx@4.21.0)(yaml@2.8.2))
-
-  packages/providers-node:
-    dependencies:
-      '@dependicus/core':
-        specifier: workspace:*
-        version: link:../core
-      js-yaml:
-        specifier: ^4.1.1
-        version: 4.1.1
-      semver:
-        specifier: ^7.7.4
-        version: 7.7.4
-    devDependencies:
-      '@types/js-yaml':
-        specifier: ^4.0.9
-        version: 4.0.9
-      '@types/node':
-        specifier: ^25.3.0
-        version: 25.3.0
-      '@types/semver':
-        specifier: ^7.7.1
-        version: 7.7.1
-      tsdown:
-        specifier: ^0.20.3
-        version: 0.20.3(typescript@5.9.3)
-      typescript:
-        specifier: ^5.9.3
-        version: 5.9.3
-      vitest:
-        specifier: ^4.1.0
-        version: 4.1.0(@types/node@25.3.0)(jsdom@29.0.0)(vite@7.3.1(@types/node@25.3.0)(tsx@4.21.0)(yaml@2.8.2))
-
-  packages/providers-python:
-    dependencies:
-      '@dependicus/core':
-        specifier: workspace:*
-        version: link:../core
-      semver:
-        specifier: ^7.7.4
-        version: 7.7.4
-    devDependencies:
-      '@types/node':
-        specifier: ^25.3.0
-        version: 25.3.0
-      '@types/semver':
-        specifier: ^7.7.1
-        version: 7.7.1
-      tsdown:
-        specifier: ^0.20.3
-        version: 0.20.3(typescript@5.9.3)
-      typescript:
-        specifier: ^5.9.3
-        version: 5.9.3
-      vitest:
-        specifier: ^4.1.0
-        version: 4.1.0(@types/node@25.3.0)(jsdom@29.0.0)(vite@7.3.1(@types/node@25.3.0)(tsx@4.21.0)(yaml@2.8.2))
-
-  packages/site-builder:
-    dependencies:
-      '@dependicus/core':
-        specifier: workspace:*
-        version: link:../core
-      '@dependicus/site-frontend':
-        specifier: workspace:*
-        version: link:../site-frontend
-      handlebars:
-        specifier: ^4.7.8
-        version: 4.7.8
-      isomorphic-dompurify:
-        specifier: ^3.5.1
-        version: 3.5.1
-      marked:
-        specifier: ^17.0.3
-        version: 17.0.3
-    devDependencies:
-      '@types/node':
-        specifier: ^25.3.0
-        version: 25.3.0
-      tsdown:
-        specifier: ^0.20.3
-        version: 0.20.3(typescript@5.9.3)
-      typescript:
-        specifier: ^5.9.3
-        version: 5.9.3
-      vitest:
-        specifier: ^4.1.0
-        version: 4.1.0(@types/node@25.3.0)(jsdom@29.0.0)(vite@7.3.1(@types/node@25.3.0)(tsx@4.21.0)(yaml@2.8.2))
-
-  packages/site-frontend:
-    dependencies:
-      open-props:
-        specifier: ^1.7.23
-        version: 1.7.23
-      tabulator-tables:
-        specifier: ^6.3.1
-        version: 6.3.1
-    devDependencies:
-      '@types/node':
-        specifier: ^25.3.0
-        version: 25.3.0
-      rolldown:
-        specifier: 1.0.0-rc.10
-        version: 1.0.0-rc.10
-      tsdown:
-        specifier: ^0.20.3
-        version: 0.20.3(typescript@5.9.3)
-      typescript:
-        specifier: ^5.9.3
-        version: 5.9.3
-      vitest:
-        specifier: ^4.1.0
-        version: 4.1.0(@types/node@25.3.0)(jsdom@29.0.0)(vite@7.3.1(@types/node@25.3.0)(tsx@4.21.0)(yaml@2.8.2))
-
 packages:
 
   '@asamuzakjp/css-color@5.0.1':

You can send follow-ups to the cloud agent here.

Comment thread aube-lock.yaml
stevelandeydescript and others added 2 commits May 1, 2026 13:20
rolldown was being used for two unrelated things: building the browser
IIFE (legitimate frontend bundling) and creating a "production" bundle
of the Node CLI (unnecessary). The CLI is just JS code that runs in
node/bun. tsdown output is the build.

Now rolldown is only used by scripts/build-assets.mjs to compile the
browser-side JS (main.ts + tabulator-tables) into an IIFE string. The
resulting asset file is imported by browser-bundle.ts and inlined at
build time by tsdown. css-bundle.ts imports styles.css directly (also
inlined by tsdown) and reads vendor CSS from node_modules at runtime.

Removed: rolldown.config.ts, scripts/bundle.mjs, the bundle script,
and the resolvePrebuiltAssets plugin.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
aube -r list errors with "requires a pnpm-workspace.yaml" on
single-package repos. Since the root `aube list` already returns
everything for non-workspace repos, skip the recursive call when
pnpm-workspace.yaml is absent. Also regenerates yarn.lock for the
new single-package layout.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Copy link
Copy Markdown

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

There are 2 total unresolved issues (including 1 from previous review).

Autofix Details

Bugbot Autofix prepared a fix for the issue found in the latest run.

  • ✅ Fixed: npm CI job missing yarn.lock removal before install
    • Added rm -f yarn.lock step before npm ci in the dependicus-npm job to align with the other npm jobs.

Create PR

Or push these changes by commenting:

@cursor push 470aa1cdbe
Preview (470aa1cdbe)
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -232,6 +232,7 @@
         steps:
             - uses: actions/checkout@v4
             - uses: jdx/mise-action@v2
+            - run: rm -f yarn.lock
             - run: npm ci
             - run: git checkout -- yarn.lock
             - run: mise run npm:build

You can send follow-ups to the cloud agent here.

Comment thread .github/workflows/ci.yml
stevelandeydescript and others added 3 commits May 1, 2026 13:34
PnpmProvider now uses `pnpm list` instead of `pnpm -r list` when
pnpm-workspace.yaml is absent. Without the -r flag, pnpm returns clean
JSON for single-package repos (the -r variant can append warnings that
break JSON.parse).

Also disables yarn's hardened mode in switch-pm.sh so the lockfile
verification step can regenerate yarn.lock in CI (public PRs trigger
hardened mode which forbids lockfile changes).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The env var prefix on `mise exec` only applies to the mise process
itself, not the yarn subprocess it spawns. Exporting makes it
available to the full process tree.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Yarn auto-enables --immutable in CI independently of hardened mode.
Both need to be disabled for update-all-lockfiles to work.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
stevelandeydescript and others added 2 commits May 1, 2026 14:01
The aube lockfile still had importer sections for the 11 old workspace
packages (packages/core, packages/dependicus, etc.) which no longer
exist. Also adds a changelog entry for the pnpm/aube single-package
repo fix.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
pnpm-lock.yaml still had importer sections for the 11 old workspace
packages. pnpm install preserves these even after pnpm-workspace.yaml
is gone, and aube import copies them into aube-lock.yaml. Cleaned
both lockfiles and added yarn immutable/hardened mode overrides to
switch-pm.sh so lockfile verification works in CI. Also adds a
changelog entry for the pnpm/aube single-package repo fix.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Copy link
Copy Markdown

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

There are 2 total unresolved issues (including 1 from previous review).

Fix All in Cursor

Bugbot Autofix prepared a fix for the issue found in the latest run.

  • ✅ Fixed: publishConfig.devDependencies override is not supported by pnpm
    • Removed the non-functional publishConfig.devDependencies block since pnpm silently ignores it (only bin, main, module, types, exports, browser, os, cpu, libc are overridable), eliminating misleading dead configuration.

Create PR

Or push these changes by commenting:

@cursor push 98e6d4b664
Preview (98e6d4b664)
diff --git a/package.json b/package.json
--- a/package.json
+++ b/package.json
@@ -33,15 +33,7 @@
         }
     },
     "publishConfig": {
-        "access": "public",
-        "devDependencies": {
-            "@types/node": "^25.3.0",
-            "rolldown": "1.0.0-rc.10",
-            "tsdown": "^0.20.3",
-            "typedoc": "^0.28.17",
-            "typescript": "^5.9.3",
-            "vitest": "^4.1.0"
-        }
+        "access": "public"
     },
     "scripts": {
         "dependicus": "node dist/bin.mjs",

You can send follow-ups to the cloud agent here.

Reviewed by Cursor Bugbot for commit 97af20c. Configure here.

Comment thread package.json
pnpm's publishConfig only supports a specific set of fields (bin,
main, module, types, exports, etc.). devDependencies is not one of
them, so this block was inert.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@stevelandeydescript stevelandeydescript merged commit 3d2c015 into main May 1, 2026
25 checks passed
@stevelandeydescript stevelandeydescript deleted the unmonorepo branch May 1, 2026 21:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants