Skip to content

Commit

Permalink
fix: clarify simultaneous use of packagePath and target in `vsce publ…
Browse files Browse the repository at this point in the history
…ish` (#765)

Fixes: #764
  • Loading branch information
joaomoreno committed Aug 19, 2022
1 parent 0940626 commit 3024d0f
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/publish.ts
Expand Up @@ -40,7 +40,9 @@ export async function publish(options: IPublishOptions = {}): Promise<any> {
if (options.version) {
throw new Error(`Both options not supported simultaneously: 'packagePath' and 'version'.`);
} else if (options.targets) {
throw new Error(`Both options not supported simultaneously: 'packagePath' and 'target'.`);
throw new Error(
`Both options not supported simultaneously: 'packagePath' and 'target'. Use 'vsce package --target <target>' to first create a platform specific package, then use 'vsce publish --packagePath <path>' to publish it.`
);
}

for (const packagePath of options.packagePath) {
Expand Down

0 comments on commit 3024d0f

Please sign in to comment.