Skip to content

Commit bd4fa6e

Browse files
authored
Prepare 2.1.0 release (#27)
1 parent d1edf6c commit bd4fa6e

4 files changed

Lines changed: 14 additions & 6 deletions

File tree

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
# Apollo Schema Check Action Changelog
22

3+
## 2.1.0 (October 31, 2022)
4+
5+
- Include a list of errors in the PR comment (@comp615)
6+
- Fix: only count errors and warnings in change summary (@comp615)
7+
38
## 2.0.2 (September 15, 2022)
49

510
- Update `from` parameter format. It seems Apollo no longer wants `sec` included with offsets.

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "apollo-schema-check-action",
33
"description": "A GitHub Action to run a schema check with Apollo Studio and post the results as a comment on a Pull Request",
4-
"version": "2.0.2",
4+
"version": "2.1.0",
55
"author": "Ian Sutherland <ian@iansutherland.ca>",
66
"license": "MIT",
77
"repository": {

src/format-message.ts

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,10 @@ const getSummary = (
4949
checkSchemaResult?.diffToPrevious.severity === 'WARNING' ||
5050
checkSchemaResult?.diffToPrevious.severity === 'FAILURE'
5151
) {
52-
const issueCount = checkSchemaResult?.diffToPrevious.changes.filter((change) => change.severity === 'FAILURE' || change.severity === 'WARNING').length;
52+
const issueCount = checkSchemaResult?.diffToPrevious.changes.filter(
53+
(change) => change.severity === 'FAILURE' || change.severity === 'WARNING'
54+
).length;
55+
5356
summary += `❌ Found **${issueCount} breaking changes**\n\n`;
5457

5558
setFailed('Breaking changes found');
@@ -129,13 +132,13 @@ const formatMessage = (
129132

130133
message += '```\n';
131134
}
132-
135+
133136
if (checkSchemaResult?.diffToPrevious.severity === 'FAILURE') {
134137
message += '#### Schema Change Errors\n\n```\n';
135138

136139
for (const change of checkSchemaResult?.diffToPrevious.changes) {
137140
if (change.severity === 'FAILURE') {
138-
message += `${error.description}\n`;
141+
message += `${change.description}\n`;
139142
}
140143
}
141144

0 commit comments

Comments
 (0)