-
Notifications
You must be signed in to change notification settings - Fork 29
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #218 from vsmalladi/197-branch
docs: fix build
- Loading branch information
Showing
2 changed files
with
12 additions
and
19 deletions.
There are no files selected for viewing
13 changes: 5 additions & 8 deletions
13
.github/workflows/build-docs.yml → .github/workflows/build.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,20 @@ | ||
name: Build OpenAPI docs | ||
on: | ||
on: | ||
- push | ||
# - pull_request | ||
jobs: | ||
docs-build: | ||
runs-on: ubuntu-latest | ||
# env: | ||
# TRAVIS_BRANCH: ${{ github.event.number }} | ||
# a trick that builds docs for PRs (with PR number). Does not work for PRs from forks. | ||
steps: | ||
- name: Setup Node.js environment | ||
uses: actions/setup-node@v2.5.1 | ||
with: | ||
node-version: 14.x | ||
uses: actions/setup-node@v4.0.4 | ||
with: | ||
node-version: 18 | ||
# Comes with npm 6. For newer Node, encountered: https://github.com/npm/cli/issues/3359 | ||
- run: npm install -g @redocly/openapi-cli && npm install -g redoc-cli | ||
- run: npm install -g gh-openapi-docs | ||
- name: Check out repository code | ||
uses: actions/checkout@v2 | ||
uses: actions/checkout@v4 | ||
- run: gh-openapi-docs | ||
- name: Deploy 🚀 | ||
uses: JamesIves/[email protected] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,37 +1,33 @@ | ||
name: Lint and validate OpenAPI specs | ||
|
||
on: | ||
- push | ||
- pull_request | ||
|
||
- pull_request_target | ||
jobs: | ||
|
||
lint: | ||
name: Lint OpenAPI definition | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Check out head branch | ||
uses: actions/checkout@v2 | ||
uses: actions/checkout@v4 | ||
- name: Run OpenAPI Lint Action | ||
uses: nwestfall/[email protected] | ||
with: | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
file: openapi/task_execution_service.openapi.yaml | ||
|
||
diff: | ||
name: Show OpenAPI differences relative to target branch | ||
runs-on: ubuntu-latest | ||
if: ${{ github.event_name == 'pull_request' }} | ||
steps: | ||
- name: Check out head branch | ||
uses: actions/checkout@v2 | ||
uses: aactions/checkout@v4 | ||
with: | ||
ref: ${{ github.head_ref }} | ||
ref: ${{ github.ref }} | ||
path: head | ||
- name: Check out base branch | ||
uses: actions/checkout@v2 | ||
uses: actions/checkout@v4 | ||
with: | ||
ref: ${{ github.base_ref }} | ||
ref: ${{ github.event.pull_request.base.ref }} | ||
path: base | ||
- name: Run OpenAPI Diff Action | ||
uses: mvegter/[email protected] | ||
|
@@ -44,7 +40,7 @@ jobs: | |
runs-on: ubuntu-latest | ||
steps: | ||
- name: Check out head branch | ||
uses: actions/checkout@v2 | ||
uses: actions/checkout@v4 | ||
- name: Run OpenAPI Validate Action | ||
uses: char0n/swagger-editor-validate@v1 | ||
with: | ||
|