Adding copr webhook to tell it to rebuild
Update README version / update-readme-version (push) Successful in 7s
Update README version / update-readme-version (push) Successful in 7s
This commit is contained in:
@@ -1,6 +1,9 @@
|
|||||||
name: Update README version
|
name: Update README version
|
||||||
|
|
||||||
on:
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- master
|
||||||
schedule:
|
schedule:
|
||||||
- cron: "17 2 * * *"
|
- cron: "17 2 * * *"
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
@@ -12,6 +15,7 @@ jobs:
|
|||||||
update-readme-version:
|
update-readme-version:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
env:
|
env:
|
||||||
|
COPR_WEBHOOK_URL: ${{ secrets.COPR_WEBHOOK_URL }}
|
||||||
TARBALL_URL: https://packages.element.io/desktop/install/linux/glibc-x86-64/element-desktop.tar.gz
|
TARBALL_URL: https://packages.element.io/desktop/install/linux/glibc-x86-64/element-desktop.tar.gz
|
||||||
steps:
|
steps:
|
||||||
- name: Check out repository
|
- name: Check out repository
|
||||||
@@ -55,6 +59,7 @@ jobs:
|
|||||||
README.md
|
README.md
|
||||||
|
|
||||||
- name: Commit and push update
|
- name: Commit and push update
|
||||||
|
id: commit
|
||||||
if: steps.version.outputs.latest != steps.version.outputs.current
|
if: steps.version.outputs.latest != steps.version.outputs.current
|
||||||
shell: bash
|
shell: bash
|
||||||
run: |
|
run: |
|
||||||
@@ -65,3 +70,21 @@ jobs:
|
|||||||
git add README.md
|
git add README.md
|
||||||
git commit -m "docs: update tracked Element Desktop version to ${{ steps.version.outputs.latest }}"
|
git commit -m "docs: update tracked Element Desktop version to ${{ steps.version.outputs.latest }}"
|
||||||
git push
|
git push
|
||||||
|
echo "pushed=true" >> "$GITHUB_OUTPUT"
|
||||||
|
|
||||||
|
- name: Trigger COPR build
|
||||||
|
if: gitea.event_name == 'push' && steps.commit.outputs.pushed != 'true'
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
|
||||||
|
if [ -z "${COPR_WEBHOOK_URL:-}" ]; then
|
||||||
|
echo "COPR_WEBHOOK_URL secret is not set" >&2
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
curl --fail --show-error --silent \
|
||||||
|
--retry 3 \
|
||||||
|
--retry-all-errors \
|
||||||
|
-X POST \
|
||||||
|
"$COPR_WEBHOOK_URL"
|
||||||
|
|||||||
Reference in New Issue
Block a user