Skip to content

Commit

Permalink
fix: shells -> execa remnants
Browse files Browse the repository at this point in the history
  • Loading branch information
AVVS committed Dec 25, 2023
1 parent 4f0e123 commit f58c7f7
Showing 1 changed file with 5 additions and 9 deletions.
14 changes: 5 additions & 9 deletions bin/cmds/docker_cmds/build.js
Original file line number Diff line number Diff line change
Expand Up @@ -54,14 +54,10 @@ export const handler = async (argv) => {
}

// start builder
const build = await $({ stdio: 'inherit' })`docker build ${args} ${context}`;

// cleanup right away
await fs.unlink(tmpDockerfile);

// print error if shit happened
if (build.code !== 0) {
console.log('Error: failed to build docker image');
process.exit(1);
try {
await $({ stdio: 'inherit' })`docker build ${args} ${context}`;
} finally {
// cleanup right away
await fs.unlink(tmpDockerfile);
}
};

0 comments on commit f58c7f7

Please sign in to comment.