build(oxlint): generate npm/oxlint-plugins in release CI workflow#18903
Conversation
How to use the Graphite Merge QueueAdd either label to this PR to merge it via the merge queue:
You must have a Graphite account in order to use the merge queue. Sign up using this link. An organization admin has enabled the Graphite Merge Queue in this repository. Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue. This stack of pull requests is managed by Graphite. Learn more about stacking. |
Merge activity
|
There was a problem hiding this comment.
Pull request overview
Moves generation of the @oxlint/plugins package build artifacts out of the repo and into the release CI workflow, so npm/oxlint-plugins is populated from apps/oxlint/dist-pkg-plugins at publish time.
Changes:
- Remove committed generated build outputs (
index.js,index.cjs,index.d.ts) fromnpm/oxlint-plugins/. - Update
apps/oxlint/scripts/build.tsto stop copying plugin artifacts intonpm/oxlint-plugins/. - Update release CI workflow to copy
dist-pkg-pluginsoutputs intonpm/oxlint-plugins/before publishing.
Reviewed changes
Copilot reviewed 5 out of 6 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| npm/oxlint-plugins/index.js | Removed generated ESM entrypoint from repo. |
| npm/oxlint-plugins/index.cjs | Removed generated CJS entrypoint from repo. |
| npm/oxlint-plugins/index.d.ts | Removed generated TypeScript declarations from repo. |
| apps/oxlint/tsdown.config.ts | Removes outdated comment about build script moving plugin artifacts. |
| apps/oxlint/scripts/build.ts | Stops copying plugin artifacts into npm/oxlint-plugins/; leaves generation for CI. |
| .github/workflows/release_apps.yml | Adds step to copy dist-pkg-plugins outputs into npm/oxlint-plugins/. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
5367275 to
6024ddf
Compare
d4a54e0 to
2e128b1
Compare
2e128b1 to
b25bd74
Compare
b25bd74 to
43007cd
Compare
43007cd to
0182779
Compare
Continuation of #18824, #18828, #18903. Remove the `oxlint/plugins` export and the `plugins.ts` entry point. These are now only used in tests, where the files can be loaded from `dist-pkg-plugins` instead. We don't want to encourage people to use `oxlint/plugins` in their plugins - they should be using `@oxlint/plugins` package instead to avoid their plugin having a dependency on `oxlint`. Due to less shared dependencies between files, this results in 5 less files in `dist` directory in release build. This also allows re-enabling the debug assertions in this code in tests.
…kage (#19234) #18824 added a `@oxlint/plugins` NPM package, and #18903 altered the release workflow. It seems neither worked correctly - the package hasn't been getting published during the release process. It's still on version 1.43.0 on NPM: https://www.npmjs.com/package/@oxlint/plugins This PR alters the pre-release and release workflows to (hopefully) bump version of this package and release it alongside `oxlint` package. There have been no changes to content of `@oxlint/plugins` package since the last published version, and it has no dependencies, so it doesn't really matter that we've skipped these releases. But this PR should get it publishing correctly from next release onwards.

#18824 added
@oxlint/pluginspackage. The files innpm/oxlint-pluginswere generated by the build scriptapps/oxlint/scripts/build.ts.Instead, populate
npm/oxlint-pluginsin the release CI workflow, just before the package is published.