Skip to content

Commit

Permalink
Nightly build release info generation updated when Unreleased section…
Browse files Browse the repository at this point in the history
… is missing
  • Loading branch information
jindrapetrik committed Jan 18, 2018
1 parent c842b17 commit 56302e6
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions travis/format_release_info.php
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -217,8 +217,16 @@ function get_changelog_section($changelog_file, $section_name) {
$changelog_data = get_changelog_section($changelog_path,$changelog_section); $changelog_data = get_changelog_section($changelog_path,$changelog_section);
if($changelog_data === false) if($changelog_data === false)
{ {
fwrite(STDERR, "Cannot load changelog data\n"); if($is_prerelease)
exit(1); {
//[Unreleased section may be missing]
$changelog_data = "";
}
else
{
fwrite(STDERR, "Cannot load changelog data\n");
exit(1);
}
} }
$full_changelog = file_get_contents($changelog_path); $full_changelog = file_get_contents($changelog_path);
if(preg_match_all('/\[([^\]]+)\][^(]/', $changelog_data."\n",$m)) if(preg_match_all('/\[([^\]]+)\][^(]/', $changelog_data."\n",$m))
Expand Down

0 comments on commit 56302e6

Please sign in to comment.