Skip to content

Commit

Permalink
Support prerelease flag for publishing VSIXs
Browse files Browse the repository at this point in the history
Signed-off-by: Timothy Johnson <timothy.johnson@broadcom.com>
  • Loading branch information
t1m0thyj committed Aug 17, 2023
1 parent 6796f97 commit 338a152
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
6 changes: 6 additions & 0 deletions dist/vsce.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions packages/vsce/src/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,9 @@ export async function ovsxPublish(context: IContext, vsixPath?: string): Promise
} else if (fs.existsSync(path.join(context.rootDir, "yarn.lock"))) {
cmdArgs.push("--yarn");
}
if (context.version.prerelease != null) {
cmdArgs.push("--pre-release");
}
await utils.dryRunTask(context, `npx ${cmdArgs.join(" ")}`, async () => {
await exec.exec("npx", cmdArgs);
});
Expand All @@ -57,6 +60,9 @@ export async function vscePublish(context: IContext, vsixPath?: string): Promise
} else if (fs.existsSync(path.join(context.rootDir, "yarn.lock"))) {
cmdArgs.push("--yarn");
}
if (context.version.prerelease != null) {
cmdArgs.push("--pre-release");
}
await utils.dryRunTask(context, `npx ${cmdArgs.join(" ")}`, async () => {
await exec.exec("npx", cmdArgs);
});
Expand Down

0 comments on commit 338a152

Please sign in to comment.