[p4perl] help using P4::ParseForms()
Tony Smith
tony at smee.org
Tue Jun 26 08:18:31 PDT 2007
Hi Stefano,
> I need your help.
>
> I am using P4::ParseForms(), and when run the command $p4->Run(
> "sync" ) I have this result:
>
>
>
> HASH(0x18351e0)
>
> HASH(0x1835270)
>
> HASH(0x1835300)
>
That's because '$p4->Run( "sync" )' is returning an array of hashes containing
the output you seek. You'll need to iterate over that array and decide what
you want to do with the output. For example:
foreach my $h ( $p4->Sync() )
{
print( $h->{ 'depotFile' }, " - ", $h->{ 'action' }, "\n" );
}
To see what fields are available to you, just run the command in tagged mode
from the command line. For example:
p4 -ztag sync
Regards,
Tony
More information about the p4perl
mailing list