Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re: SVN API log_msg help

by mbethke (Hermit)
on Dec 02, 2011 at 01:21 UTC ( [id://941207]=note: print w/replies, xml ) Need Help??


in reply to Reaped: SVN API log_msg help

Just guessing wildly as I don't have a clue what you're trying to do either but there seems to be a typo in line 4, you likely want a dereferencing arrow instead of a minus:

$self->{'log_msg_callback'} = $self->{'ctx'}->log_msg_baton3(shift);

Replies are listed 'Best First'.
Re^2: SVN API log_msg help
by naresh777 (Initiate) on Dec 02, 2011 at 03:19 UTC

    Thanks for reply I am Trying to create a SVN API. In which when i commit a file it will call back the log_msg. i am trying to write the log_msg function which need to take massage from user and kept in a tmp file and commit using that message.

    use SVN::Client; use IO:File; use vars qw($fh $filename); my $template = 'filexxxx'; my $target = '/home/XXX/bla/bla'; my $ctx-> new SVN::Client(); $ctx->log_msg(\&log_msg); print " enter path to commit"; my $path =<>; chomp($path); $ctx->commit($path,0); sub log_msg{ my $log_msg=shift; my $messgpath=shift; my $citem = shift; my $pool = shift; $logmsg =&message(); $citem ={ $citem->path($path), $citem->revision('HEAD') } sub message { ($fh,$filename)=temfile($template, DIR => $target or die "error creating $filename :$!"; $fh =new IO::File "+>> $filename " or die " could not open a file :$!" +; if (defined $fh){ my $line =<STDIN>; print $fh $line; } $logmsg = ` cat $filename`; close($fh) return $logmsg; $messgpath ="$pathh/$filename"; } }

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://941207]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others learning in the Monastery: (5)
As of 2024-04-19 23:22 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found