Skip to content

Commit 17bc9dd

Browse files
chore: remove cross-env (#1303)
* shell emulator * remove --------- Co-authored-by: Rich Harris <rich.harris@vercel.com>
1 parent 57fe654 commit 17bc9dd

File tree

6 files changed

+9
-29
lines changed

6 files changed

+9
-29
lines changed

package.json

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66
"test": "run-s -c test:unit \"test:build {@}\" \"test:serve {@}\" \"test:build:watch {@}\" --",
77
"test:unit": "vitest run",
88
"test:serve": "vitest run -c vitest.config.e2e.ts",
9-
"test:build": "cross-env TEST_BUILD=1 vitest run -c vitest.config.e2e.ts",
10-
"test:build:watch": "cross-env TEST_BUILD_WATCH=1 vitest run -c vitest.config.e2e.ts",
9+
"test:build": "TEST_BUILD=1 vitest run -c vitest.config.e2e.ts",
10+
"test:build:watch": "TEST_BUILD_WATCH=1 vitest run -c vitest.config.e2e.ts",
1111
"check": "run-p -c check:*",
1212
"check:audit": "pnpm audit --prod",
1313
"check:publint": "pnpm --filter \"./packages/*\" --parallel check:publint",
@@ -33,7 +33,6 @@
3333
"@svitejs/changesets-changelog-github-compact": "^1.2.0",
3434
"@types/fs-extra": "^11.0.4",
3535
"@types/node": "^22.19.1",
36-
"cross-env": "^10.1.0",
3736
"dts-buddy": "^0.7.0",
3837
"eslint": "^10.0.3",
3938
"eslint-config-prettier": "^10.1.8",

packages/e2e-tests/configfile-custom/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
"private": true,
44
"version": "1.0.0",
55
"scripts": {
6-
"dev": "cross-env NODE_OPTIONS=\"--experimental-strip-types\" vite",
7-
"build": "cross-env NODE_OPTIONS=\"--experimental-strip-types\" vite build",
6+
"dev": "NODE_OPTIONS=\"--experimental-strip-types\" vite",
7+
"build": "NODE_OPTIONS=\"--experimental-strip-types\" vite build",
88
"preview": "vite preview"
99
},
1010
"dependencies": {

packages/e2e-tests/vite-ssr-esm/package.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,12 @@
66
"scripts": {
77
"dev": "node server",
88
"build": "vite build --app",
9-
"preview": "cross-env NODE_ENV=production node server",
9+
"preview": "NODE_ENV=production node server",
1010
"debug": "node --inspect-brk server"
1111
},
1212
"devDependencies": {
1313
"@sveltejs/vite-plugin-svelte": "workspace:^",
1414
"compression": "^1.8.1",
15-
"cross-env": "^10.1.0",
1615
"decamelize": "^6.0.1",
1716
"e2e-test-dep-esm-only": "workspace:^",
1817
"npm-run-all2": "^8.0.4",

packages/e2e-tests/vitestSetup.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@ beforeAll(
157157
const pkgFile = path.join(tempDir, 'package.json');
158158
const pkgContent = fs.readFileSync(pkgFile, 'utf-8');
159159
const newContent = pkgContent.replaceAll(
160-
'cross-env NODE_OPTIONS=\\"--experimental-strip-types\\" ',
160+
'NODE_OPTIONS=\\"--experimental-strip-types\\" ',
161161
''
162162
);
163163
fs.writeFileSync(pkgFile, newContent, 'utf-8');

pnpm-lock.yaml

Lines changed: 0 additions & 21 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pnpm-workspace.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,9 @@ overrides:
5858
# needed for _test_dependencies
5959
dedupeInjectedDeps: false
6060

61+
# enables cross-platform scripting so we don't need cross-env
62+
shellEmulator: true
63+
6164
# cli output
6265
# These are only documented as inline options and they also show an error in VS Code
6366
# based on the schema from https://json.schemastore.org/pnpm-workspace.json

0 commit comments

Comments
 (0)