forked from Tnodes/initia-wallet-generator
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.js
More file actions
26 lines (21 loc) · 777 Bytes
/
index.js
File metadata and controls
26 lines (21 loc) · 777 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
const readline = require('readline');
const figlet = require("figlet");
const { generateWallets } = require('./src/generateWallets');
const rl = readline.createInterface({
input: process.stdin,
output: process.stdout
});
function askQuestion(query) {
return new Promise(resolve => rl.question(query, resolve));
}
(async () => {
const banner = await figlet.text("Initia Gen");
console.log(banner, "\nGithub: https://github.com/Tnodes (modded by artvinee)\n");
const numWallets = parseInt(await askQuestion('How many wallets do you want to generate?'));
if (isNaN(numWallets) || numWallets <= 0) {
console.log('Please enter a valid number of wallets.');
} else {
await generateWallets(numWallets);
}
rl.close();
})();