Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 14 additions & 14 deletions .github/actions-lock.txt
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
# SPDX-FileCopyrightText: 2025 Nextcloud GmbH and Nextcloud contributors
# SPDX-License-Identifier: MIT
e456e5920f7020b8fef59329ab6ce54e ai-policy.yml
fe1239ed98a163abbdea3e0490c85458 appstore-build-publish.yml
7f15fef2fde87aae0eb8386ded489372 command-compile.yml
e6351c608939c31ae1e32923aa82aa10 dependabot-approve-merge.yml
2afe22a01c1c2413f0cf48d010a13396 appstore-build-publish.yml
4544db1f7eb9832ec10d80676c8c82b0 command-compile.yml
c1476a553c3223e70e49de980f22315e dependabot-approve-merge.yml
2581a67c5bcdcd570427e6d51db767d7 fixup.yml
985f3ac7d51405c1601c742832a14120 lint-eslint.yml
3ebb059d675980d618b9727fb3792d00 lint-eslint.yml
43fd0c5fb704cabc5f11cdfaf513236d lint-info-xml.yml
4b40dd0073e16f74dd04e6d49dcc043d lint-php-cs.yml
cfb31e47b6e9ab65e76c89b028754a4e lint-php.yml
ab3a506506b1d7c1cea9593ecfd84366 lint-stylelint.yml
aff9f466debc652013b43d1a11b32a0b npm-audit-fix.yml
28dcf55e283b85c292fea0d0b2a15a8a npm-build.yml
8fab08ac7da700ee304af0bf3c18b3a3 phpunit-mysql.yml
43878db2acac51746332618c9f731553 psalm-matrix.yml
79006ab196f5664fc444e63645cfd8a7 lint-php-cs.yml
300be6a756abda800e40850918f2d964 lint-php.yml
d35c01a3f110e52eed0e0c422747a417 lint-stylelint.yml
10bb32b28348390097f8e9ad030ecca8 npm-audit-fix.yml
92a60849d140adc8bdfa1e4cad903b48 npm-build.yml
3cacf28a710b387e83d3858af40b7ffe phpunit-mysql.yml
6c355cb7b5d4da4d56a58e6d7f82881b psalm-matrix.yml
2dbec18233063b42f4d8e03bbb43671c reuse.yml
94c65e30a77686c079c6dfa54a008440 sync-workflow-templates.yml
a3440826636c0fd7c2d20b1de50363da update-nextcloud-ocp-approve-merge.yml
7cc949cd51ea5d604986bbdcb75c95c7 update-nextcloud-ocp-matrix.yml
511439ba27869e0324f283142cc8b3df sync-workflow-templates.yml
abcb8206c3f6c5a9dc86cccf57846bfc update-nextcloud-ocp-approve-merge.yml
ba78daa94b11b18fd0cf340160e5c776 update-nextcloud-ocp-matrix.yml
6 changes: 3 additions & 3 deletions .github/workflows/appstore-build-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ jobs:
expression: "//info//dependencies//nextcloud/@min-version"

- name: Read package.json node and npm engines version
uses: skjnldsv/read-package-engines-version-actions@06d6baf7d8f41934ab630e97d9e6c0bc9c9ac5e4 # v3
uses: skjnldsv/read-package-engines-version-actions@06d6db44aa62f4609ba070f556ec24bc99fb85cb # v4
id: versions
# Continue if no package.json
continue-on-error: true
Expand All @@ -83,7 +83,7 @@ jobs:

- name: Get php version
id: php-versions
uses: icewind1991/nextcloud-version-matrix@8a7bac6300b2f0f3100088b297995a229558ddba # v1.3.2
uses: nextcloud-libraries/nextcloud-version-matrix@cd0211ffcef1065e2020cd579e4843b8746e7a58 # v1.3.3
with:
filename: ${{ env.APP_NAME }}/appinfo/info.xml

Expand Down Expand Up @@ -194,7 +194,7 @@ jobs:
overwrite: true

- name: Upload app to Nextcloud appstore
uses: nextcloud-releases/nextcloud-appstore-push-action@a011fe619bcf6e77ddebc96f9908e1af4071b9c1 # v1.0.3
uses: nextcloud-libraries/nextcloud-appstore-push-action@a011fe619bcf6e77ddebc96f9908e1af4071b9c1 # v1.0.3
with:
app_name: ${{ env.APP_NAME }}
appstore_token: ${{ secrets.APPSTORE_TOKEN }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/command-compile.yml
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ jobs:
git config --local user.name 'nextcloud-command'

- name: Read package.json node and npm engines version
uses: skjnldsv/read-package-engines-version-actions@06d6baf7d8f41934ab630e97d9e6c0bc9c9ac5e4 # v3
uses: skjnldsv/read-package-engines-version-actions@06d6db44aa62f4609ba070f556ec24bc99fb85cb # v4
id: package-engines-versions
with:
fallbackNode: '^24'
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/dependabot-approve-merge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
name: Auto approve Dependabot PRs

on:
pull_request_target: # zizmor: ignore[dangerous-triggers]
pull_request:
branches:
- main
- master
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/lint-eslint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ jobs:
src: ${{ steps.changes.outputs.src}}

steps:
- uses: dorny/paths-filter@7b450fff21473bca461d4b92ce414b9d0420d706 # v4.0.2
- uses: dorny/paths-filter@ceb8a2b8f2d89434be7ff52d3de7ec3738c5cc9d # v4.0.3
id: changes
continue-on-error: true
with:
Expand Down Expand Up @@ -61,7 +61,7 @@ jobs:
persist-credentials: false

- name: Read package.json node and npm engines version
uses: skjnldsv/read-package-engines-version-actions@06d6baf7d8f41934ab630e97d9e6c0bc9c9ac5e4 # v3
uses: skjnldsv/read-package-engines-version-actions@06d6db44aa62f4609ba070f556ec24bc99fb85cb # v4
id: versions
with:
fallbackNode: '^24'
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/lint-php-cs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ jobs:

- 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: Set up php${{ steps.versions.outputs.php-min }}
uses: shivammathur/setup-php@f3e473d116dcccaddc5834248c87452386958240 # 2.37.2
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/lint-php.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ jobs:

- name: Get version matrix
id: versions
uses: icewind1991/nextcloud-version-matrix@8a7bac6300b2f0f3100088b297995a229558ddba # v1.3.2
uses: nextcloud-libraries/nextcloud-version-matrix@cd0211ffcef1065e2020cd579e4843b8746e7a58 # v1.3.3

php-lint:
runs-on: ubuntu-latest-low
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/lint-stylelint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
persist-credentials: false

- name: Read package.json node and npm engines version
uses: skjnldsv/read-package-engines-version-actions@06d6baf7d8f41934ab630e97d9e6c0bc9c9ac5e4 # v3
uses: skjnldsv/read-package-engines-version-actions@06d6db44aa62f4609ba070f556ec24bc99fb85cb # v4
id: versions
with:
fallbackNode: '^24'
Expand Down
28 changes: 25 additions & 3 deletions .github/workflows/npm-audit-fix.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,20 +15,25 @@ on:
- cron: '30 2 * * 0'

permissions:
contents: read
contents: write
pull-requests: write

jobs:
build:
runs-on: ubuntu-latest

env:
# env variable for maintainers: 'false' disables auto-merge for these pull requests
AUTOMERGE: true

strategy:
fail-fast: false
matrix:
branches:
- ${{ github.event.repository.default_branch }}
- 'stable35'
- 'stable34'
- 'stable33'
- 'stable32'

name: npm-audit-fix-${{ matrix.branches }}

Expand All @@ -42,7 +47,7 @@ jobs:
continue-on-error: true

- name: Read package.json node and npm engines version
uses: skjnldsv/read-package-engines-version-actions@06d6baf7d8f41934ab630e97d9e6c0bc9c9ac5e4 # v3
uses: skjnldsv/read-package-engines-version-actions@06d6db44aa62f4609ba070f556ec24bc99fb85cb # v4
id: versions
with:
fallbackNode: '^24'
Expand All @@ -69,6 +74,7 @@ jobs:
npm run build --if-present

- name: Create Pull Request
id: create-pull-request
if: steps.checkout.outcome == 'success'
uses: peter-evans/create-pull-request@5f6978faf089d4d20b00c7766989d076bb2fc7f1 # v8.1.1
with:
Expand All @@ -83,3 +89,19 @@ jobs:
labels: |
dependencies
3. to review

# Approve using the default GITHUB_TOKEN, as the PR itself was created
# using COMMAND_BOT_PAT and GitHub does not allow an account to approve its own PR
- name: GitHub actions bot approve
if: steps.create-pull-request.outputs.pull-request-operation != 'none'
run: gh pr review --approve "$PR_URL"
env:
PR_URL: ${{ steps.create-pull-request.outputs.pull-request-url }}
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Enable auto merge
if: steps.create-pull-request.outputs.pull-request-operation != 'none' && fromJSON(env.AUTOMERGE)
uses: peter-evans/enable-pull-request-automerge@a660677d5469627102a1c1e11409dd063606628d # v3.0.0
with:
token: ${{ secrets.GITHUB_TOKEN }}
pull-request-number: ${{ steps.create-pull-request.outputs.pull-request-number }}
4 changes: 2 additions & 2 deletions .github/workflows/npm-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ jobs:
src: ${{ steps.changes.outputs.src}}

steps:
- uses: dorny/paths-filter@7b450fff21473bca461d4b92ce414b9d0420d706 # v4.0.2
- uses: dorny/paths-filter@ceb8a2b8f2d89434be7ff52d3de7ec3738c5cc9d # v4.0.3
id: changes
continue-on-error: true
with:
Expand Down Expand Up @@ -58,7 +58,7 @@ jobs:
persist-credentials: false

- name: Read package.json node and npm engines version
uses: skjnldsv/read-package-engines-version-actions@06d6baf7d8f41934ab630e97d9e6c0bc9c9ac5e4 # v3
uses: skjnldsv/read-package-engines-version-actions@06d6db44aa62f4609ba070f556ec24bc99fb85cb # v4
id: versions
with:
fallbackNode: '^24'
Expand Down
46 changes: 22 additions & 24 deletions .github/workflows/phpunit-mysql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,33 +18,18 @@ concurrency:
cancel-in-progress: true

jobs:
matrix:
runs-on: ubuntu-latest-low
outputs:
matrix: ${{ steps.versions.outputs.sparse-matrix }}
steps:
- name: Checkout app
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false

- name: Get version matrix
id: versions
uses: icewind1991/nextcloud-version-matrix@8a7bac6300b2f0f3100088b297995a229558ddba # v1.3.2
with:
matrix: '{"mysql-versions": ["8.4"]}'

changes:
changes-and-matrix:
runs-on: ubuntu-latest-low
permissions:
contents: read
pull-requests: read

outputs:
src: ${{ steps.changes.outputs.src}}
src: ${{ steps.changes.outputs.src }}
matrix: ${{ steps.versions.outputs.sparse-matrix }}

steps:
- uses: dorny/paths-filter@7b450fff21473bca461d4b92ce414b9d0420d706 # v4.0.2
- uses: dorny/paths-filter@ceb8a2b8f2d89434be7ff52d3de7ec3738c5cc9d # v4.0.3
id: changes
continue-on-error: true
with:
Expand All @@ -61,15 +46,28 @@ jobs:
- 'composer.json'
- 'composer.lock'

- name: Checkout app
if: steps.changes.outputs.src != 'false'
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false

- name: Get version matrix
if: steps.changes.outputs.src != 'false'
id: versions
uses: nextcloud-libraries/nextcloud-version-matrix@cd0211ffcef1065e2020cd579e4843b8746e7a58 # v1.3.3
with:
matrix: '{"mysql-versions": ["8.4"]}'

phpunit-mysql:
runs-on: ubuntu-latest

needs: [changes, matrix]
if: needs.changes.outputs.src != 'false'
needs: changes-and-matrix
if: needs.changes-and-matrix.outputs.src != 'false'

strategy:
fail-fast: false
matrix: ${{ fromJson(needs.matrix.outputs.matrix) }}
matrix: ${{ fromJson(needs.changes-and-matrix.outputs.matrix) }}

name: MySQL ${{ matrix.mysql-versions }} PHP ${{ matrix.php-versions }} Nextcloud ${{ matrix.server-versions }}

Expand Down Expand Up @@ -194,12 +192,12 @@ jobs:
permissions:
contents: none
runs-on: ubuntu-latest-low
needs: [changes, phpunit-mysql]
needs: [changes-and-matrix, phpunit-mysql]

if: always()

name: phpunit-mysql-summary

steps:
- name: Summary status
run: if ${{ needs.changes.outputs.src != 'false' && needs.phpunit-mysql.result != 'success' }}; then exit 1; fi
run: if ${{ needs.changes-and-matrix.outputs.src != 'false' && needs.phpunit-mysql.result != 'success' }}; then exit 1; fi
2 changes: 1 addition & 1 deletion .github/workflows/psalm-matrix.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ jobs:

- name: Get version matrix
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
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/sync-workflow-templates.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@ jobs:
matrix:
branches:
- ${{ github.event.repository.default_branch }}
- 'stable35'
- 'stable34'
- 'stable33'
- 'stable32'

name: Update workflows in ${{ matrix.branches }}

Expand Down
49 changes: 11 additions & 38 deletions .github/workflows/update-nextcloud-ocp-approve-merge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,54 +6,27 @@
# SPDX-FileCopyrightText: 2023-2024 Nextcloud GmbH and Nextcloud contributors
# SPDX-License-Identifier: MIT

name: Auto approve nextcloud/ocp
# TODO: Remove this after a grace period of 6 months to give everyone the chance to remove the workflow
# TODO: To be removed mid 2027.
name: No-op please remove this workflow

on:
pull_request_target: # zizmor: ignore[dangerous-triggers]
branches:
- main
- master
- stable*
on: pull_request

permissions:
contents: read
contents: none

concurrency:
group: update-nextcloud-ocp-approve-merge-${{ github.head_ref || github.run_id }}
cancel-in-progress: true

jobs:
auto-approve-merge:
if: github.actor == 'nextcloud-command'
runs-on: ubuntu-latest-low
permissions:
# for auto-approve-action to approve PRs
pull-requests: write
# for alexwilson/enable-github-automerge-action to approve PRs
contents: write
if: always()

steps:
- name: Disabled on forks
if: ${{ github.event.pull_request.head.repo.full_name != github.repository }}
run: |
echo 'Can not approve PRs from forks'
exit 1

- uses: mdecoleman/pr-branch-name@55795d86b4566d300d237883103f052125cc7508 # v3.0.0
id: branchname
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
# This is the summary, we just avoid to rename it so that branch protection rules still match
name: auto-approve-merge

- name: GitHub actions bot approve
if: startsWith(steps.branchname.outputs.branch, 'automated/noid/') && endsWith(steps.branchname.outputs.branch, 'update-nextcloud-ocp')
run: gh pr review --approve "$PR_URL"
env:
PR_URL: ${{ github.event.pull_request.html_url }}
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

# Enable GitHub auto merge
- name: Auto merge
uses: alexwilson/enable-github-automerge-action@2c32e18a76e0726ffe7a573bfff2d42a20885126 # 3.0.0
if: startsWith(steps.branchname.outputs.branch, 'automated/noid/') && endsWith(steps.branchname.outputs.branch, 'update-nextcloud-ocp')
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
steps:
- name: No-op please remove this workflow
run: echo "Approve and auto-merge has been folded into update-nextcloud-ocp.yml / update-nextcloud-ocp-matrix.yml, please remove this file"; exit 1;
Loading
Loading