Skip to content

Commit

Permalink
Fix
Browse files Browse the repository at this point in the history
  • Loading branch information
mwithi committed Oct 27, 2023
1 parent aaa5b20 commit 60e24df
Showing 1 changed file with 23 additions and 17 deletions.
40 changes: 23 additions & 17 deletions .github/workflows/openapi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,24 +7,30 @@ on: [pull_request]

jobs:
build:

runs-on: ubuntu-latest

steps:
- name: Set up JDK 11
uses: actions/setup-java@v1
with:
java-version: 11
- name: Build with Maven
run: mvn -B package --file pom.xml
- name: Run
run: java -cp "target/openhospital-api-0.1.0.jar:rsc/:static/" org.springframework.boot.loader.JarLauncher
- name: Get json
run: curl -o openapi/oh.json http://localhost:8080/v3/api-docs
- name: Convert to json to yaml
uses: mikefarah/yq@master
with:
cmd: yq -p openapi/oh.json -o yaml openapi/oh.yaml
- name: Update PR
- uses: gr2m/create-or-update-pull-request-action@v1
- uses: actions/checkout@v2

- name: Set up JDK 11
uses: actions/setup-java@v1
with:
java-version: 11

- name: Build with Maven
run: mvn -B package --file pom.xml

- name: Run API
run: java -cp "target/openhospital-api-0.1.0.jar:rsc/:static/" org.springframework.boot.loader.JarLauncher

- name: Get json
run: curl -o openapi/oh.json http://localhost:8080/v3/api-docs

- name: Convert to json to yaml
uses: mikefarah/yq@master
with:
cmd: yq -p openapi/oh.json -o yaml openapi/oh.yaml

- name: Update PR
uses: gr2m/create-or-update-pull-request-action@v1

0 comments on commit 60e24df

Please sign in to comment.