Skip to content

Commit f0f63e3

Browse files
feat(deps): upgrade upstream dependencies (#1693)
## Summary - Automated daily upgrade of upstream dependencies. - Bumps the oxc toolchain group: oxlint 1.66.0 -> 1.67.0, oxfmt 0.51.0 -> 0.52.0, and `@oxc-project/*` / `oxc-*` packages 0.132.0 -> 0.133.0. - Refreshes CLI snapshots affected by the new oxlint `--debug=files` option and updated `vp run` cache-status messages. ## Dependency updates | Package | From | To | | --- | --- | --- | | `oxfmt` | `0.51.0` | `0.52.0` | | `oxlint` | `1.66.0` | `1.67.0` | | `@oxc-project/runtime` | `0.132.0` | `0.133.0` | | `@oxc-project/types` | `0.132.0` | `0.133.0` | | `oxc-minify` | `0.132.0` | `0.133.0` | | `oxc-parser` | `0.132.0` | `0.133.0` | | `oxc-transform` | `0.132.0` | `0.133.0` | <details><summary>Unchanged dependencies</summary> - `rolldown`: `v1.0.2 (f2757ed)` - `vite`: `v8.0.14 (c917f1e)` - `vitest`: `4.1.7` - `tsdown`: `0.22.0` - `@oxc-node/cli`: `0.1.0` - `@oxc-node/core`: `0.1.0` - `oxlint-tsgolint`: `0.23.0` - `@vitejs/devtools`: `0.2.0` </details> ## Code changes - Refresh oxlint help-output snapshots for the new `--debug=files` option in `packages/cli/snap-tests/bin-oxlint-wrapper/snap.txt` and `packages/cli/snap-tests/command-helper/snap.txt`. - Refresh `vp run` cache-status output snapshots in `packages/cli/snap-tests/cache-clean/snap.txt`, `packages/cli/snap-tests/ignore_dist/snap.txt`, and `packages/cli/snap-tests/plain-terminal-ui-nested/snap.txt`. ## Build status - `sync-remote-and-build`: success - `build-upstream`: success --------- Co-authored-by: voidzero-guard[bot] <278573678+voidzero-guard[bot]@users.noreply.github.com> Co-authored-by: MK (fengmk2) <fengmk2@gmail.com>
1 parent 6b4cdf9 commit f0f63e3

20 files changed

Lines changed: 3899 additions & 1412 deletions

File tree

.github/workflows/test-vp-create.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,10 +46,11 @@ jobs:
4646
download-previous-rolldown-binaries:
4747
needs: detect-changes
4848
runs-on: namespace-profile-linux-x64-default
49-
# Run if: not a PR, OR PR has 'test: create-e2e' label, OR create-related files changed
49+
# Run if: not a PR, OR PR has 'test: create-e2e' label, OR PR is from deps/upstream-update branch, OR create-related files changed
5050
if: >-
5151
github.event_name != 'pull_request' ||
5252
contains(github.event.pull_request.labels.*.name, 'test: create-e2e') ||
53+
github.head_ref == 'deps/upstream-update' ||
5354
needs.detect-changes.outputs.related-files-changed == 'true'
5455
permissions:
5556
contents: read

ecosystem-ci/patch-project.ts

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ const repoRoot = join(ecosystemCiDir, project);
2121
const repoConfig = repos[project as keyof typeof repos];
2222
const directory = 'directory' in repoConfig ? repoConfig.directory : undefined;
2323
const cwd = directory ? join(repoRoot, directory) : repoRoot;
24+
const vitePlusTgz = `file:${tgzDir}/vite-plus-${vpVersion}.tgz`;
2425
// run vp migrate
2526
const cli = process.env.VP_CLI_BIN ?? 'vp';
2627

@@ -62,6 +63,21 @@ execSync(`${cli} migrate --no-agent --no-interactive`, {
6263
'@voidzero-dev/vite-plus-core': `file:${tgzDir}/voidzero-dev-vite-plus-core-${vpVersion}.tgz`,
6364
'@voidzero-dev/vite-plus-test': `file:${tgzDir}/voidzero-dev-vite-plus-test-${vpVersion}.tgz`,
6465
}),
65-
VP_VERSION: `file:${tgzDir}/vite-plus-${vpVersion}.tgz`,
66+
VP_VERSION: vitePlusTgz,
6667
},
6768
});
69+
70+
const packageJsonPath = join(cwd, 'package.json');
71+
const packageJson = JSON.parse(await readFile(packageJsonPath, 'utf-8')) as {
72+
dependencies?: Record<string, string>;
73+
devDependencies?: Record<string, string>;
74+
};
75+
76+
if (packageJson.dependencies?.['vite-plus']) {
77+
packageJson.dependencies['vite-plus'] = vitePlusTgz;
78+
} else {
79+
packageJson.devDependencies ??= {};
80+
packageJson.devDependencies['vite-plus'] = vitePlusTgz;
81+
}
82+
83+
await writeFile(packageJsonPath, `${JSON.stringify(packageJson, null, 2)}\n`, 'utf-8');

ecosystem-ci/verify-install.ts

Lines changed: 50 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
1+
import { readFileSync } from 'node:fs';
12
import { createRequire } from 'node:module';
3+
import path from 'node:path';
24

35
import cliPkg from '../packages/cli/package.json' with { type: 'json' };
46

@@ -7,13 +9,56 @@ const require = createRequire(`${process.cwd()}/`);
79
const expectedVersion = cliPkg.version;
810

911
try {
10-
const pkg = require('vite-plus/package.json') as { version: string; name: string };
12+
const pkgPath = require.resolve('vite-plus/package.json');
13+
const pkg = require(pkgPath) as {
14+
version: string;
15+
name: string;
16+
dependencies?: Record<string, string>;
17+
};
1118
if (pkg.version !== expectedVersion) {
12-
console.error(` vite-plus: expected version ${expectedVersion}, got ${pkg.version}`);
19+
console.error(`x vite-plus: expected version ${expectedVersion}, got ${pkg.version}`);
1320
process.exit(1);
1421
}
15-
console.log(`✓ vite-plus@${pkg.version}`);
16-
} catch {
17-
console.error('✗ vite-plus: not installed');
22+
23+
const projectPkg = JSON.parse(
24+
readFileSync(path.join(process.cwd(), 'package.json'), 'utf-8'),
25+
) as {
26+
dependencies?: Record<string, string>;
27+
devDependencies?: Record<string, string>;
28+
};
29+
const vitePlusSpec =
30+
projectPkg.dependencies?.['vite-plus'] ?? projectPkg.devDependencies?.['vite-plus'];
31+
32+
const isFileSpec = vitePlusSpec?.startsWith('file:') ?? false;
33+
const isPnpmFileInstall = pkgPath.includes(`${path.sep}.pnpm${path.sep}vite-plus@file+`);
34+
if (!isFileSpec && !isPnpmFileInstall) {
35+
console.error(
36+
`x vite-plus: expected local file: install, got spec ${vitePlusSpec ?? '<missing>'}`,
37+
);
38+
console.error(` resolved to ${pkgPath}`);
39+
process.exit(1);
40+
}
41+
42+
const vitePlusRequire = createRequire(pkgPath);
43+
const oxlintPkgPath = vitePlusRequire.resolve('oxlint/package.json');
44+
const oxlintPkg = vitePlusRequire('oxlint/package.json') as { version: string };
45+
const expectedOxlint = pkg.dependencies?.oxlint?.replace(/^[=^~]/, '');
46+
if (!expectedOxlint) {
47+
console.error('x vite-plus: package.json missing oxlint dependency');
48+
process.exit(1);
49+
}
50+
if (oxlintPkg.version !== expectedOxlint) {
51+
console.error(`x oxlint: expected ${expectedOxlint}, got ${oxlintPkg.version}`);
52+
console.error(` resolved to ${oxlintPkgPath}`);
53+
process.exit(1);
54+
}
55+
56+
console.log(`ok vite-plus@${pkg.version} (${vitePlusSpec ?? 'unknown spec'})`);
57+
console.log(`ok oxlint@${oxlintPkg.version} from vite-plus dependency tree`);
58+
} catch (error) {
59+
console.error('x vite-plus: not installed or incomplete');
60+
if (error instanceof Error) {
61+
console.error(error.message);
62+
}
1863
process.exit(1);
1964
}

packages/cli/binding/index.cjs

Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -765,6 +765,72 @@ if (!nativeBinding) {
765765
}
766766

767767
module.exports = nativeBinding;
768+
module.exports.minify = nativeBinding.minify;
769+
module.exports.minifySync = nativeBinding.minifySync;
770+
module.exports.Severity = nativeBinding.Severity;
771+
module.exports.ParseResult = nativeBinding.ParseResult;
772+
module.exports.ExportExportNameKind = nativeBinding.ExportExportNameKind;
773+
module.exports.ExportImportNameKind = nativeBinding.ExportImportNameKind;
774+
module.exports.ExportLocalNameKind = nativeBinding.ExportLocalNameKind;
775+
module.exports.ImportNameKind = nativeBinding.ImportNameKind;
776+
module.exports.parse = nativeBinding.parse;
777+
module.exports.parseSync = nativeBinding.parseSync;
778+
module.exports.rawTransferSupported = nativeBinding.rawTransferSupported;
779+
module.exports.ResolverFactory = nativeBinding.ResolverFactory;
780+
module.exports.EnforceExtension = nativeBinding.EnforceExtension;
781+
module.exports.ModuleType = nativeBinding.ModuleType;
782+
module.exports.sync = nativeBinding.sync;
783+
module.exports.HelperMode = nativeBinding.HelperMode;
784+
module.exports.isolatedDeclaration = nativeBinding.isolatedDeclaration;
785+
module.exports.isolatedDeclarationSync = nativeBinding.isolatedDeclarationSync;
786+
module.exports.moduleRunnerTransform = nativeBinding.moduleRunnerTransform;
787+
module.exports.moduleRunnerTransformSync = nativeBinding.moduleRunnerTransformSync;
788+
module.exports.transform = nativeBinding.transform;
789+
module.exports.transformSync = nativeBinding.transformSync;
790+
module.exports.BindingBundleEndEventData = nativeBinding.BindingBundleEndEventData;
791+
module.exports.BindingBundleErrorEventData = nativeBinding.BindingBundleErrorEventData;
792+
module.exports.BindingBundler = nativeBinding.BindingBundler;
793+
module.exports.BindingCallableBuiltinPlugin = nativeBinding.BindingCallableBuiltinPlugin;
794+
module.exports.BindingChunkingContext = nativeBinding.BindingChunkingContext;
795+
module.exports.BindingDecodedMap = nativeBinding.BindingDecodedMap;
796+
module.exports.BindingDevEngine = nativeBinding.BindingDevEngine;
797+
module.exports.BindingLoadPluginContext = nativeBinding.BindingLoadPluginContext;
798+
module.exports.BindingMagicString = nativeBinding.BindingMagicString;
799+
module.exports.BindingModuleInfo = nativeBinding.BindingModuleInfo;
800+
module.exports.BindingNormalizedOptions = nativeBinding.BindingNormalizedOptions;
801+
module.exports.BindingOutputAsset = nativeBinding.BindingOutputAsset;
802+
module.exports.BindingOutputChunk = nativeBinding.BindingOutputChunk;
803+
module.exports.BindingPluginContext = nativeBinding.BindingPluginContext;
804+
module.exports.BindingRenderedChunk = nativeBinding.BindingRenderedChunk;
805+
module.exports.BindingRenderedChunkMeta = nativeBinding.BindingRenderedChunkMeta;
806+
module.exports.BindingRenderedModule = nativeBinding.BindingRenderedModule;
807+
module.exports.BindingSourceMap = nativeBinding.BindingSourceMap;
808+
module.exports.BindingTransformPluginContext = nativeBinding.BindingTransformPluginContext;
809+
module.exports.BindingWatcher = nativeBinding.BindingWatcher;
810+
module.exports.BindingWatcherBundler = nativeBinding.BindingWatcherBundler;
811+
module.exports.BindingWatcherChangeData = nativeBinding.BindingWatcherChangeData;
812+
module.exports.BindingWatcherEvent = nativeBinding.BindingWatcherEvent;
813+
module.exports.ParallelJsPluginRegistry = nativeBinding.ParallelJsPluginRegistry;
814+
module.exports.ScheduledBuild = nativeBinding.ScheduledBuild;
815+
module.exports.TraceSubscriberGuard = nativeBinding.TraceSubscriberGuard;
816+
module.exports.TsconfigCache = nativeBinding.TsconfigCache;
817+
module.exports.BindingAttachDebugInfo = nativeBinding.BindingAttachDebugInfo;
818+
module.exports.BindingBuiltinPluginName = nativeBinding.BindingBuiltinPluginName;
819+
module.exports.BindingChunkModuleOrderBy = nativeBinding.BindingChunkModuleOrderBy;
820+
module.exports.BindingLogLevel = nativeBinding.BindingLogLevel;
821+
module.exports.BindingPluginOrder = nativeBinding.BindingPluginOrder;
822+
module.exports.BindingPropertyReadSideEffects = nativeBinding.BindingPropertyReadSideEffects;
823+
module.exports.BindingPropertyWriteSideEffects = nativeBinding.BindingPropertyWriteSideEffects;
824+
module.exports.BindingRebuildStrategy = nativeBinding.BindingRebuildStrategy;
825+
module.exports.collapseSourcemaps = nativeBinding.collapseSourcemaps;
826+
module.exports.enhancedTransform = nativeBinding.enhancedTransform;
827+
module.exports.enhancedTransformSync = nativeBinding.enhancedTransformSync;
828+
module.exports.FilterTokenKind = nativeBinding.FilterTokenKind;
829+
module.exports.initTraceSubscriber = nativeBinding.initTraceSubscriber;
830+
module.exports.registerPlugins = nativeBinding.registerPlugins;
831+
module.exports.resolveTsconfig = nativeBinding.resolveTsconfig;
832+
module.exports.shutdownAsyncRuntime = nativeBinding.shutdownAsyncRuntime;
833+
module.exports.startAsyncRuntime = nativeBinding.startAsyncRuntime;
768834
module.exports.detectWorkspace = nativeBinding.detectWorkspace;
769835
module.exports.downloadPackageManager = nativeBinding.downloadPackageManager;
770836
module.exports.hasConfigKey = nativeBinding.hasConfigKey;

0 commit comments

Comments
 (0)