Skip to content

Commit

Permalink
GitHub actions added.
Browse files Browse the repository at this point in the history
  • Loading branch information
Glomberg committed Feb 8, 2024
1 parent f826a80 commit 3caae8d
Show file tree
Hide file tree
Showing 3 changed files with 52 additions and 0 deletions.
23 changes: 23 additions & 0 deletions .github/workflows/releaseNotice.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Notice about releases via Telegram

on:
release:
types: [published]

jobs:

build:
runs-on: ubuntu-latest
steps:
- name: send telegram message on release
uses: appleboy/telegram-action@master
with:
to: ${{ secrets.TELEGRAM_TO }}
token: ${{ secrets.TELEGRAM_TOKEN }}
message: |
${{ github.event.repository.description }} <strong>v${{github.event.release.name}}</strong> released
${{github.event.release.html_url}}
${{ github.event.release.body }}
format: html
disable_web_page_preview: true
27 changes: 27 additions & 0 deletions .github/workflows/reviewNotice.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Notice about review approved via Telegram

on:
pull_request_review:
types: [ submitted ]

jobs:

build:
if: github.event.review.state == 'approved' && toJSON(github.event.pull_request.requested_reviewers) == '[]'
runs-on: ubuntu-latest
steps:
- name: Convert date format
id: date
run: echo "::set-output name=date::$(date -d "${{ github.event.pull_request.created_at }}" +"%Y-%m-%d")"
- name: Send telegram message on review approved
uses: appleboy/telegram-action@master
with:
to: ${{ secrets.TELEGRAM_PLUGINS_TO }}
token: ${{ secrets.TELEGRAM_REVIEWER_TOKEN }}
message: |
💥🎉🎉🎉💥 Pull-request <a href="${{ github.event.pull_request.html_url }}"><strong>${{ github.event.pull_request.title }}</strong></a>
submitted by <strong>${{ github.event.pull_request.user.login }}</strong> at <strong>${{ steps.date.outputs.date }}</strong>
was <strong>approved</strong> and is ready to merge <a href="${{ github.event.pull_request.html_url }}">➡️</a> !!!
format: html
disable_web_page_preview: true
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
/*
!/uniforce
!/uniforce/*
!/.github
!/.github/*
!/README.md
#/uniforce/data/

0 comments on commit 3caae8d

Please sign in to comment.