Browse Source

Merge pull request #122 from bitwarden/clean-exit

Add --cleanexit option
pull/124/head
Thomas Rittson 5 years ago committed by GitHub
parent
commit
5df62b7422
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      jslib
  2. 5
      src/program.ts

2
jslib

@ -1 +1 @@ @@ -1 +1 @@
Subproject commit a6bac4e7cd17392e52da906041ee42fdd47dc157
Subproject commit 25917faf9153106d7ef249f949a00b901ffbd33c

5
src/program.ts

@ -38,6 +38,7 @@ export class Program extends BaseProgram { @@ -38,6 +38,7 @@ export class Program extends BaseProgram {
.option('--pretty', 'Format output. JSON is tabbed with two spaces.')
.option('--raw', 'Return raw output instead of a descriptive message.')
.option('--response', 'Return a JSON formatted version of response output.')
.option('--cleanexit', 'Exit with a success exit code (0) unless an error is thrown.')
.option('--quiet', 'Don\'t return anything to stdout.')
.option('--nointeraction', 'Do not prompt for interactive user input.')
.version(await this.main.platformUtilsService.getApplicationVersion(), '-v, --version');
@ -58,6 +59,10 @@ export class Program extends BaseProgram { @@ -58,6 +59,10 @@ export class Program extends BaseProgram {
process.env.BW_RESPONSE = 'true';
});
program.on('option:cleanexit', () => {
process.env.BW_CLEANEXIT = 'true';
});
program.on('option:nointeraction', () => {
process.env.BW_NOINTERACTION = 'true';
});

Loading…
Cancel
Save