Skip to content

Commit

Permalink
Merge pull request #218 from vsmalladi/197-branch
Browse files Browse the repository at this point in the history
docs: fix build
  • Loading branch information
vsmalladi authored Oct 8, 2024
2 parents e4a5720 + 1de8ebe commit d49bc65
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 19 deletions.
13 changes: 5 additions & 8 deletions .github/workflows/build-docs.yml → .github/workflows/build.yml
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]
Expand Down
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]
Expand All @@ -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:
Expand Down

0 comments on commit d49bc65

Please sign in to comment.