telegram-desktop: Update tdesktop.git to 5.8.0 #586
Workflow file for this run
This file contains 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
name: Update Qt patches | |
on: pull_request | |
jobs: | |
update-qt-patches: | |
runs-on: ubuntu-latest | |
if: github.event.pull_request.user.login == 'flathubbot' | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
ref: ${{ github.event.pull_request.head.ref }} | |
submodules: true | |
- name: Update Qt patches | |
run: | | |
QT=$(yq '.modules[] | select(.name == "qtbase").sources[0].url' org.telegram.desktop.yml | sed -r 's/.*([0-9]+\.[0-9]+\.[0-9]+).*/\1/') | |
pushd desktop-app-patches > /dev/null | |
repo=$(git remote get-url origin | sed -r 's@^https://github.com/(.*)\.git$@\1@') | |
git fetch | |
git checkout origin/master | |
commit=$(git rev-parse --short HEAD) | |
popd > /dev/null | |
for i in desktop-app-patches/*_${QT}; do | |
./gen-patchset.py -o $(basename $i | sed -r "s/_${QT}//").json $i | |
done | |
git config --global user.name 'GitHub Action' | |
git config --global user.email '[email protected]' | |
git add . | |
git diff --staged --quiet || (git commit -m "Update Qt patches to $repo@$commit" && git push) |