Replying to my own message, what bad form. However, I'm making some progress.
At line 390 of Glue.pm, there's a stanza which tests if the product is CVS or
Git, and if so throws an error saying auto product detection is not supported.
I need to change this so that the error routine is not called if the product is
CVS and the version is 1.12 or above. What I've tried is:
# CVS prior to 1.12 does not provide a list of files that are about
to
# be commited during an activity_verify. Cannot support
# policy 'auto' for it.
if ( $self->configuration()->{ scm }->{ name } eq "CVS" ) {
if ( $self->configuration()->{ scm }->{ version } eq
$SCM_VERSION_LATEST) {
# pass, friend...
} else {
my $msg = "Policy product_name_definition does not
support the 'auto' configuration for " . $self->configuration()->{ scm }->{
name } . ".\n";
scmbug_error(
$GLUE_ERROR_POLICY_PRODUCT_NAME_DEFINITION_AUTO_NOT_SUPPORTED, $msg);
}
}
# Git does not provide a list of files that are about to
# be commited during an activity_verify. Cannot support
# policy 'auto' for it.
if ( $self->configuration()->{ scm }->{ name } eq "Git" ) {
my $msg = "Policy product_name_definition does not support the
'auto' configuration for " . $self->configuration()->{ scm }->{ name } . ".\n";
scmbug_error(
$GLUE_ERROR_POLICY_PRODUCT_NAME_DEFINITION_AUTO_NOT_SUPPORTED, $msg);
}
However this fails with
cvs commit: Pre-commit check failed
Global symbol "$SCM_VERSION_LATEST" requires explicit package name at
/var/lib/cvs/CVSROOT/lib/scmbug/Scmbug/Glue/Glue.pm line 392.
Compilation failed in require at /var/lib/cvs/CVSROOT/bin/scmbug_activity.pl
line 24.
BEGIN failed--compilation aborted at
/var/lib/cvs/CVSROOT/bin/scmbug_activity.pl line 24.
cvs commit: Pre-commit check failed
I've simply copied $SCM_VERSION_LATEST on a 'monkey see, monkey do' basis from
line 110 of CVS.pm; what I need to know is what the correct way to get the
version of the product is, what format I'll get the data in is, and how best to
compare it to 1.12.
-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Simon Brooke
Sent: 07 May 2008 12:18
To: [email protected]
Subject: [scmbug-users] Logging output from scmbug_activity.pl - where?
I'm trying to fix scmbug to auto-detect product names with CVS 1.12.13. I have
to confess that progress is slow, partly because I'm no Perl expert, and partly
because I'm having to fit it in around other work. However I've failed to make
scmbug-activity.pl run in a test environment outside CVS, because I've failed
to understand what should be passed by the %l placeholder in verifymsg (yes, I
know it's a filename, but I haven't worked out what file, nor what syntax);
I've also failed to get any debugging output to print when scmbug-activity.pl
is run in the CVS process.
So, questions in order:
What is the syntax of the file which will be passed as %l? Where can I find a
sample of this file? Can I get the STDERR from scmbug-activity to go somewhere
particular, and if so how?
Cheers
Simon
Simon Brooke, Software Specialist
Cygnet Solutions Ltd
Registered office: Swan House, Darvel, Ayrshire, Scotland, KA17 0LP Registered
in Scotland No. SC158059
mail: [EMAIL PROTECTED]
www: http://www.cygnets.co.uk
tel: +44(0)1560 323444
fax: +44(0)1560 323432
_______________________________________________
scmbug-users mailing list
[email protected]
http://lists.mkgnu.net/cgi-bin/mailman/listinfo/scmbug-users
Simon Brooke, Software Specialist
Cygnet Solutions Ltd
Registered office: Swan House, Darvel, Ayrshire, Scotland, KA17 0LP Registered
in Scotland No. SC158059
mail: [EMAIL PROTECTED]
www: http://www.cygnets.co.uk
tel: +44(0)1560 323444
fax: +44(0)1560 323432
Simon Brooke, Software Specialist
Cygnet Solutions Ltd
Registered office: Swan House, Darvel, Ayrshire, Scotland, KA17 0LP
Registered in Scotland No. SC158059
mail: [EMAIL PROTECTED]
www: http://www.cygnets.co.uk
tel: +44(0)1560 323444
fax: +44(0)1560 323432
_______________________________________________
scmbug-users mailing list
[email protected]
http://lists.mkgnu.net/cgi-bin/mailman/listinfo/scmbug-users