Skip to content

Commit

Permalink
Change message format
Browse files Browse the repository at this point in the history
  • Loading branch information
zharinov committed May 18, 2024
1 parent 77086d3 commit bcf0d68
Showing 1 changed file with 18 additions and 5 deletions.
23 changes: 18 additions & 5 deletions lib/modules/manager/gomod/artifacts-extra.ts
Original file line number Diff line number Diff line change
Expand Up @@ -86,14 +86,27 @@ export function getExtraDepsNotice(
return null;
}

const noticeLines: string[] = [];
const noticeLines: string[] = [
'In order to perform the update(s) described in the table above, Renovate ran the `go get` command, which resulted in the following additional change(s):',
'\n',
];

const goUpdated = extraDeps.some(({ depName }) => depName === 'go');
const otherDepsCount = extraDeps.length - (goUpdated ? 1 : 0);

if (otherDepsCount > 0) {
noticeLines.push(`- ${otherDepsCount} additional dependency was updated`);
}

if (goUpdated) {
noticeLines.push(

Check warning on line 102 in lib/modules/manager/gomod/artifacts-extra.ts

View check run for this annotation

Codecov / codecov/patch

lib/modules/manager/gomod/artifacts-extra.ts#L102

Added line #L102 was not covered by tests
'- The `go` directive was updated for compatibility reasons',
);
}

noticeLines.push(
'In addition to the dependencies listed above, the following packages will also be updated:',
);
noticeLines.push('\n');
noticeLines.push('Details:');
noticeLines.push(extraDepsTable(extraDeps));
noticeLines.push('\n');

return noticeLines.join('\n');
}

0 comments on commit bcf0d68

Please sign in to comment.