Skip to content

Commit 7bc4499

Browse files
committed
fix(ci): Update workflows
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
1 parent 9ed82d5 commit 7bc4499

File tree

3 files changed

+26
-5
lines changed

3 files changed

+26
-5
lines changed

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

Lines changed: 21 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,9 @@ on:
1212
release:
1313
types: [published]
1414

15+
permissions:
16+
contents: write
17+
1518
jobs:
1619
build_and_publish:
1720
runs-on: ubuntu-latest
@@ -32,13 +35,25 @@ jobs:
3235
echo "APP_VERSION=${GITHUB_REF##*/}" >> $GITHUB_ENV
3336
3437
- name: Checkout
35-
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
38+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
3639
with:
40+
persist-credentials: false
3741
path: ${{ env.APP_NAME }}
3842

43+
- name: Get app version number
44+
id: app-version
45+
uses: skjnldsv/xpath-action@f5b036e9d973f42c86324833fd00be90665fbf77 # master
46+
with:
47+
filename: ${{ env.APP_NAME }}/appinfo/info.xml
48+
expression: "//info//version/text()"
49+
50+
- name: Validate app version against tag
51+
run: |
52+
[ "${{ env.APP_VERSION }}" = "v${{ fromJSON(steps.app-version.outputs.result).version }}" ]
53+
3954
- name: Get appinfo data
4055
id: appinfo
41-
uses: skjnldsv/xpath-action@7e6a7c379d0e9abc8acaef43df403ab4fc4f770c # master
56+
uses: skjnldsv/xpath-action@f5b036e9d973f42c86324833fd00be90665fbf77 # master
4257
with:
4358
filename: ${{ env.APP_NAME }}/appinfo/info.xml
4459
expression: "//info//dependencies//nextcloud/@min-version"
@@ -56,7 +71,7 @@ jobs:
5671
- name: Set up node ${{ steps.versions.outputs.nodeVersion }}
5772
# Skip if no package.json
5873
if: ${{ steps.versions.outputs.nodeVersion }}
59-
uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4.0.3
74+
uses: actions/setup-node@39370e3970a6d050c480ffad4ff0ed4d3fdee5af # v4.1.0
6075
with:
6176
node-version: ${{ steps.versions.outputs.nodeVersion }}
6277

@@ -72,7 +87,7 @@ jobs:
7287
filename: ${{ env.APP_NAME }}/appinfo/info.xml
7388

7489
- name: Set up php ${{ steps.php-versions.outputs.php-min }}
75-
uses: shivammathur/setup-php@c541c155eee45413f5b09a52248675b1a2575231 # v2.31.1
90+
uses: shivammathur/setup-php@9e72090525849c5e82e596468b86eb55e9cc5401 # v2.32.0
7691
with:
7792
php-version: ${{ steps.php-versions.outputs.php-min }}
7893
coverage: none
@@ -134,9 +149,10 @@ jobs:
134149
unzip latest-$NCVERSION.zip
135150
136151
- name: Checkout server master fallback
137-
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
152+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
138153
if: ${{ steps.server-checkout.outcome != 'success' }}
139154
with:
155+
persist-credentials: false
140156
submodules: true
141157
repository: nextcloud/server
142158
path: nextcloud

.github/workflows/integration_test.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,7 @@ jobs:
6868
with:
6969
repository: nextcloud/server
7070
ref: ${{ matrix.server-versions }}
71+
persist-credentials: false
7172

7273
- name: Checkout submodules
7374
shell: bash
@@ -87,6 +88,7 @@ jobs:
8788
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
8889
with:
8990
path: ${{ env.APP_NAME }}
91+
persist-credentials: false
9092

9193
- name: Get app version
9294
id: appinfo

.github/workflows/reuse.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,9 @@ name: REUSE Compliance Check
1111

1212
on: [pull_request]
1313

14+
permissions:
15+
contents: read
16+
1417
jobs:
1518
reuse-compliance-check:
1619
runs-on: ubuntu-latest

0 commit comments

Comments
 (0)