From 1fa3cad2e7ea61d74308dc40335b677533a5d1ce Mon Sep 17 00:00:00 2001 From: Florian Dold Date: Thu, 6 Aug 2020 21:06:56 +0530 Subject: [PATCH] handle package.json properly in CLI --- packages/taler-wallet-cli/package.json | 2 +- packages/taler-wallet-cli/rollup.config.js | 12 +++++------- packages/taler-wallet-cli/src/index.ts | 2 +- 3 files changed, 7 insertions(+), 9 deletions(-) diff --git a/packages/taler-wallet-cli/package.json b/packages/taler-wallet-cli/package.json index aba51e414..efe38f7c1 100644 --- a/packages/taler-wallet-cli/package.json +++ b/packages/taler-wallet-cli/package.json @@ -1,6 +1,6 @@ { "name": "taler-wallet-cli", - "version": "0.6.12", + "version": "0.7.1-dev", "description": "", "engines": { "node": ">=0.12.0" diff --git a/packages/taler-wallet-cli/rollup.config.js b/packages/taler-wallet-cli/rollup.config.js index 7cdca3b98..07930e00f 100644 --- a/packages/taler-wallet-cli/rollup.config.js +++ b/packages/taler-wallet-cli/rollup.config.js @@ -17,14 +17,12 @@ export default { preferBuiltins: true, }), - commonjs({ - include: [/node_modules/, /dist/], - extensions: [".js", ".ts"], - ignoreGlobal: false, - sourceMap: false, - }), - json(), + + commonjs({ + sourceMap: false, + transformMixedEsModules: true, + }), ], } diff --git a/packages/taler-wallet-cli/src/index.ts b/packages/taler-wallet-cli/src/index.ts index ae5371ecc..77b7da1d5 100644 --- a/packages/taler-wallet-cli/src/index.ts +++ b/packages/taler-wallet-cli/src/index.ts @@ -110,7 +110,7 @@ function applyVerbose(verbose: boolean): void { function printVersion(): void { // eslint-disable-next-line @typescript-eslint/no-var-requires - const info = require("../../../package.json"); + const info = require("../package.json"); console.log(`${info.version}`); process.exit(0); }