From b2f59224a6f1fd298948c873bf3c106abc8093ed Mon Sep 17 00:00:00 2001 From: Justin Flannery Date: Thu, 26 Dec 2024 16:06:04 -0700 Subject: [PATCH] =?UTF-8?q?=F0=9F=91=B7=20ci=20generation?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/generator.yaml | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/.github/workflows/generator.yaml b/.github/workflows/generator.yaml index d0132f9..831bf18 100644 --- a/.github/workflows/generator.yaml +++ b/.github/workflows/generator.yaml @@ -31,17 +31,22 @@ jobs: run: npm audit signatures - name: Generate OpenAPI Client run: npm run generate - - name: Get OpenAPI Spec - id: openapi + - name: Get OpenAPI YAML + id: yaml + run: spec="$(curl -LsSf ${{ env.OPENAPI_URL }})" echo spec="${spec}" >> ${GITHUB_OUTPUT} + env: + OPENAPI_URL: https://lm-v2-api-mock-data-f24357049a1b.herokuapp.com/v2/openapi + - name: Get OpenAPI JSON + id: json uses: mikefarah/yq@master with: - cmd: curl -LsSf "${{ env.OPENAPI_URL }}" | yq --output-format json + cmd: echo "${{ steps.yaml.outputs.spec }}" | yq --output-format json env: OPENAPI_URL: https://lm-v2-api-mock-data-f24357049a1b.herokuapp.com/v2/openapi - name: Get OpenAPI Spec Version id: version run: | - version=$(echo "${{ steps.openapi.outputs.result }}" | jq -r .info.version) + version=$(echo "${{ steps.json.outputs.result }}" | jq -r .info.version) echo version=${version} >> ${GITHUB_OUTPUT} - name: Create Pull Request uses: peter-evans/create-pull-request@v7