Permalink
Browse files

provide an existing key as first argument to get the private key / ad…

…dress
  • Loading branch information...
dbasch committed Jan 30, 2014
1 parent 0f0eef9 commit 67772d77128f54e296e0e325231fee896ccb363d
Showing with 7 additions and 1 deletion.
  1. +7 −1 src/main/java/com/fruitcat/dogecoin/PuppyKey.java
@@ -44,7 +44,13 @@ public static String dogeAddress(String key) throws AddressFormatException {
* @throws AddressFormatException
*/
public static void main(String args[]) throws Exception {
- String mk = new Minikey().toString();
+ Minikey minikey;
+ if (args.length == 0) {
+ minikey = new Minikey();
+ } else {
+ minikey = new Minikey(args[0]);
+ }
+ String mk = minikey.toString();
System.out.println("Minikey: " + mk);
String dogeKey = miniToDoge(mk);
System.out.println("Dogecoin key: " + dogeKey);

0 comments on commit 67772d7

Please sign in to comment.