summaryrefslogtreecommitdiffstats
path: root/tools/addchangelog.pl
blob: 27befd6d8632af452aca7424ccf72828e2a426d9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/usr/bin/perl

@ARGV == 1 or die "usage $0: <cvslog2changelog script>\n";

($script) = @ARGV;

$date = (split('/', `grep ChangeLog perl-install/CVS/Entries`))[3];

@changelog = `(cvs log -d ">$date" mdk-stage1 ; cd perl-install; cvs log -d ">$date") | $script`;
@before = `cat perl-install/ChangeLog`;

open F, ">perl-install/ChangeLog";
print F foreach @changelog, @before;

`cvs commit -m '' perl-install/ChangeLog >/dev/null` =~ /new revision: (.*$);/;

print "$1\n";
print foreach @changelog;