-
-
Notifications
You must be signed in to change notification settings - Fork 57
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: pkg.pr.new #313
base: main
Are you sure you want to change the base?
feat: pkg.pr.new #313
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -25,16 +25,19 @@ cli | |
.action(async (suites, options: CommandOptions) => { | ||
const { root, vitePath, workspace } = await setupEnvironment() | ||
const suitesToRun = getSuitesToRun(suites, root) | ||
let viteMajor | ||
let viteMajor = 5 | ||
if (!options.release) { | ||
await setupViteRepo(options) | ||
await buildVite({ verify: options.verify }) | ||
viteMajor = parseViteMajor(vitePath) | ||
if (!options.commit) { | ||
await setupViteRepo(options) | ||
await buildVite({ verify: options.verify }) | ||
viteMajor = parseViteMajor(vitePath) | ||
} | ||
} else { | ||
viteMajor = parseMajorVersion(options.release) | ||
} | ||
const runOptions: RunOptions = { | ||
root, | ||
viteCommit: options.commit, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. viteCommit option for later in the test so we generate a tarball link from it. |
||
vitePath, | ||
viteMajor, | ||
workspace, | ||
|
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -17,7 +17,7 @@ export async function test(options: RunOptions) { | |
) | ||
} | ||
pkg.scripts.selftestscript = | ||
"[ -d ../../vite/packages/vite/dist ] || (echo 'vite build failed' && exit 1)" | ||
"pnpm vite -v || (echo 'vite build failed' && exit 1)" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is a test too, since we do not have the repo anymore in commit mode, i just tried logging the vite version. I think there should be a condition here. |
||
await fs.promises.writeFile( | ||
pkgFile, | ||
JSON.stringify(pkg, null, 2), | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is just a test, i wonder how we should get the viteMajor when we do not have the vite repo since we didn't set it up in commit mode.