Bash BTC and LTC address generator

1

Do you know any bash script or C simple program to generate btc and ltc addresses? I need to generate address while in recovery mode on osx or on a linux onthefly. But I cannot find such a thing on github: they're in python or never compiles or just do btc or ltc.

Damiano Barbati

Posted 2014-06-25T21:22:12.297

Reputation: 175

Answers

1

Sure, you can do this with CryptoCoinJS.

First download Node.js. Then do the following:

Make a new directory:

mkdir /tmp/myapp
cd /tmp/myapp

Initialize your app:

npm init

Then run:

npm install --save coinkey@1.1.0

Then run:

npm install --save coininfo@0.2.0

Create your js file:

touch app.js

Put the following:

var CoinKey = require('coinkey')
var ci = require('coininfo')

var amount = 10
//generate a bunch of Litecoin addresses
for (var i = 0; i < amount; ++i) {
  var ck = CoinKey.createRandom(ci('LTC').versions) //change LTC to BTC if you want Bitcoin
  console.log(ck.privateWif + ': ' + ck.publicAddress)
}

Run your script:

node app.js

Documentation for coinkey Documentation for coininfo.

Hope this helps. If something doesn't work, let me know.

JP Richardson

Posted 2014-06-25T21:22:12.297

Reputation: 256

ehi jp, I'll try and give a feed! thanks!Damiano Barbati 2014-07-05T11:38:45.803