merge_report.yml 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. name: 'Check FL ticket in PR name'
  2. on:
  3. push:
  4. branches:
  5. - dev
  6. env:
  7. FBT_TOOLCHAIN_PATH: /runner/_work
  8. jobs:
  9. merge_report:
  10. runs-on: [self-hosted,FlipperZeroShell]
  11. steps:
  12. - name: 'Wipe workspace'
  13. run: find ./ -mount -maxdepth 1 -exec rm -rf {} \;
  14. - name: 'Checkout code'
  15. uses: actions/checkout@v3
  16. with:
  17. fetch-depth: 1
  18. ref: ${{ github.event.pull_request.head.sha }}
  19. - name: 'Get commit details'
  20. run: |
  21. if [[ ${{ github.event_name }} == 'pull_request' ]]; then
  22. TYPE="pull"
  23. elif [[ "${{ github.ref }}" == "refs/tags/"* ]]; then
  24. TYPE="tag"
  25. else
  26. TYPE="other"
  27. fi
  28. python3 scripts/get_env.py "--event_file=${{ github.event_path }}" "--type=$TYPE"
  29. - name: 'Check ticket and report'
  30. run: |
  31. source scripts/toolchain/fbtenv.sh
  32. python3 -m pip install slack_sdk
  33. python3 scripts/merge_report_qa.py \
  34. ${{ secrets.QA_REPORT_SLACK_TOKEN }} \
  35. ${{ secrets.QA_REPORT_SLACK_CHANNEL }}