Skip to content

Commit 6dfb395

Browse files
authored
Merge pull request #45734 from nextcloud/ci/eol/update-workflow-stable29
2 parents f993d52 + 102a675 commit 6dfb395

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

.github/workflows/block-merge-eol.yml

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,9 @@
22
#
33
# https://github.com/nextcloud/.github
44
# https://docs.github.com/en/actions/learn-github-actions/sharing-workflows-with-your-organization
5+
#
6+
# SPDX-FileCopyrightText: 2022-2024 Nextcloud GmbH and Nextcloud contributors
7+
# SPDX-License-Identifier: MIT
58

69
name: Block merges for EOL
710

@@ -23,15 +26,15 @@ jobs:
2326
runs-on: ubuntu-latest-low
2427

2528
steps:
26-
- name: Download updater config
27-
run: curl https://raw.githubusercontent.com/nextcloud/updater_server/production/config/config.php --output config.php
28-
2929
- name: Set server major version environment
3030
run: |
3131
# retrieve version number from branch reference
3232
server_major=$(echo "${{ github.base_ref }}" | sed -En 's/stable//p')
3333
echo "server_major=$server_major" >> $GITHUB_ENV
34+
echo "current_month=$(date +%Y-%m)" >> $GITHUB_ENV
3435
3536
- name: Checking if ${{ env.server_major }} is EOL
3637
run: |
37-
php -r 'echo json_encode(require_once "config.php");' | jq --arg version "${{ env.server_major }}" '.stable[$version]["100"].eol // .beta[$version]["100"].eol // "NotEOL"' | grep -q "NotEOL"
38+
curl -s https://raw.githubusercontent.com/nextcloud-releases/updater_server/production/config/major_versions.json \
39+
| jq '.["${{ env.server_major }}"]["eol"] // "9999-99" | . >= "${{ env.current_month }}"' \
40+
| grep -q true

0 commit comments

Comments
 (0)