Skip to content

Commit 3a7cdad

Browse files
authored
Merge pull request #176 from OAI/chore/sync-main-to-v1.1-dev
v1.1-dev: sync from main
2 parents 60a1bb5 + f0d6cc9 commit 3a7cdad

File tree

14 files changed

+2590
-1683
lines changed

14 files changed

+2590
-1683
lines changed

.github/CODEOWNERS

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
* @oai/tsc
1+
* @oai/tsc @OAI/overlay-maintainers

.github/dependabot.yml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
version: 2
2+
updates:
3+
- package-ecosystem: github-actions
4+
directory: "/"
5+
schedule:
6+
interval: daily
7+
open-pull-requests-limit: 10
8+
- package-ecosystem: npm
9+
directory: "/"
10+
schedule:
11+
interval: daily
12+
open-pull-requests-limit: 10
13+
groups:
14+
vitest:
15+
patterns:
16+
- "*vitest*"

.github/workflows/agenda.yaml

Lines changed: 19 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,28 +3,44 @@ name: Create meeting template
33
on:
44
workflow_dispatch: {}
55
schedule:
6-
# every two weeks on tuesday at 10AM PST (with DST)
7-
- cron: '0 17 */14 * 2'
6+
# every week on tuesday at 10AM PST (with DST)
7+
- cron: '0 17 * * 2'
88

99
jobs:
1010
create-discussion:
1111
permissions:
1212
discussions: write
1313
runs-on: ubuntu-22.04
1414
steps:
15-
- uses: actions/checkout@v4
15+
- uses: actions/checkout@v5
16+
- name: Check if it's an alternate week
17+
id: check-week
18+
run: |
19+
# Get ISO week number (1-53)
20+
WEEK_NUMBER=$(date +%V)
21+
# Check if week number is odd or even to run workflow and create agenda for next week's meeting
22+
if [ $((WEEK_NUMBER % 2)) -eq 0 ]; then
23+
echo "Should run this week (even week: $WEEK_NUMBER)"
24+
echo "should_run=true" >> $GITHUB_OUTPUT
25+
else
26+
echo "Skipping odd week: $WEEK_NUMBER"
27+
echo "should_run=false" >> $GITHUB_OUTPUT
28+
fi
1629
- name: Get agenda text from template
30+
if: steps.check-week.outputs.should_run == 'true'
1731
id: get-agenda
1832
run: |
1933
echo 'AGENDA<<EOF' >> $GITHUB_ENV
2034
cat .github/templates/agenda.md >> $GITHUB_ENV
2135
echo 'EOF' >> $GITHUB_ENV
2236
- name: Get Next Meeting Date
37+
if: steps.check-week.outputs.should_run == 'true'
2338
id: get-next-meeting-date
2439
run: |
2540
NEXT_MEETING_DATE=$(date -d "next Tuesday" +%Y-%m-%d)
2641
echo "NEXT_MEETING_DATE=$NEXT_MEETING_DATE" >> $GITHUB_ENV
2742
- name: Create discussion with agenda
43+
if: steps.check-week.outputs.should_run == 'true'
2844
id: create-repository-discussion
2945
uses: octokit/[email protected]
3046
env:

.github/workflows/respec.yaml

Lines changed: 47 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -4,68 +4,70 @@ name: respec
44
# issue: https://github.com/OAI/OpenAPI-Specification/issues/1564
55

66
#
7-
# This workflow updates the respec 'pretty' rendered versions of the spec
7+
# This workflow updates the respec 'pretty' rendered versions of the spec
88
# on the gh-pages branch when the corresponding markdown files change.
99
#
1010

11-
# run this on push to main
11+
# run this on push of new spec versions to main
1212
on:
1313
push:
14+
paths:
15+
- "versions/**"
1416
branches:
1517
- main
1618
workflow_dispatch: {}
1719

1820
jobs:
1921
respec:
2022
if: github.repository == 'OAI/Overlay-Specification'
21-
23+
2224
runs-on: ubuntu-22.04
2325

2426
steps:
25-
- name: Generate access token
26-
id: generate-token
27-
uses: actions/create-github-app-token@v1
28-
with:
29-
app-id: ${{ secrets.OAI_SPEC_PUBLISHER_APPID }}
30-
private-key: ${{ secrets.OAI_SPEC_PUBLISHER_PRIVATE_KEY }}
31-
owner: OAI
32-
repositories: OpenAPI-Specification
33-
34-
- uses: actions/checkout@v4 # checkout main branch
35-
with:
36-
fetch-depth: 0
27+
- name: Generate access token
28+
id: generate-token
29+
uses: actions/create-github-app-token@v1
30+
with:
31+
app-id: ${{ secrets.OAI_SPEC_PUBLISHER_APPID }}
32+
private-key: ${{ secrets.OAI_SPEC_PUBLISHER_PRIVATE_KEY }}
33+
owner: OAI
34+
repositories: OpenAPI-Specification
35+
36+
- uses: actions/checkout@v5 # checkout main branch
37+
with:
38+
fetch-depth: 0
39+
40+
- uses: actions/setup-node@v6 # setup Node.js
41+
with:
42+
node-version: "22.x"
3743

38-
- uses: actions/setup-node@v4 # setup Node.js
39-
with:
40-
node-version: '20.x'
41-
42-
- name: Install dependencies
43-
run: npm ci
44+
- name: Install dependencies
45+
run: npm ci
4446

45-
- uses: actions/checkout@v4 # checkout gh-pages branch
46-
with:
47-
token: ${{ steps.generate-token.outputs.token }}
48-
repository: OAI/OpenAPI-Specification # TODO: change to OAI/...
49-
ref: gh-pages
50-
path: deploy
47+
- uses: actions/checkout@v5 # checkout gh-pages branch
48+
with:
49+
token: ${{ steps.generate-token.outputs.token }}
50+
repository: OAI/OpenAPI-Specification # TODO: change to OAI/...
51+
ref: gh-pages
52+
path: deploy
5153

52-
- name: run main script
53-
run: scripts/md2html/build.sh
54+
- name: run main script
55+
run: scripts/md2html/build.sh
5456

55-
- name: Create Pull Request
56-
uses: peter-evans/create-pull-request@v7
57-
with:
58-
token: ${{ steps.generate-token.outputs.token }}
59-
branch: update-overlay-respec-version
60-
base: gh-pages
61-
delete-branch: true
62-
path: deploy
63-
labels: Housekeeping
64-
reviewers: darrelmiller,webron,earth2marsh,lornajane,mikekistler,miqui,handrews,ralfhandl
65-
title: Overlay - Update ReSpec-rendered specification versions
66-
commit-message: Update ReSpec-rendered specification versions
67-
signoff: true
68-
body: |
69-
This pull request is automatically triggered by GitHub action `respec` in the OAI/Overlay-Specification repo.
57+
- name: Create Pull Request
58+
uses: peter-evans/create-pull-request@v7
59+
with:
60+
token: ${{ steps.generate-token.outputs.token }}
61+
branch: update-overlay-respec-version
62+
base: gh-pages
63+
delete-branch: true
64+
path: deploy
65+
labels: Housekeeping
66+
reviewers: darrelmiller,webron,earth2marsh,lornajane,mikekistler,miqui,handrews,ralfhandl
67+
title: Overlay - Update ReSpec-rendered specification versions
68+
commit-message: Update ReSpec-rendered specification versions
69+
signoff: true
70+
body: |
71+
This pull request is automatically triggered by GitHub action `respec` in the OAI/Overlay-Specification repo.
7072
71-
The `versions/*.md` files have changed, so the HTML files are automatically being regenerated.
73+
The `versions/*.md` files have changed, so the HTML files are automatically being regenerated.

.github/workflows/schema-publish.yaml

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -15,30 +15,31 @@ on:
1515

1616
jobs:
1717
publish:
18+
if: github.repository == 'OAI/Overlay-Specification'
1819
runs-on: ubuntu-latest
1920

2021
steps:
2122
- name: Generate access token
2223
id: generate-token
23-
uses: actions/create-github-app-token@v1
24+
uses: actions/create-github-app-token@v2
2425
with:
2526
app-id: ${{ secrets.OAI_SPEC_PUBLISHER_APPID }}
2627
private-key: ${{ secrets.OAI_SPEC_PUBLISHER_PRIVATE_KEY }}
2728
owner: OAI
2829
repositories: OpenAPI-Specification
2930

30-
- uses: actions/checkout@v4 # checkout main branch
31+
- uses: actions/checkout@v5 # checkout main branch
3132
with:
3233
fetch-depth: 0
3334

34-
- uses: actions/setup-node@v4 # setup Node.js
35+
- uses: actions/setup-node@v6 # setup Node.js
3536
with:
36-
node-version: 20.x
37+
node-version: "22.x"
3738

3839
- name: Install dependencies
3940
run: npm ci
4041

41-
- uses: actions/checkout@v4 # checkout gh-pages branch
42+
- uses: actions/checkout@v5 # checkout gh-pages branch
4243
with:
4344
token: ${{ steps.generate-token.outputs.token }}
4445
repository: OAI/OpenAPI-Specification

.github/workflows/schema-tests.yaml

Lines changed: 14 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -8,30 +8,28 @@ name: schema-tests
88
# testcases for the metaschemas
99
#
1010

11-
# run this on push to any branch and creation of pull-requests
12-
on:
13-
push: {}
11+
# run this on pull-requests (creation and updates) and on manual trigger
12+
on:
1413
pull_request: {}
1514
workflow_dispatch: {}
1615

1716
jobs:
1817
test:
19-
2018
runs-on: ubuntu-latest
2119

2220
steps:
23-
- uses: actions/checkout@v4 # checkout repo content
24-
with:
25-
fetch-depth: 0
21+
- uses: actions/checkout@v5 # checkout repo content
22+
with:
23+
fetch-depth: 0
2624

27-
- uses: actions/setup-node@v4 # setup Node.js
28-
with:
29-
node-version: '20.x'
25+
- uses: actions/setup-node@v6 # setup Node.js
26+
with:
27+
node-version: "22.x"
3028

31-
- name: Install dependencies from main
32-
run: |
33-
# git checkout remotes/origin/main -- package.json package-lock.json #TODO: uncomment with subsequent PR
34-
npm ci
29+
- name: Install dependencies
30+
run: npm ci
3531

36-
- name: Run tests
37-
run: npm test
32+
- name: Run tests
33+
run: npm test
34+
env:
35+
BASE: ${{ github.event.pull_request.base.ref }}

.github/workflows/validate-markdown.yaml

Lines changed: 17 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -7,25 +7,26 @@ name: validate-markdown
77
# This workflow validates markdown files in the versions directory matching *.md
88
#
99

10-
# run this on push to any branch and creation of pull-requests
11-
on: [push, pull_request]
10+
# run this on pull-requests (creation and updates) and on manual trigger
11+
on:
12+
pull_request: {}
13+
workflow_dispatch: {}
1214

1315
jobs:
1416
mdv:
15-
1617
runs-on: ubuntu-latest
1718

1819
steps:
19-
- uses: actions/checkout@v4 # checkout repo content
20-
with:
21-
fetch-depth: 0
22-
# - name: use the javascript environment from main
23-
# run: |
24-
# git checkout remotes/origin/main -- package.json package-lock.json .markdownlint.yaml
25-
- uses: actions/setup-node@v4 # setup Node.js
26-
with:
27-
node-version: '20.x'
28-
- name: Validate markdown
29-
run: npx --yes mdv versions/*.md
30-
- name: Lint markdown
31-
run: npx --yes markdownlint-cli --config .markdownlint.yaml versions/*.md
20+
- uses: actions/checkout@v5 # checkout repo content
21+
with:
22+
fetch-depth: 0
23+
# - name: use the javascript environment from main
24+
# run: |
25+
# git checkout remotes/origin/main -- package.json package-lock.json .markdownlint.yaml
26+
- uses: actions/setup-node@v6 # setup Node.js
27+
with:
28+
node-version: "22.x"
29+
- name: Validate markdown
30+
run: npx --yes mdv versions/*.md
31+
- name: Lint markdown
32+
run: npx --yes markdownlint-cli --config .markdownlint.yaml versions/*.md

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ If you are looking for tools to use with Overlays, try these:
2626
- [oas-overlay-java](https://github.com/IBM/oas-overlay-java)
2727
- [Specmatic](https://specmatic.io/) - [Docs](https://docs.specmatic.io/documentation/contract_tests.html#overlays)
2828
- [BinkyLabs.OpenApi.Overlays - dotnet](https://github.com/BinkyLabs/openapi-overlays-dotnet)
29+
- [Legba - Clojure OpenAPI toolkit](https://github.com/mpenet/legba?tab=readme-ov-file#openapi-overlay-support)
2930

3031
(Is something missing from the list? Send us a pull request to add it!)
3132

0 commit comments

Comments
 (0)