Skip to content

Commit

Permalink
Merge pull request #2625 from erwinmombay/fix-cyc-changelog
Browse files Browse the repository at this point in the history
fix changelog to handle PR's that have a merge coming from master
  • Loading branch information
erwinmombay committed Mar 17, 2016
2 parents e2848a0 + c1a51c2 commit 54db402
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions build-system/tasks/changelog.js
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,8 @@ function getLastGitTag() {
*/
function getGitLog(tag) {
var options = {
args: 'log ' + branch + '...' + tag + ' --pretty=format:%s --merges'
args: 'log ' + branch + '...' + tag +
' --pretty=format:%s --merges --first-parent'
};
return gitExec(options).then(function(log) {
if (!log) {
Expand Down Expand Up @@ -306,7 +307,7 @@ function onGitLogSuccess(gitMetadata, logs) {
assert(typeof logs == 'string', 'git log should be a string.\n' + logs);
return commits
.filter(function(commit) {
// filter non Pull request merges
// Filter non Pull request merges.
return commit.indexOf('Merge pull') == 0;
})
.map(function(commit) {
Expand All @@ -324,7 +325,7 @@ function errHandler(err) {
msg = err.message;
}
util.log(util.colors.red(msg));
return err;
throw err;
}

/**
Expand Down

0 comments on commit 54db402

Please sign in to comment.