You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

28 lines
572 B

#!/usr/bin/perl
BEGIN { if (-e $ENV{SITE}.'/lib') { use lib $ENV{SITE}.'/lib'; } }
use seed;
use toychain;
use TXPOOL qw(getTxMeta);
use YAML::Syck qw(Dump);
my $seed = &seed::setseed('beautiful toy chain');
my $height = &getChainHeight();
my $n = $height + 1;
printf "height: %s\n",$height;
my $txmeta = getTxMeta();
my $payload = "testing $0";
my $comment = "new block $n";
my $block = &createBlock($seed,$payload,$txmeta,$comment);
#printf "--- # block %s...\n",Dump($block);
my $blk = &insertBlock($block);
printf "--- # blk %s...\n",Dump($blk);
exit $?;
1;