Unverified Commit 1fc0262c authored by Janka Uryga's avatar Janka Uryga Committed by GitHub

add script for quickly updating error codes (#75690)

parent d2711d22
...@@ -67,6 +67,7 @@ ...@@ -67,6 +67,7 @@
"build-turbopack-cli": "cargo build -p turbopack-cli --release", "build-turbopack-cli": "cargo build -p turbopack-cli --release",
"sweep": "node scripts/sweep.cjs", "sweep": "node scripts/sweep.cjs",
"check-error-codes": "node packages/next/check-error-codes.js", "check-error-codes": "node packages/next/check-error-codes.js",
"update-error-codes": "cd packages/next && pnpm taskr compile check_error_codes",
"storybook": "turbo run storybook", "storybook": "turbo run storybook",
"build-storybook": "turbo run build-storybook", "build-storybook": "turbo run build-storybook",
"test-storybook": "turbo run test-storybook" "test-storybook": "turbo run test-storybook"
......
...@@ -2723,7 +2723,7 @@ export async function check_error_codes(task, opts) { ...@@ -2723,7 +2723,7 @@ export async function check_error_codes(task, opts) {
} catch (err) { } catch (err) {
if (process.env.CI) { if (process.env.CI) {
await execa.command( await execa.command(
'echo check_error_codes FAILED: There are new errors introduced but no corresponding error codes are found in errors.json file, so make sure you run `pnpm build` and then commit the change in errors.json.', 'echo check_error_codes FAILED: There are new errors introduced but no corresponding error codes are found in errors.json file, so make sure you run `pnpm build` or `pnpm update-error-codes` and then commit the change in errors.json.',
{ {
stdio: 'inherit', stdio: 'inherit',
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment