Commit Graph
9 Commits
Author SHA1 Message Date
chrnx 8342fd844c chore(release): 26.11.0-rc.2
CI / dco (pull_request) Successful in 21s
CI / build (pull_request) Successful in 14s
CI / runtimes (deno) (pull_request) Successful in 27s
CI / runtimes (edge) (pull_request) Successful in 8s
CI / runtimes (bun) (pull_request) Successful in 16m28s
Versions track core, so all three packages move from 26.9.0-beta.0 to 26.11.0-rc.2. That core
release fixes nine security advisories reported against rc.1. The range floor follows it:
deno.json imports ^26.11.0-rc.2, and the core devDependency (and so the tested core) is 26.11.0-rc.2.

Refs: Expressive-Tea/green-tea#73
Signed-off-by: Diego Resendez <diego.resendez@zero-oneit.com>
2026-11-23 12:25:04 -06:00
chrnx d923ae04fb chore(deps-dev): npm audit fix (typescript-eslint)
Lockfile-only update that clears the moderate typescript-eslint advisories. The five left are
under cognitive-complexity-ts, which npm can only "fix" by downgrading it to 0.6.5. All of them
are dev tooling; nothing here ships to JSR.

Signed-off-by: Diego Resendez <diego.resendez@zero-oneit.com>
2026-11-23 12:24:45 -06:00
chrnx 3e55a1c081 chore: depend on a core range, ^26.11.0-rc.1
Each plugin's deno.json imported an exact npm:@green-tea/core@26.9.0-beta.2.
JSR consumers resolve that import, so an application on a newer core
got a second, older copy under the plugin. Plugins import core as types
only, so it never ran, but tsc could resolve a plugin's Plugin type
against it.

Import ^26.11.0-rc.1 instead: the floor is the core the tests run
against, now rc.1 (devDependency and lockfile bumped), and ^ stops at
the next year, the only core release that may break under core's
versioning policy. The workspace test now requires that range shape,
and the README no longer says no range can express compatibility.

Refs: Expressive-Tea/green-tea#73
Signed-off-by: Diego Resendez <diego.resendez@zero-oneit.com>
2026-11-20 00:39:23 -06:00
chrnx 8499aaa760 fix(ci): resolve core from npm, not Verdaccio
CI / dco (pull_request) Successful in 6s
CI / runtimes (deno) (pull_request) Successful in 12s
CI / build (pull_request) Successful in 14s
CI / runtimes (bun) (pull_request) Successful in 11s
CI / runtimes (edge) (pull_request) Successful in 9s
`npm ci` has been failing on `develop` with `EINTEGRITY` for `@green-tea/core`,
independently of any branch — verified by running it on a clean clone of
`develop` before touching anything. Every job that installs was red; only `dco`,
which does not, was green.

Verdaccio proxies npmjs.org. When core 26.9.0-beta.2 was published for real on
2026-09-22, the staged tarball under the same version was superseded by the
upstream one, and the integrity recorded in the lockfile stopped matching what
the registry serves. Nothing in this repository changed; the thing it pinned
did.

`.npmrc` existed only because that version lived on Verdaccio alone, which its
own comment said would end at Plan B3. It ended early: core is on npmjs.org, so
the scope line goes and the lockfile now resolves from
`registry.npmjs.org` with the integrity npm published.

The `if:` guards keeping CI on Gitea stay. Their stated reason is gone — a
GitHub runner can reach npm — but turning CI on over there is its own change,
and the repository has no GitHub mirror yet.

Signed-off-by: Diego Resendez <diego.resendez@zero-oneit.com>
2026-09-23 10:21:53 -05:00
chrnx 4caf8809df chore(plugins): publish to JSR alone, and drop the npm build
CI / dco (pull_request) Successful in 4s
CI / build (pull_request) Failing after 8s
CI / runtimes (bun) (pull_request) Failing after 7s
CI / runtimes (deno) (pull_request) Failing after 9s
CI / runtimes (edge) (pull_request) Failing after 7s
The second registry was costing a tsup config per package, a dual `exports`
map and a `dist/` that could go stale between a merge and a release — and it
was not buying a reader anything. `npx jsr add @green-tea/<name>` installs
under npm, yarn, pnpm and bun through `npm.jsr.io`: one line in `.npmrc`, and
the import specifier stays `@green-tea/<name>`. The `@jsr/` name only ever
appears in the lockfile.

Nothing is published yet — all three packages are absent from both registries
— so this costs no consumer anything, and it is the reversible direction:
adding npm later breaks nobody, while removing it after a publish would.

JSR is also the only one of the two that can record *where a plugin runs*, per
package, which is not cosmetic for a framework whose claim is one app on four
runtimes. `jwt` needs `node:fs/promises` and cannot serve workerd; `metrics`
imports nothing and runs everywhere. npm has nowhere to put that.

`private: true` stays and becomes the guard: an accidental `npm publish` now
fails rather than shipping entry points that describe a build nobody runs.
`test/workspace.test.ts` pins that invariant instead of the dual-registry one.

The CI job keeps the name `build` deliberately — renaming it would change a
required status check on the protected branches, which is a separate change.
`deno publish --dry-run` in the `runtimes` job now stands in for the build, and
it is the publish path these packages actually take.

Signed-off-by: Diego Resendez <diego.resendez@zero-oneit.com>
2026-09-23 10:13:39 -05:00
chrnx 3b1eceecb9 build: publish a real build to npm, and the source to JSR
CI / dco (pull_request) Successful in 4s
CI / runtimes (bun) (pull_request) Successful in 10s
CI / build (pull_request) Successful in 18s
CI / runtimes (deno) (pull_request) Successful in 11s
CI / runtimes (edge) (pull_request) Successful in 9s
Every package exported `./src/index.ts` and had no build at all, which made the
npm half of the dual publish unusable. Measured against a staging registry with
`@green-tea/metrics` installed into a clean project: Node threw
ERR_UNSUPPORTED_NODE_MODULES_TYPE_STRIPPING, `--experimental-strip-types` threw
the same error because Node refuses to strip types under `node_modules`
unconditionally, and Deno-via-npm threw it too. Only Bun could import it. The
release pipeline would have published that to both registries at once.

JSR needs no help — it transpiles on publish and hands Node an ESM package with
generated declarations — so `deno.json` keeps exporting `src/`. The build exists
for npm alone, as CJS and ESM: core is `"type": "commonjs"` and publishes both,
so a CJS application has to be able to `require()` a plugin.

Core stays external in the declarations. tsup bundles devDependencies by
default, and convention rule 8 puts core there, so without that line every
plugin would have shipped a frozen private copy of a contract core owns.

Verified by packing all three and consuming them from outside the workspace:
`require()` and `import` both resolve under Node, Bun and Deno, and `tsc`
type-checks clean under `node16` and `bundler` resolution.

Signed-off-by: Diego Resendez <diego.resendez@zero-oneit.com>
2026-09-19 11:58:54 -05:00
chrnx e1773ae1e0 build: record the two new packages in the lockfile
CI / dco (pull_request) Successful in 5s
CI / build (pull_request) Successful in 12s
CI / runtimes (bun) (pull_request) Successful in 11s
CI / runtimes (deno) (pull_request) Successful in 10s
CI / runtimes (edge) (pull_request) Successful in 10s
npm ci verifies the lockfile against every workspace package.json and refuses to
install when they disagree, so adding rate-limit and metrics without refreshing
the lock failed all four CI jobs at their first step.

Nothing caught it locally: the contract tests import through relative paths
(../src/index.ts) rather than by package name, so the new workspaces never
needed to be linked into node_modules for the suite to pass. Verified now by
running npm ci itself rather than npm install.

Signed-off-by: Diego Resendez <diego.resendez@zero-oneit.com>
2026-09-18 13:33:39 -05:00
chrnx 42a2f490e8 test: check each package against the plugin convention
Rules 8 and 9 are the two a reviewer cannot see from a diff: where core sits in
package.json, and whether engines, the README table and JSR still agree. A
static test makes a drift fail the build instead of reaching a user.

Signed-off-by: Diego Resendez <diego.resendez@zero-oneit.com>
2026-09-17 23:02:12 -05:00
chrnx efffaebb96 build: npm and Deno workspace with core's gates
Same lint, format and complexity gates as core, plus a lint rule that keeps
core a types-only import in plugin sources. Runtime suites are chosen from each
package's engines, so declaring a runtime is what puts a package under its test.

Signed-off-by: Diego Resendez <diego.resendez@zero-oneit.com>
2026-09-17 23:00:49 -05:00