Skip to content

Commit

Permalink
Fixes bug in version upgrade script
Browse files Browse the repository at this point in the history
* Fixes bug where the plugins/teiid directory pom.xml version gets updated
  incorrectly. This pom should be ignored.

* Only modifies those poms where the packaging is not pom, ie. updates
  plugin, site and feature poms.
  • Loading branch information
Paul Richardson committed Feb 21, 2013
1 parent 685e4f0 commit 43cd980
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions scripts/upgrade-version.pl
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,20 @@ sub process_pom {
my @contents = (<INF>);
close(INF);

# It is possible that a directory has been
# caught up in the pom modification process
# and we don't want to change their version
# numbers.
#
# Directories have a packaging type of pom
# so check for this and bail out
#
foreach $line (@contents) {
if ($line =~ m/<packaging>pom<\/packaging>/) {
return 0;
}
}

# Prepare to modify the pom
open(OUF, ">$_") or die "Cannot open $!";

Expand Down

0 comments on commit 43cd980

Please sign in to comment.