Skip to content

posible fixed workflow file #4

posible fixed workflow file

posible fixed workflow file #4

Workflow file for this run

name: Generate Client
on:
push:
jobs:
generate-schema:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
token: ${{ secrets.RELEASE_GIT_TOKEN }}
- name: "Install Poetry"
run: "pipx install poetry"
- name: Set up Python ${{matrix.python-version}}
uses: "actions/setup-python@v5"
with:
python-version: 3.11
- name: "Install the project"
run: "poetry install"
- name: Generate Schema
run: |
cd src
poetry run python manage.py spectacular --file openapi.json --validate --format openapi-json
echo "Schema generated"
- name: Commit and push changes
run: |
git config --global user.email "github@actions.com"
git config --global user.name "GitHub Actions"
git add .
git commit -m "Generated openapi.json"
git push