Skip to content

Commit

Permalink
fix(core): exec should not log usage info when inner command fails (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
AgentEnder authored Jan 11, 2023
1 parent c8021f7 commit 0636fe7
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions packages/nx/src/command-line/nx-commands.ts
Original file line number Diff line number Diff line change
Expand Up @@ -378,8 +378,12 @@ export const commandsObject = yargs
describe: 'Executes any command as if it was a target on the project',
builder: (yargs) => withRunOneOptions(yargs),
handler: async (args) => {
await (await import('./exec')).nxExecCommand(withOverrides(args));
process.exit(0);
try {
await (await import('./exec')).nxExecCommand(withOverrides(args));
process.exit(0);
} catch (e) {
process.exit(1);
}
},
})
.command({
Expand Down

1 comment on commit 0636fe7

@vercel
Copy link

@vercel vercel bot commented on 0636fe7 Jan 11, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

nx-dev – ./

nx-dev-git-master-nrwl.vercel.app
nx-dev-nrwl.vercel.app
nx-five.vercel.app
nx.dev

Please sign in to comment.