From 688e61b79f5fabf27452b653adf2dac6c2f28c05 Mon Sep 17 00:00:00 2001 From: andrewsy-opal Date: Tue, 26 Nov 2024 13:16:24 -0500 Subject: [PATCH] add python --- .github/workflows/autogen-remote-changes.yml | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/.github/workflows/autogen-remote-changes.yml b/.github/workflows/autogen-remote-changes.yml index 04dc307..a4b12c1 100644 --- a/.github/workflows/autogen-remote-changes.yml +++ b/.github/workflows/autogen-remote-changes.yml @@ -10,6 +10,9 @@ on: [push, pull_request] jobs: update-sdk: runs-on: ubuntu-latest + strategy: + matrix: + python-version: ["3.11"] steps: - name: Checkout repository run: | @@ -17,6 +20,21 @@ jobs: cd repo git config --global user.name "github-actions[bot]" git config --global user.email "github-actions[bot]@users.noreply.github.com" + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v5 + with: + python-version: ${{ matrix.python-version }} + - name: Set up Node.js + uses: actions/setup-node@v3 + with: + node-version: '18' + - name: Install OpenAPI Generator CLI + run: npm install @openapitools/openapi-generator-cli -g + - name: Install dependencies + run: | + cd repo + python -m pip install --upgrade pip + pip install -r requirements.txt - name: Pull and generate SDK run: | cd repo @@ -49,7 +67,7 @@ jobs: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} run: | PR_TITLE="Auto-update SDK on $(date +'%Y-%m-%d')" - PR_BODY="This pull request was automatically created by GitHub Actions to update the SDK." + PR_BODY="This pull request was automatically created by GitHub Actions to update the SDK with the latest remote OpenAPI specification." curl -H "Authorization: token $GITHUB_TOKEN" \ -X POST \ -H "Content-Type: application/json" \