Browse Source

Add gen-zaddrs.pl and improve docs

pull/217/head
Duke Leto 2 years ago
parent
commit
ab83649c1a
  1. 20
      contrib/README.md
  2. 17
      contrib/gen-zaddrs.pl

20
contrib/README.md

@ -6,9 +6,25 @@ Do not expect all scripts to work!
Please fix bugs and report things you find.
## Hush Tools
# Hush Tools
## block\_time.pl
Estimate when a Hush block will happen.
Example:
./contrib/block_time.pl 123456 # Print out datetime of when block height 123456 happens
## gen-zaddrs.pl
Generate zaddrs in bulk, by default 50 at a time. Prints out a zaddr one per line.
Example:
./contrib/gen-zaddrs.pl # generate 50 zaddrs
./contrib/gen-zaddrs.pl 500 # generate 500 zaddrs
block\_time.pl - estimate when a Hush block will happen
## Wallet Tools

17
contrib/gen-zaddrs.pl

@ -0,0 +1,17 @@
#!/usr/bin/env perl
# Copyright 2019-2022 The Hush developers
# Released under the GPLv3
use warnings;
use strict;
my $hush = "./src/hush-cli";
my $znew = "$hush z_getnewaddress";
my $count = 1;
my $howmany = shift || 50;
while ($count < $howmany) {
my $zaddr = qx{$znew};
chomp($zaddr);
print qq{$zaddr\n};
$count++;
}
Loading…
Cancel
Save