diff --git a/.github/workflows/update_versions.yml b/.github/workflows/update_versions.yml index b7a5ac8..4449f26 100644 --- a/.github/workflows/update_versions.yml +++ b/.github/workflows/update_versions.yml @@ -27,6 +27,8 @@ jobs: python-version: 3.12.2 - name: Update versions.json + env: + DATA_JSON: ${{ github.event.inputs.datajson }} run: | python3 update_versions.py diff --git a/update_versions.py b/update_versions.py index 8fbf158..c37c42a 100644 --- a/update_versions.py +++ b/update_versions.py @@ -1,7 +1,10 @@ import json import re +import os -data_json = "${{ github.event.inputs.datajson }}" +data_json = os.environ.get("DATA_JSON") +if not data_json: + raise ValueError("DATA_JSON environment variable not set") data = json.loads(data_json) with open('versions.json', 'r') as f: