diff options
author | jld3103 <jld3103yt@gmail.com> | 2023-08-11 14:36:14 +0200 |
---|---|---|
committer | Joas Schilling <coding@schilljs.com> | 2023-10-05 17:05:05 +0200 |
commit | dcec4465bbe1e45e5a7a2bd979572c56c74f2d3a (patch) | |
tree | 462a3ec25c76e2c4215e83d5751f0dbf7b214bc1 | |
parent | 70511e69c0d5e6cfb24e2755cd0e4499c5e32494 (diff) |
Add OpenAPI CItechdebt/noid/openapi
Signed-off-by: jld3103 <jld3103yt@gmail.com>
-rw-r--r-- | .github/workflows/openapi.yml | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/.github/workflows/openapi.yml b/.github/workflows/openapi.yml new file mode 100644 index 000000000..554870ae8 --- /dev/null +++ b/.github/workflows/openapi.yml @@ -0,0 +1,46 @@ +name: OpenAPI + +on: + pull_request: + push: + branches: + - master + - stable* + +permissions: + contents: read + +concurrency: + group: openapi-${{ github.head_ref || github.run_id }} + cancel-in-progress: true + +jobs: + openapi: + runs-on: ubuntu-latest + + if: ${{ github.repository_owner != 'nextcloud-gmbh' }} + + steps: + - name: Checkout + uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 + + - name: Set up php + uses: shivammathur/setup-php@c5fc0d8281aba02c7fda07d3a70cc5371548067d # v2 + with: + php-version: '8.2' + extensions: xml + coverage: none + ini-file: development + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + + - name: Set up dependencies + run: composer i + + - name: Check OpenAPI + run: | + composer run openapi + if [ -n "$(git status --porcelain openapi.json)" ]; then + git diff + exit 1 + fi |