Skip to content

Commit

Permalink
Tweaks. Add styling
Browse files Browse the repository at this point in the history
  • Loading branch information
jcbrand committed Oct 20, 2023
1 parent dadcb22 commit cb37b0d
Showing 1 changed file with 15 additions and 13 deletions.
28 changes: 15 additions & 13 deletions .github/workflows/xmpp-notify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ name: 'XMPP Notifier'

on:
push:
branches: [ "master" ]
branches: [ "master", "jcbrand/xmpp-notify"]
pull_request:
branches: [ "master" ]
branches: [ "master", "jcbrand/xmpp-notify"]

jobs:
notif-script:
Expand All @@ -23,34 +23,36 @@ jobs:
recipient: ${{ secrets.recipient }}
server_port: ${{ secrets.server_port }}
message: |
${{ github.actor }} pushed ${{ github.event.ref }} ${{ github.event.compare }} with message(s):
${{ join(github.event.commits.*.message, '\n') }}
*${{ github.actor }}* pushed commits to ${{ github.event.ref }} with message(s):
> ${{ join(github.event.commits.*.message, '\n\n> ') }}
${{ github.event.compare }}
recipient_is_room: true

- name: pr_open_info_step
id: pull_request_open
uses: conversejs/github-action-xmpp-notifier@master
# Will only get triggered when a pull request to master is created
if: github.event_name == 'pull_request' && github.event.action == 'opened'
with: # Set the secrets as inputs
jid: ${{ secrets.jid }}
password: ${{ secrets.password }}
server_host: ${{ secrets.server_host }}
recipient: ${{ secrets.recipient }}
message: |
${{ github.actor }} opened a PR : ${{ github.event.pull_request.html_url }} with message :
${{ github.actor }} opened a PR ${{ github.event.pull_request.html_url }}
${{ github.event.pull_request.title }}
recipient_is_room: true
- name: pr_edit_info_step
id: pull_request_edit

- name: issue_open_info_step
id: issue_open
uses: conversejs/github-action-xmpp-notifier@master
# Will only get triggered when a pull request to master is created
if: github.event_name == 'pull_request' && github.event.action == 'edited'
with: # Set the secrets as inputs
if: github.event_name == 'issue' && github.event.action == 'opened'
with:
jid: ${{ secrets.jid }}
password: ${{ secrets.password }}
server_host: ${{ secrets.server_host }}
recipient: ${{ secrets.recipient }}
message: |
${{ github.actor }} edited the following PR : ${{ github.event.pull_request.html_url }} with message :
${{ github.event.pull_request.title }}
${{ github.actor }} created a new issue ${{ github.event.issue.html_url }}:
${{ github.event.issue.title }}
recipient_is_room: true

0 comments on commit cb37b0d

Please sign in to comment.