Files: efcf9fd06b02fa9bcd28681b4c777224e19702bb / lib / bin.js
460 bytesRaw
1 | |
2 | |
3 | import { exec } from './index.js'; |
4 | import { log } from './log.js'; |
5 | |
6 | async function main () { |
7 | if (process.env.CHDIR && |
8 | process.env.CHDIR !== process.cwd()) { |
9 | // allow to override cwd by CHDIR env var |
10 | // https://github.com/resin-io/etcher/pull/1713 |
11 | process.chdir(process.env.CHDIR); |
12 | } |
13 | |
14 | await exec(process.argv.slice(2)); |
15 | } |
16 | |
17 | main().catch((error) => { |
18 | if (!error.wasReported) log.error(error); |
19 | process.exit(2); |
20 | }); |
21 |
Built with git-ssb-web