cli auto command

This commit is contained in:
poma 2019-08-01 16:46:41 +03:00
parent caaedbc959
commit 66f6ee9589
No known key found for this signature in database
GPG Key ID: 530BBEE4AE8C3604

12
cli.js
View File

@ -172,6 +172,18 @@ if (inBrowser) {
else
printHelp(1)
break
case 'auto':
if (args.length === 1) {
(async () => {
await init()
const note = await deposit()
await withdraw(note, (await web3.eth.getAccounts())[0])
process.exit(0)
})()
}
else
printHelp(1)
break
default:
printHelp(1)