Skip to content

chore: add devx bot token #284

chore: add devx bot token

chore: add devx bot token #284

Workflow file for this run

name: Generate SDK Packages
on:
pull_request:
types:
- opened
- synchronize
permissions:
contents: write
jobs:
get-changed-files:
name: Get Changed Files
runs-on: ubuntu-latest

Check failure on line 12 in .github/workflows/generate-sdk.yaml

View workflow run for this annotation

GitHub Actions / .github/workflows/generate-sdk.yaml

Invalid workflow file

You have an error in your yaml syntax on line 12
outputs:
oas-modified: ${{ steps.oas-modified.outputs.any_modified }}
steps:
- name: Check if `openapi.yaml` has changed
uses: tj-actions/[email protected]
id: oas-modified
with:
files: |
openapi.yaml
generate-js:
name: Generate JavaScript SDK
runs-on: ubuntu-latest
needs: [get-changed-files]
if: needs.get-changed-files.outputs.oas-modified == 'true'
steps:
- uses: actions/checkout@v3
with:
ref: ${{ github.event.pull_request.ref }}
path: actions
- name: Build JavaScript SDK
uses: Kong/public-shared-actions/code-build-actions/build-js-sdk@main
with:
app_directory: ${{ github.workspace }}
sdk_output_directory: ${{ github.workspace }}/actions
token: ${{ secrets.GITHUB_TOKEN }}
- name: Commit SDK changes to the PR
shell: bash
working-directory: ${{ github.workspace }}/actions
env:
GH_TOKEN: ${{ secrets.PORTAL_JS_SDK_TOKEN }}
run: |
git config --global user.email "[email protected]"
git config --global user.name "team-devx"
gh pr checkout ${{ github.event.pull_request.number }}
git add src/
git commit -m "chore: build SDK from openapi.yaml changes"
git push