incubator-ooo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From arie...@apache.org
Subject svn commit: r1353793 - /incubator/ooo/trunk/main/solenv/bin/modules/installer/scriptitems.pm
Date Tue, 26 Jun 2012 01:41:05 GMT
Author: arielch
Date: Tue Jun 26 01:41:04 2012
New Revision: 1353793

URL: http://svn.apache.org/viewvc?rev=1353793&view=rev
Log:
Always replace <scsrevision>

Revision 1352877 leaves Revision=<scsrevision> in version[rc|.ini] if
$scsrevision is undefined, that is the case when
SvnRevision::DetectRevisionId fails; in these cases it would be better
an empty string.

Modified:
    incubator/ooo/trunk/main/solenv/bin/modules/installer/scriptitems.pm

Modified: incubator/ooo/trunk/main/solenv/bin/modules/installer/scriptitems.pm
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/solenv/bin/modules/installer/scriptitems.pm?rev=1353793&r1=1353792&r2=1353793&view=diff
==============================================================================
--- incubator/ooo/trunk/main/solenv/bin/modules/installer/scriptitems.pm (original)
+++ incubator/ooo/trunk/main/solenv/bin/modules/installer/scriptitems.pm Tue Jun 26 01:41:04
2012
@@ -985,7 +985,8 @@ sub replace_setup_variables
 	if ( $hashref->{'USERDIRPRODUCTVERSION'} ) { $userdirproductversion = $hashref->{'USERDIRPRODUCTVERSION'};
}
 	my $productkey = $productname . " " . $productversion;
 
-	my $scsrevision = SvnRevision::DetectRevisionId(File::Spec->catfile($ENV{'SRC_ROOT'},
File::Spec->updir()));
+    my $scsrevision;
+    $scsrevision = "" unless ( $scsrevision = SvnRevision::DetectRevisionId(File::Spec->catfile($ENV{'SRC_ROOT'},
File::Spec->updir())) );
 
 	# string $buildid, which is used to replace the setup variable <buildid>
 	
@@ -1014,7 +1015,7 @@ sub replace_setup_variables
 		my $value = $oneitem->{'Value'};
 		
 		$value =~ s/\<buildid\>/$buildidstring/;
-		$value =~ s/\<scsrevision\>/$scsrevision/ if defined $scsrevision;
+		$value =~ s/\<scsrevision\>/$scsrevision/;
 		$value =~ s/\<sequence_languages\>/$languagesstring/;
 		$value =~ s/\<productkey\>/$productkey/;
 		$value =~ s/\<productcode\>/$installer::globals::productcode/;



Mime
View raw message