Skip to content

Commit b16a5d4

Browse files
ci(actions): Update workflow templates from organization template repository
Signed-off-by: GitHub <noreply@github.com>
1 parent 62ec806 commit b16a5d4

16 files changed

Lines changed: 56 additions & 126 deletions

.github/actions-lock.txt

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,22 @@
11
# SPDX-FileCopyrightText: 2025 Nextcloud GmbH and Nextcloud contributors
22
# SPDX-License-Identifier: MIT
3-
e20c2aa019763dd8c01214150f203ec6 appstore-build-publish.yml
4-
7dd8d21d9dd013196cd4bdbf7c24db6f dependabot-approve-merge.yml
3+
43851fd8e1125e1083be704056616c9a appstore-build-publish.yml
4+
d00c282925ce19918cc26ec0827d9726 dependabot-approve-merge.yml
55
7bcfba381bfb7c28d9ef6a7d55ac937b lint-eslint.yml
66
80a58e5584612def0e751fcfb7669814 lint-info-xml.yml
7-
ccd8a55c60e35b84becb0f7005ce1286 lint-php-cs.yml
8-
5dcc3187a9460cb62a455235cbdb3562 lint-php.yml
7+
058024e4560ae1f18f6e4be9ecc0dacb lint-php-cs.yml
8+
d86aa09feb6ce2ad244926aff7adcb36 lint-php.yml
99
bd5b5245dc07b5779031e13817663a3e lint-stylelint.yml
10-
c98e518ff87d052a1236ac3fc40d2bc1 node.yml
11-
e54d4276168426a10219333cf10e0d10 npm-audit-fix.yml
12-
3488e09e545319403424fa66a02e6c05 openapi.yml
13-
bdca1af74c27de9a9fc2f3c70aabdc8f phpunit-mariadb.yml
14-
5846b994639ccab0059bf23e141d389a phpunit-mysql.yml
15-
ec7d1084fbb3a6803dbabf3acdd17ac8 phpunit-oci.yml
16-
29b359a5b76e7ff8cd85af34b3bf36e3 phpunit-pgsql.yml
17-
182cc739d33a2441d3a9278a9bff55b4 phpunit-sqlite.yml
10+
03759c9dc0fa748cb927b9f9cadf2925 node.yml
11+
20d567b2158851c6b54170e0a7c7fc30 npm-audit-fix.yml
12+
887e74a10fb81844981217e649551793 openapi.yml
13+
6da74afd101a7c60f4db81b124b1c977 phpunit-mariadb.yml
14+
efac00595fcf8c91902a40467bb8e58a phpunit-mysql.yml
15+
ea1ad2b41d5c8730af03c2923fd0d90d phpunit-oci.yml
16+
5f7de35e496afb4f1206fe18017d6320 phpunit-pgsql.yml
17+
10d907363827d671d37831b78c0a1137 phpunit-sqlite.yml
1818
3c4a096b3b7dbaef0f8e5190ffe13518 pr-feedback.yml
19-
a6d8aa0050107ce4d8b6d166d25ca8aa psalm.yml
19+
a965b7d4820a97cc232a24f6caf90d95 psalm.yml
2020
7db5b820f3750eebe988005a0bb2febd reuse.yml
21-
800d5b188aa885626cf4169fa2dfea9e update-nextcloud-ocp-approve-merge.yml
22-
90f22641445623fb227102f8d2d87cc0 update-nextcloud-ocp.yml
21+
78bd5cbcc4b48cb9b0d1b0fbbb4403d7 update-nextcloud-ocp-approve-merge.yml
22+
c62537b3800cce229cae328bd206a3d4 update-nextcloud-ocp.yml

.github/workflows/appstore-build-publish.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,7 @@ jobs:
7474
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
7575
with:
7676
node-version: ${{ steps.versions.outputs.nodeVersion }}
77+
package-manager-cache: false
7778

7879
- name: Set up npm ${{ steps.versions.outputs.npmVersion }}
7980
# Skip if no package.json
@@ -87,7 +88,7 @@ jobs:
8788
filename: ${{ env.APP_NAME }}/appinfo/info.xml
8889

8990
- name: Set up php ${{ steps.php-versions.outputs.php-min }}
90-
uses: shivammathur/setup-php@accd6127cb78bee3e8082180cb391013d204ef9f # v2.37.0
91+
uses: shivammathur/setup-php@accd6127cb78bee3e8082180cb391013d204ef9f # 2.37.0
9192
with:
9293
php-version: ${{ steps.php-versions.outputs.php-min }}
9394
coverage: none
@@ -181,7 +182,7 @@ jobs:
181182
tar -zcvf ${{ env.APP_NAME }}.tar.gz ${{ env.APP_NAME }}
182183
183184
- name: Attach tarball to github release
184-
uses: svenstaro/upload-release-action@29e53e917877a24fad85510ded594ab3c9ca12de # v2.11.5
185+
uses: svenstaro/upload-release-action@29e53e917877a24fad85510ded594ab3c9ca12de # 2.11.5
185186
id: attach_to_release
186187
with:
187188
repo_token: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/dependabot-approve-merge.yml

Lines changed: 13 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ jobs:
2727
if: github.event.pull_request.user.login == 'dependabot[bot]'
2828
runs-on: ubuntu-latest-low
2929
permissions:
30-
# for hmarr/auto-approve-action to approve PRs
30+
# for auto-approve step to work
3131
pull-requests: write
3232
# for alexwilson/enable-github-automerge-action to approve PRs
3333
contents: write
@@ -44,15 +44,22 @@ jobs:
4444
with:
4545
repo-token: ${{ secrets.GITHUB_TOKEN }}
4646

47-
# GitHub actions bot approve
48-
- uses: hmarr/auto-approve-action@f0939ea97e9205ef24d872e76833fa908a770363 # v4.0.0
49-
if: startsWith(steps.branchname.outputs.branch, 'dependabot/')
47+
- name: Dependabot metadata
48+
id: metadata
49+
uses: dependabot/fetch-metadata@ffa630c65fa7e0ecfa0625b5ceda64399aea1b36 # v3.0.0
5050
with:
5151
github-token: ${{ secrets.GITHUB_TOKEN }}
5252

53+
- name: GitHub actions bot approve
54+
if: startsWith(steps.branchname.outputs.branch, 'dependabot/')
55+
run: gh pr review --approve "$PR_URL"
56+
env:
57+
PR_URL: ${{ github.event.pull_request.html_url }}
58+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
59+
5360
# Enable GitHub auto merge
5461
- name: Auto merge
55-
uses: alexwilson/enable-github-automerge-action@56e3117d1ae1540309dc8f7a9f2825bc3c5f06ff # v2.0.0
56-
if: startsWith(steps.branchname.outputs.branch, 'dependabot/') && (github.event.pull_request.action == 'opened' || github.event.pull_request.action == 'reopened')
62+
uses: alexwilson/enable-github-automerge-action@56e3117d1ae1540309dc8f7a9f2825bc3c5f06ff # 2.0.0
63+
if: startsWith(steps.branchname.outputs.branch, 'dependabot/') && (github.event.action == 'opened' || github.event.action == 'reopened') && (steps.metadata.outputs.update-type == 'version-update:semver-patch' || steps.metadata.outputs.update-type == 'version-update:semver-minor')
5764
with:
5865
github-token: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/lint-php-cs.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ jobs:
3434
uses: icewind1991/nextcloud-version-matrix@8a7bac6300b2f0f3100088b297995a229558ddba # v1.3.2
3535

3636
- name: Set up php${{ steps.versions.outputs.php-min }}
37-
uses: shivammathur/setup-php@accd6127cb78bee3e8082180cb391013d204ef9f # v2.37.0
37+
uses: shivammathur/setup-php@accd6127cb78bee3e8082180cb391013d204ef9f # 2.37.0
3838
with:
3939
php-version: ${{ steps.versions.outputs.php-min }}
4040
extensions: bz2, ctype, curl, dom, fileinfo, gd, iconv, intl, json, libxml, mbstring, openssl, pcntl, posix, session, simplexml, xmlreader, xmlwriter, zip, zlib, sqlite, pdo_sqlite

.github/workflows/lint-php.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ jobs:
4949
persist-credentials: false
5050

5151
- name: Set up php ${{ matrix.php-versions }}
52-
uses: shivammathur/setup-php@accd6127cb78bee3e8082180cb391013d204ef9f # v2.37.0
52+
uses: shivammathur/setup-php@accd6127cb78bee3e8082180cb391013d204ef9f # 2.37.0
5353
with:
5454
php-version: ${{ matrix.php-versions }}
5555
extensions: bz2, ctype, curl, dom, fileinfo, gd, iconv, intl, json, libxml, mbstring, openssl, pcntl, posix, session, simplexml, xmlreader, xmlwriter, zip, zlib, sqlite, pdo_sqlite

.github/workflows/node.yml

Lines changed: 6 additions & 87 deletions
Original file line numberDiff line numberDiff line change
@@ -6,108 +6,27 @@
66
# SPDX-FileCopyrightText: 2021-2024 Nextcloud GmbH and Nextcloud contributors
77
# SPDX-License-Identifier: MIT
88

9-
name: Node
9+
# TODO: Remove this after a grace period of 6 months to give everyone the chance to switch to the new workflow name
10+
# TODO: To be removed end of 2026.
11+
name: No-op please switch to npm-build.yml
1012

1113
on: pull_request
1214

1315
permissions:
14-
contents: read
16+
contents: none
1517

1618
concurrency:
1719
group: node-${{ github.head_ref || github.run_id }}
1820
cancel-in-progress: true
1921

2022
jobs:
21-
changes:
22-
runs-on: ubuntu-latest-low
23-
permissions:
24-
contents: read
25-
pull-requests: read
26-
27-
outputs:
28-
src: ${{ steps.changes.outputs.src}}
29-
30-
steps:
31-
- uses: dorny/paths-filter@fbd0ab8f3e69293af611ebaee6363fc25e6d187d # v4.0.1
32-
id: changes
33-
continue-on-error: true
34-
with:
35-
filters: |
36-
src:
37-
- '.github/workflows/**'
38-
- 'src/**'
39-
- 'appinfo/info.xml'
40-
- 'package.json'
41-
- 'package-lock.json'
42-
- 'tsconfig.json'
43-
- '**.js'
44-
- '**.ts'
45-
- '**.vue'
46-
47-
build:
48-
runs-on: ubuntu-latest
49-
50-
needs: changes
51-
if: needs.changes.outputs.src != 'false'
52-
53-
name: NPM build
54-
steps:
55-
- name: Checkout
56-
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
57-
with:
58-
persist-credentials: false
59-
60-
- name: Read package.json node and npm engines version
61-
uses: skjnldsv/read-package-engines-version-actions@06d6baf7d8f41934ab630e97d9e6c0bc9c9ac5e4 # v3
62-
id: versions
63-
with:
64-
fallbackNode: '^24'
65-
fallbackNpm: '^11.3'
66-
67-
- name: Set up node ${{ steps.versions.outputs.nodeVersion }}
68-
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
69-
with:
70-
node-version: ${{ steps.versions.outputs.nodeVersion }}
71-
72-
- name: Set up npm ${{ steps.versions.outputs.npmVersion }}
73-
run: npm i -g 'npm@${{ steps.versions.outputs.npmVersion }}'
74-
75-
- name: Validate package-lock.json # See https://github.com/npm/cli/issues/4460
76-
run: |
77-
npm i -g npm-package-lock-add-resolved@1.1.4
78-
npm-package-lock-add-resolved
79-
git --no-pager diff --exit-code
80-
81-
- name: Install dependencies & build
82-
env:
83-
CYPRESS_INSTALL_BINARY: 0
84-
PUPPETEER_SKIP_DOWNLOAD: true
85-
run: |
86-
npm ci
87-
npm run build --if-present
88-
89-
- name: Check build changes
90-
run: |
91-
bash -c "[[ ! \"`git status --porcelain `\" ]] || (echo 'Please recompile and commit the assets, see the section \"Show changes on failure\" for details' && exit 1)"
92-
93-
- name: Show changes on failure
94-
if: failure()
95-
run: |
96-
git status
97-
git --no-pager diff
98-
exit 1 # make it red to grab attention
99-
10023
summary:
101-
permissions:
102-
contents: none
10324
runs-on: ubuntu-latest-low
104-
needs: [changes, build]
105-
10625
if: always()
10726

10827
# This is the summary, we just avoid to rename it so that branch protection rules still match
10928
name: node
11029

11130
steps:
112-
- name: Summary status
113-
run: if ${{ needs.changes.outputs.src != 'false' && needs.build.result != 'success' }}; then exit 1; fi
31+
- name: No-op please switch to npm-build.yml
32+
run: echo "The workflow has been renamed, please switch to npm-build.yml from organization templates"; exit 1;

.github/workflows/npm-audit-fix.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ jobs:
2626
matrix:
2727
branches:
2828
- ${{ github.event.repository.default_branch }}
29+
- 'stable34'
2930
- 'stable33'
3031
- 'stable32'
3132

.github/workflows/openapi.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ jobs:
3535
uses: icewind1991/nextcloud-version-matrix@8a7bac6300b2f0f3100088b297995a229558ddba # v1.3.2
3636

3737
- name: Set up php
38-
uses: shivammathur/setup-php@accd6127cb78bee3e8082180cb391013d204ef9f # v2.37.0
38+
uses: shivammathur/setup-php@accd6127cb78bee3e8082180cb391013d204ef9f # 2.37.0
3939
with:
4040
php-version: ${{ steps.php_versions.outputs.php-available }}
4141
extensions: xml

.github/workflows/phpunit-mariadb.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ jobs:
105105
path: apps/${{ env.APP_NAME }}
106106

107107
- name: Set up php ${{ matrix.php-versions }}
108-
uses: shivammathur/setup-php@accd6127cb78bee3e8082180cb391013d204ef9f # v2.37.0
108+
uses: shivammathur/setup-php@accd6127cb78bee3e8082180cb391013d204ef9f # 2.37.0
109109
with:
110110
php-version: ${{ matrix.php-versions }}
111111
# https://docs.nextcloud.com/server/stable/admin_manual/installation/source_installation.html#prerequisites-for-manual-installation

.github/workflows/phpunit-mysql.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ jobs:
103103
path: apps/${{ env.APP_NAME }}
104104

105105
- name: Set up php ${{ matrix.php-versions }}
106-
uses: shivammathur/setup-php@accd6127cb78bee3e8082180cb391013d204ef9f # v2.37.0
106+
uses: shivammathur/setup-php@accd6127cb78bee3e8082180cb391013d204ef9f # 2.37.0
107107
with:
108108
php-version: ${{ matrix.php-versions }}
109109
# https://docs.nextcloud.com/server/stable/admin_manual/installation/source_installation.html#prerequisites-for-manual-installation

0 commit comments

Comments
 (0)