update-psalm-baseline.yml 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. name: Update Psalm baseline
  2. on:
  3. workflow_dispatch:
  4. schedule:
  5. - cron: "5 4 * * *"
  6. jobs:
  7. update-psalm-baseline:
  8. runs-on: ubuntu-latest
  9. if: ${{ github.repository_owner != 'nextcloud-gmbh' }}
  10. strategy:
  11. fail-fast: false
  12. matrix:
  13. branches: ["master", "stable24", "stable23", "stable22"]
  14. name: update-psalm-baseline-${{ matrix.branches }}
  15. steps:
  16. - uses: actions/checkout@v2
  17. with:
  18. ref: ${{ matrix.branches }}
  19. submodules: true
  20. - name: Set up php7.4
  21. uses: shivammathur/setup-php@v2
  22. with:
  23. php-version: 7.4
  24. extensions: ctype,curl,dom,fileinfo,gd,intl,json,mbstring,openssl,pdo_sqlite,posix,sqlite,xml,zip
  25. coverage: none
  26. env:
  27. GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
  28. - name: Composer install
  29. run: composer install
  30. - name: Psalm
  31. run: composer run psalm -- --monochrome --no-progress --output-format=text --update-baseline
  32. continue-on-error: true
  33. - name: Reset composer
  34. run: |
  35. git clean -f lib/composer
  36. git checkout composer.json composer.lock lib/composer
  37. - name: Create Pull Request
  38. uses: peter-evans/create-pull-request@v3
  39. with:
  40. token: ${{ secrets.COMMAND_BOT_PAT }}
  41. commit-message: Update psalm baseline
  42. committer: GitHub <noreply@github.com>
  43. author: nextcloud-command <nextcloud-command@users.noreply.github.com>
  44. signoff: true
  45. branch: automated/noid/${{ matrix.branches }}-update-psalm-baseline
  46. title: "[${{ matrix.branches }}] Update psalm-baseline.xml"
  47. body: |
  48. Auto-generated update psalm-baseline.xml with fixed psalm warnings
  49. labels: |
  50. automated pr
  51. 3. to review
  52. team-reviewers: server-backend