Skip to content

Commit

Permalink
[#3] Merge branch 'master' into v3
Browse files Browse the repository at this point in the history
  • Loading branch information
8398a7 committed Apr 13, 2020
2 parents 99d82ee + 0206a54 commit 6248b66
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,11 @@ steps:
- uses: 8398a7/action-slack@v3
with:
status: ${{ job.status }}
fields: repo,message,commit,author,action,eventName,ref,workflow # selectable (default: repo,message)
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # optional
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }} # required
if: always() # Pick up events even if the job fails or is canceled.
```
<img width="480" alt="success" src="https://user-images.githubusercontent.com/8043276/78500565-2b15c900-7792-11ea-86fe-a0dcf7ebef84.png" />
<img width="480" alt="success" src="https://user-images.githubusercontent.com/8043276/79061851-2c358180-7ccf-11ea-9d04-fe67b0f88986.png" />
3 changes: 2 additions & 1 deletion docs/content/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,11 @@ steps:
- uses: 8398a7/action-slack@v3
with:
status: ${{ job.status }}
fields: repo,message,commit,author,action,eventName,ref,workflow # selectable (default: repo,message)
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # optional
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }} # required
if: always() # Pick up events even if the job fails or is canceled.
```
<img width="480" alt="success" src="https://user-images.githubusercontent.com/8043276/78500565-2b15c900-7792-11ea-86fe-a0dcf7ebef84.png" />
<img width="480" alt="success" src="https://user-images.githubusercontent.com/8043276/79061851-2c358180-7ccf-11ea-9d04-fe67b0f88986.png" />
4 changes: 3 additions & 1 deletion src/client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,9 @@ export class Client {
commit && this.includesField('message')
? {
title: 'message',
value: `<${commit.data.html_url}|${commit.data.commit.message}>`,
value: `<${commit.data.html_url}|${
commit.data.commit.message.split('\n')[0]
}>`,
short: true,
}
: undefined,
Expand Down

0 comments on commit 6248b66

Please sign in to comment.