From d661d531e411a8f3826564d4a04d4dde31b65e81 Mon Sep 17 00:00:00 2001 From: Herbert Roth Date: Tue, 11 Jun 2024 17:01:39 +0200 Subject: [PATCH] Switch to reusable workflow. --- .github/workflows/qodana.yaml | 43 ++++++++--------------------------- 1 file changed, 9 insertions(+), 34 deletions(-) diff --git a/.github/workflows/qodana.yaml b/.github/workflows/qodana.yaml index 4d7d744..3a48681 100644 --- a/.github/workflows/qodana.yaml +++ b/.github/workflows/qodana.yaml @@ -11,44 +11,19 @@ on: branches: - '*' - '**' - pull_request: + pull_request_target: types: [opened, synchronize, reopened] paths: - '**.php' - '**.yml' - '**.yaml' + branches: + - '*' + - '**' jobs: - qodana: - timeout-minutes: 15 - runs-on: ubuntu-latest - permissions: - contents: write - pull-requests: write - checks: write - steps: - - uses: actions/checkout@v3 - with: - ref: ${{ github.event.pull_request.head.sha }} - fetch-depth: 0 - - name: Install PHP - uses: shivammathur/setup-php@v2 - with: - php-version: 8.1 - extensions: curl, mbstring, openssl, pdo, pdo_sqlite - ini-values: memory_limit=-1, date.timezone='UTC' - coverage: xdebug - tools: composer:v2 - - - name: Validate composer.json and composer.lock - run: composer validate - - - name: Install dependencies - run: composer install --prefer-dist --no-progress --no-interaction --no-suggest - - - name: 'Qodana Scan' - uses: JetBrains/qodana-action@v2023.2 - with: - args: --baseline,qodana.sarif.json - env: - QODANA_TOKEN: ${{ secrets.QODANA_TOKEN }} + qodana-check-workflow: + uses: pimcore/workflows-collection-public/.github/workflows/reusable-qodana-check.yaml@main + secrets: + COMPOSER_PIMCORE_REPO_PACKAGIST_TOKEN: ${{ secrets.COMPOSER_PIMCORE_REPO_PACKAGIST_TOKEN }} + QODANA_TOKEN: ${{ secrets.QODANA_TOKEN }}