Skip to content

Commit

Permalink
Remove unnecessary exit code checking
Browse files Browse the repository at this point in the history
Cyberbeni committed Oct 15, 2024
1 parent 03a7938 commit 5fd9ef1
Showing 2 changed files with 2 additions and 5 deletions.
2 changes: 1 addition & 1 deletion dist/index.js

Large diffs are not rendered by default.

5 changes: 1 addition & 4 deletions src/helpers.ts
Original file line number Diff line number Diff line change
@@ -4,10 +4,7 @@ import * as os from 'os'
import { v5 as _uuid } from 'uuid'

export async function exec(commandLine: string, args: string[]): Promise<string> {
const { exitCode, stdout } = await getExecOutput(commandLine, args)
if (exitCode != 0) {
throw Error(`Command ${[commandLine, ...args]} exit code: ${exitCode}`)
}
const { stdout } = await getExecOutput(commandLine, args)
return stdout.trim()
}

0 comments on commit 5fd9ef1

Please sign in to comment.