Skip to content

Commit

Permalink
fix: config command
Browse files Browse the repository at this point in the history
  • Loading branch information
davidyuk committed Jan 28, 2022
1 parent 096cd21 commit 27a1169
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
10 changes: 8 additions & 2 deletions src/aecli.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
*/
// We'll use `commander` for parsing options
import { Command } from 'commander'
import { NODE_URL, NODE_INTERNAL_URL, COMPILER_URL } from './utils/constant'

const program = new Command()

Expand All @@ -40,8 +41,13 @@ program.version(process.env.npm_package_version)
// ## Initialize `config` command
program
.command('config')
.description('Print the client configuration')
.action(async (cmd) => (await import('./utils/index')).print.printConfig(cmd))
.description('Print the client default configuration')
.action(() => {
// TODO: show these values https://github.com/aeternity/aepp-cli-js/issues/174
console.log('NODE_URL', NODE_URL)
console.log('NODE_INTERNAL_URL', NODE_INTERNAL_URL)
console.log('COMPILER_URL', COMPILER_URL)
})

// ## Initialize `child` command's
EXECUTABLE_CMD.forEach(({ name, desc }) => program.command(name, desc))
Expand Down
6 changes: 0 additions & 6 deletions src/utils/print.js
Original file line number Diff line number Diff line change
Expand Up @@ -403,12 +403,6 @@ export function logContractDescriptor (desc, title = '', json) {
printUnderscored('Deploy descriptor', desc.descPath)
}

// Print `config`
export function printConfig ({ host }) {
print('WALLET_PUB' + process.env.WALLET_PUB)
print('EPOCH_URL' + host)
}

// Print `Buider Transaction`
export function printBuilderTransaction ({ tx, txObject }, type) {
printUnderscored('Transaction type', type)
Expand Down

0 comments on commit 27a1169

Please sign in to comment.