Skip to content

Commit 9e6d105

Browse files
author
Alex Page
committed
Add correct error handling with core
1 parent 09f7121 commit 9e6d105

File tree

3 files changed

+4
-2
lines changed

3 files changed

+4
-2
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,5 +60,6 @@ These are the options recommended to be changed. For more detailed explanation o
6060

6161
## Release History
6262

63+
- v0.0.2 - Error handling using GitHub actions
6364
- v0.0.1 - Update icon and color for GitHub actions
6465
- v0.0.0 - Initial release

index.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,7 @@ const getData = () => {
114114

115115
console.log(`✅ ${action === 'opened' ? 'Added' : 'Moved'} card to ${column} in ${project}`);
116116
} catch (error) {
117-
console.error(error);
117+
core.error(error);
118+
core.setFailed(error.message);
118119
}
119120
})();

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "github-project-automation-plus",
3-
"version": "0.0.1",
3+
"version": "0.0.2",
44
"description": "🤖 Automate GitHub Project cards with any webhook event",
55
"private": true,
66
"main": "dist/index.js",

0 commit comments

Comments
 (0)