my $defpool = SVN::Pool->new_default;
my $fs = $repos->fs;
my $rev = $fs->youngest_rev($defpool);
my $txn = $repos->fs_begin_txn_for_commit($rev, $uname, $message, $defpool);
my $root = $txn->root($defpool);

foreach my $filename (keys %submit_files) {
  my $subpool = SVN::Pool->new_default($defpool);
  $root->make_file($filepath, $subpool);
  my ($handler, $baton) = $root->apply_textdelta($filepath, undef, undef, $subpool);
  open(FILE, "<$filename");
  my $contents = do { local $/; <FILE> };
  close FILE;
  SVN::TxDelta::send_string($contents, $handler, $baton, $subpool);
  $subpool->clear();
}

$repos->fs_commit_txn($txn, $defpool);
$defpool->clear();



