Change author field to use sender's login #10
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # yaml-language-server: $schema=https://json.schemastore.org/github-workflow.json | |
| name: Post an inline text message | |
| on: | |
| push: | |
| branches: | |
| - main | |
| jobs: | |
| run: | |
| name: Commit message | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Mensagem para commit | |
| uses: slackapi/slack-github-action@v2.1.1 | |
| with: | |
| webhook: ${{ secrets.SLACK_WEBHOOK_URL }} | |
| webhook-type: incoming-webhook | |
| payload: | | |
| { | |
| "text": ":black_nib: *Novo commit*", | |
| "attachments": [ | |
| { | |
| "color": "#36a64f", | |
| "title": "${{ github.event.head_commit.message}}", | |
| "fields": [ | |
| { | |
| "title": "Autor", | |
| "value": "${{ github.event.sender.user.login }}", | |
| "short": true | |
| }, | |
| ] | |
| } | |
| ] | |
| } |