diff options
| author | syuilo <syuilotan@yahoo.co.jp> | 2017-03-18 01:42:43 +0900 |
|---|---|---|
| committer | syuilo <syuilotan@yahoo.co.jp> | 2017-03-18 01:42:43 +0900 |
| commit | 827be398582fbaf15adcd8d5393cfdf299932472 (patch) | |
| tree | 232171f059de309769aa050ed50d91b6912a0043 /src/api/service/github.ts | |
| parent | [Test] Fix (diff) | |
| download | sharkey-827be398582fbaf15adcd8d5393cfdf299932472.tar.gz sharkey-827be398582fbaf15adcd8d5393cfdf299932472.tar.bz2 sharkey-827be398582fbaf15adcd8d5393cfdf299932472.zip | |
🚨
Diffstat (limited to 'src/api/service/github.ts')
| -rw-r--r-- | src/api/service/github.ts | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/api/service/github.ts b/src/api/service/github.ts index c811a38da9..c2414930ed 100644 --- a/src/api/service/github.ts +++ b/src/api/service/github.ts @@ -29,6 +29,16 @@ module.exports = async (app: express.Application) => { } }); + handler.on('status', event => { + const state = event.state; + switch (state) { + case 'failure': + const commit = event.commit.commit; + post(`⚠️🚨BUILD FAILED🚨⚠️: ?[${commit.message}](${commit.url})`); + break; + } + }); + handler.on('push', event => { const ref = event.ref; switch (ref) { |