christopher.hahn at peregrine.com
Thu Oct 25 18:32:27 PDT 2001
I think that I should add some context.
Why doesn't this version seem to work?
use lib "/cm/tools/perl/modules";
# Grab params
$clistnum = shift;
$port = shift or $port = "perforce-sd:1666";
print STDOUT "This test message should appear when the submission fails";
print STDOUT "The arguments to this script were $clistnum and $port";
My trigger line is:
chahntest //cm/bamf/... "/usr/local/bin/perl TriggerTest2.pl %changelist%
Running the trigger manually works:
bash-2.03$ /usr/local/bin/perl TriggerTest2.pl 101
This test message should appear when the submission failsThe arguments to
this script were 101 and perforce-sd:1666
I know that the trigger is not working because I do
not see the output sent to STDOUT in the Perforce pop-up,
and also because changing the return code to 0 causes the
submit to keep on failing when a success code should allow
the submission to complete.
I have placed the script in the main Perforce directory,
where older scripts seem to be working.
From: Christopher Hahn [mailto:christopher.hahn at peregrine.com]
Sent: Thursday, October 25, 2001 5:33 PM
To: Perforce-User (E-mail)
Subject: [p4] Triggers
I have read the triggers documentation, and
understand how I can allow the submission to
succeed or fail via the triggers return code.
...but I wanted to confirm how I might add to the
message that pops-up for the user upon submission
I could swear that I have seen this done, but it
does not appear that either the triggers stdout
nor it's stderr are grabbed by perforce, for display.
(Or maybe my test failed ;-)
Well, I am really looking for more discussion on
triggers. Has anyone created a wiz-bang trigger,
in Perl, that is publicly available for study?
TIA for your kind attention,
In our sleep, pain which cannot forget falls drop by
drop upon the heart until, in our own despair, against
our will, comes wisdom through the awful grace of God.
Christopher Hahn: chahn at peregrine.com
perforce-user mailing list - perforce-user at perforce.com
More information about the perforce-user