Phil Steitz wrote:
OK, went ahead and scripted this. Here's what I did after setting
maven.changes.issue.template=http://issues.apache.org/jira/browse/%ISSUE%
You shouldn't have to set that if you use maven-changes-plugin 1.5.1 or
newer.
No laughing at my Perl ....
Oh, I'm laughing alright. Not at your Perl, but at how easy it was to use :)
Works like a charm, thanks!
Phil
------------------------
#
# Script to replace Bugzilla IDs with JIRA.
# $file needs to be csv with jira ID first, then BZ.
# Use "all" issue view from JIRA issue browser and download to
spreadsheet, then
# delete other cols and export to csv.
#
# read CSV file exported from JIRA into hash
$file = 'issueMap.csv';
$changes = 'changes.xml';
open (F, $file) || die ("Could not open $file!");
while ($line = <F>)
{
$line =~ s/[\"\n\ ]//g; # lose the quotes, newlines, spaces
($jira,$bugzilla) = split ',', $line;
$issues{$bugzilla} = $jira;
}
close (F);
# make replacements one at a time (ugly, but simple and works)
while (($bugzilla, $jira) = each(%issues))
{
`cat $changes |sed "s/$bugzilla/$jira/g" > $changes.new`;
`mv $changes.new $changes`;
print "jira: $jira <- bugzilla: $bugzilla \n";
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
--
Dennis Lundberg
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]