From 5bc8dfd0146a7f0bac5932b5a59a75c698ba4dc1 Mon Sep 17 00:00:00 2001 From: YvesCesar Date: Fri, 23 Oct 2026 16:36:08 -0400 Subject: [PATCH 1/2] ci: use shared LibreCode psalm.yml workflow Signed-off-by: YvesCesar --- .github/workflows/psalm.yml | 31 +++++++++++++++---------------- 1 file changed, 15 insertions(+), 16 deletions(-) diff --git a/.github/workflows/psalm.yml b/.github/workflows/psalm.yml index 76a7cd65..7cb226cb 100644 --- a/.github/workflows/psalm.yml +++ b/.github/workflows/psalm.yml @@ -4,55 +4,54 @@ name: Static analysis -on: - pull_request: - -permissions: - contents: read +on: pull_request concurrency: group: psalm-${{ github.head_ref || github.run_id }} cancel-in-progress: true +permissions: + contents: read + jobs: static-analysis: runs-on: ubuntu-latest - name: static-psalm-analysis + name: static-psalm-analysis steps: - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 + uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 with: persist-credentials: false - name: Get php version id: versions - uses: icewind1991/nextcloud-version-matrix@8a7bac6300b2f0f3100088b297995a229558ddba # v1.3.2 + uses: nextcloud-libraries/nextcloud-version-matrix@cd0211ffcef1065e2020cd579e4843b8746e7a58 # v1.3.3 - name: Check enforcement of minimum PHP version ${{ steps.versions.outputs.php-min }} in psalm.xml - run: grep 'phpVersion="${{ steps.versions.outputs.php-min }}"' psalm.xml + run: grep 'phpVersion="${{ steps.versions.outputs.php-min }}' psalm.xml - name: Set up php${{ steps.versions.outputs.php-available }} - uses: shivammathur/setup-php@accd6127cb78bee3e8082180cb391013d204ef9f # v2.37.0 + uses: shivammathur/setup-php@f3e473d116dcccaddc5834248c87452386958240 # 2.37.2 with: php-version: ${{ steps.versions.outputs.php-available }} extensions: bz2, ctype, curl, dom, fileinfo, gd, iconv, intl, json, libxml, mbstring, openssl, pcntl, posix, session, simplexml, xmlreader, xmlwriter, zip, zlib, sqlite, pdo_sqlite coverage: none ini-file: development + # Temporary workaround for missing pcntl_* in PHP 8.3 ini-values: disable_functions= env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - name: Install dependencies + - name: Remove nextcloud/ocp run: | composer remove nextcloud/ocp --dev --no-scripts - composer i - - name: Check for vulnerable PHP dependencies - run: composer require --dev roave/security-advisories:dev-latest + - name: Install composer dependencies + uses: ramsey/composer-install@65e4f84970763564f46a70b8a54b90d033b3bdda # 4.0.0 - - name: Install nextcloud/ocp + - name: Install nextcloud/ocp:dev-${{ steps.versions.outputs.branches-max }} run: composer require --dev nextcloud/ocp:dev-${{ steps.versions.outputs.branches-max }} --ignore-platform-reqs --with-dependencies - - name: Run Psalm + - name: Run coding standards check run: composer run psalm -- --threads=1 --monochrome --no-progress --output-format=github From 0ff49274491392304ca4376b9f87de59639d44a0 Mon Sep 17 00:00:00 2001 From: YvesCesar Date: Fri, 23 Oct 2026 16:36:08 -0400 Subject: [PATCH 2/2] fix(psalm): align php version with support matrix Signed-off-by: YvesCesar --- psalm.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/psalm.xml b/psalm.xml index 22e35d0e..47c04226 100644 --- a/psalm.xml +++ b/psalm.xml @@ -11,7 +11,7 @@ SPDX-License-Identifier: AGPL-3.0-or-later findUnusedBaselineEntry="true" findUnusedCode="false" resolveFromConfigFile="true" - phpVersion="8.1" + phpVersion="8.2" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="https://getpsalm.org/schema/config" xsi:schemaLocation="https://getpsalm.org/schema/config vendor-bin/psalm/vendor/vimeo/psalm/config.xsd"