Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 15 additions & 16 deletions .github/workflows/respec.yaml
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
name: respec

# author: @MikeRalphson
# author: @MikeRalphson, @ralfhandl
# issue: https://github.com/OAI/OpenAPI-Specification/issues/1564

#
# This workflow updates the respec 'pretty' rendered versions of the spec
# on the gh-pages branch when the corresponding markdown files change.
# This workflow creates a pull request for publishing HTML spec versions to the spec.openapis.org site.
#

# run this on push of new spec versions to main
# run this manually or on push of new spec versions to main
on:
push:
paths:
Expand All @@ -31,9 +30,9 @@ jobs:
app-id: ${{ secrets.OAI_SPEC_PUBLISHER_APPID }}
private-key: ${{ secrets.OAI_SPEC_PUBLISHER_PRIVATE_KEY }}
owner: OAI
repositories: OpenAPI-Specification
repositories: spec.openapis.org

- uses: actions/checkout@v5 # checkout main branch
- uses: actions/checkout@v5 # checkout main branch of this repo
with:
fetch-depth: 0

Expand All @@ -44,11 +43,11 @@ jobs:
- name: Install dependencies
run: npm ci

- uses: actions/checkout@v5 # checkout gh-pages branch
- uses: actions/checkout@v5 # checkout main branch of website repo
with:
token: ${{ steps.generate-token.outputs.token }}
repository: OAI/OpenAPI-Specification # TODO: change to OAI/...
ref: gh-pages
repository: OAI/spec.openapis.org
ref: main
path: deploy

- name: run main script
Expand All @@ -58,16 +57,16 @@ jobs:
uses: peter-evans/create-pull-request@v7
with:
token: ${{ steps.generate-token.outputs.token }}
branch: update-overlay-respec-version
base: gh-pages
branch: overlay-spec-versions
base: main
delete-branch: true
path: deploy
labels: Housekeeping
reviewers: darrelmiller,webron,earth2marsh,lornajane,mikekistler,miqui,handrews,ralfhandl
title: Overlay - Update ReSpec-rendered specification versions
labels: Overlay,Specification
reviewers: earth2marsh,lornajane,mikekistler,miqui,baywet,ralfhandl
title: Overlay - update ReSpec-rendered specification versions
commit-message: Update ReSpec-rendered specification versions
signoff: true
body: |
This pull request is automatically triggered by GitHub action `respec` in the OAI/Overlay-Specification repo.
This pull request is automatically generated by GitHub action `respec` in the OAI/Overlay-Specification repo.

The `versions/*.md` files have changed, so the HTML files are automatically being regenerated.
The `versions/*.md` files of the OpenAPI Specification have changed and the corresponding HTML files are regenerated.
32 changes: 17 additions & 15 deletions .github/workflows/schema-publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,14 @@ name: schema-publish
# author: @ralfhandl

#
# This workflow copies the x.y schemas to the gh-pages branch
# This workflow creates a pull request for publishing schema iterations to the spec.openapis.org site.
#

# run this on push to main
# run this on changes to schemas to main
on:
push:
paths:
- "schemas/**"
branches:
- main
workflow_dispatch: {}
Expand All @@ -26,9 +28,9 @@ jobs:
app-id: ${{ secrets.OAI_SPEC_PUBLISHER_APPID }}
private-key: ${{ secrets.OAI_SPEC_PUBLISHER_PRIVATE_KEY }}
owner: OAI
repositories: OpenAPI-Specification
- uses: actions/checkout@v5 # checkout main branch
repositories: spec.openapis.org

- uses: actions/checkout@v5 # checkout main branch of this repo
with:
fetch-depth: 0

Expand All @@ -39,11 +41,11 @@ jobs:
- name: Install dependencies
run: npm ci

- uses: actions/checkout@v5 # checkout gh-pages branch
- uses: actions/checkout@v5 # checkout main branch of website repo
with:
token: ${{ steps.generate-token.outputs.token }}
repository: OAI/OpenAPI-Specification
ref: gh-pages
repository: OAI/spec.openapis.org
ref: main
path: deploy

- name: run main script
Expand All @@ -53,15 +55,15 @@ jobs:
uses: peter-evans/create-pull-request@v7
with:
token: ${{ steps.generate-token.outputs.token }}
branch: publish-overlay-schema-iteration
base: gh-pages
branch: overlay-schema-iterations
base: main
delete-branch: true
path: deploy
labels: Housekeeping,Schema
reviewers: darrelmiller,webron,earth2marsh,lornajane,mikekistler,miqui,handrews,ralfhandl
title: Overlay - Publish Schema Iterations
commit-message: New Overlay schema iterations
labels: Overlay,Schema
reviewers: earth2marsh,lornajane,mikekistler,miqui,baywet,ralfhandl
title: "Overlay - publish schema iterations"
commit-message: "New Overlay schema iterations published from ${{ github.ref_name }}"
signoff: true
body: |
This pull request is automatically triggered by GitHub action `schema-publish` in the OAI/Overlay-Specification repo.
This pull request is automatically generated by GitHub action `schema-publish` in the OAI/Overlay-Specification repo.
The `schemas/**/*.yaml` files have changed and JSON files are automatically generated.