--- trunk/scripts/estcp.pl 2006/01/17 11:43:38 84 +++ trunk/scripts/estcp.pl 2006/01/17 15:00:50 85 @@ -31,6 +31,20 @@ debug => $debug, ); +unless(eval{ $to_n->name }) { + if ($to =~ m#^(http://.+)/node/(\w+)$#) { + my ($url,$name) = ($1,$2); + print "Creating '$name' on $url\n"; + $to_n->shuttle_url( $url . '/master?action=nodeadd', + 'application/x-www-form-urlencoded', + 'name=' . uri_escape($name) . '&label=' . uri_escape( $name ), + undef, + ); + } else { + die "can't extract node name from $to\n"; + } +} + print "Copy from ",$from_n->name," (",$from_n->label,") to ",$to_n->name," (",$to_n->label,") - ",$from_n->doc_num," documents (",$from_n->word_num," words, ",$from_n->size," bytes)\n"; my $doc_num = $from_n->doc_num || 1;