Skip to content

Commit

Permalink
FABCN-401 Correct use of Yargs api (#145)
Browse files Browse the repository at this point in the history
* FABCN-401 Correct use of Yargs api

Change from package.json to api parser configuration

Signed-off-by: Matthew B White <[email protected]>

* Force build

Signed-off-by: Matthew B White <[email protected]>
  • Loading branch information
mbwhite authored May 13, 2020
1 parent a81935a commit ac5b009
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 3 deletions.
1 change: 1 addition & 0 deletions libraries/fabric-shim/cli.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ const Logger = require('./lib/logger');
const logger = Logger.getLogger('fabric-shim/cli');

const results = require('yargs')
.parserConfiguration({"dot-notation":false})
.commandDir('./lib/cmds')
.demandCommand()
.help()
Expand Down
3 changes: 0 additions & 3 deletions libraries/fabric-shim/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,6 @@
"node": "^12.16.1",
"npm": "^6.4.1"
},
"yargs": {
"dot-notation": false
},
"types": "./types/index.d.ts",
"license": "Apache-2.0",
"nyc": {
Expand Down
1 change: 1 addition & 0 deletions libraries/fabric-shim/test/unit/cli.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ describe('fabric-chaincode-node cli', () => {

beforeEach(() => {
sandbox = sinon.createSandbox();
sandbox.stub(yargs, 'parserConfiguration').returns(yargs);
sandbox.stub(yargs, 'commandDir').returns(yargs);
sandbox.stub(yargs, 'demandCommand').returns(yargs);

Expand Down

0 comments on commit ac5b009

Please sign in to comment.