2
0

fixup-NEWS.md-postrelease.pl 795 B

12345678910111213141516171819202122232425262728
  1. #! /usr/bin/env perl -pi
  2. BEGIN {
  3. our $count = 1; # Only the first one
  4. our $RELEASE = $ENV{RELEASE};
  5. our $RELEASE_TEXT = $ENV{RELEASE_TEXT};
  6. our $PREV_RELEASE_DATE = $ENV{PREV_RELEASE_DATE} || 'under development';
  7. our $PREV_RELEASE_TEXT = $ENV{PREV_RELEASE_TEXT};
  8. $RELEASE =~ s/-dev//;
  9. }
  10. if (/^### Major changes between OpenSSL (\S+) and OpenSSL (\S+) \[under development\]/
  11. && $count-- > 0) {
  12. my $v1 = $1;
  13. my $v2 = $PREV_RELEASE_TEXT || $2;
  14. # If this is a pre-release, we do nothing
  15. if ($RELEASE !~ /^\d+\.\d+\.\d+-(?:alpha|beta)/) {
  16. $_ = <<_____
  17. ### Major changes between OpenSSL $v2 and OpenSSL $RELEASE_TEXT [under development]
  18. *
  19. ### Major changes between OpenSSL $v1 and OpenSSL $v2 [$PREV_RELEASE_DATE]
  20. _____
  21. }
  22. }