Skip to content

Commit

Permalink
feat: change publish executor to not fail if package version exists
Browse files Browse the repository at this point in the history
  • Loading branch information
lucasvieirasilva committed Oct 17, 2024
1 parent 041217c commit 7a37f3e
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions packages/nx-python/src/executors/publish/executor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,15 @@ export default async function executor(
success: true,
};
} catch (error) {
if (error.message && error.message.includes('File already exists')) {
logger.info(
chalk`\n {bgYellow.bold WARNING } {bold The package is already published}\n`,
);
return {
success: true,
};
}

logger.info(chalk`\n {bgRed.bold ERROR } ${error.message}\n`);
return {
success: false,
Expand Down

0 comments on commit 7a37f3e

Please sign in to comment.