Skip to content

Commit 238fd07

Browse files
committed
fix: set target branch
1 parent 2c6c824 commit 238fd07

File tree

1 file changed

+11
-7
lines changed

1 file changed

+11
-7
lines changed

.github/workflows/en-api-docs.yml

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ jobs:
2626
uses: actions/checkout@v4
2727
with:
2828
ref: refs/heads/main
29+
path: main
2930
sparse-checkout: |
3031
.github/scripts
3132
token: ${{ secrets.GITHUB_TOKEN }}
@@ -34,7 +35,7 @@ jobs:
3435
uses: actions/checkout@v4
3536
with:
3637
ref: refs/heads/en
37-
path: openapi
38+
path: api-schemas
3839
token: ${{ secrets.GITHUB_TOKEN }}
3940

4041
- name: Set up Node.js
@@ -43,17 +44,20 @@ jobs:
4344
node-version: ${{ matrix.node-version }}
4445

4546
- name: Install script dependencies
46-
working-directory: .github/scripts
47+
working-directory: main/.github/scripts
4748
run: npm install
4849

4950
- name: Run add-code-samples script
50-
working-directory: .github/scripts
51-
run: npm run add-code-samples -- "../../openapi" "openapi.*\\.json"
51+
working-directory: main/.github/scripts
52+
run: npm run add-code-samples -- "../../../api-schemas" "openapi.*\\.json"
5253

53-
- name: Push openapi directory to en-api-docs branch
54+
- name: Run add-code-samples script
55+
run: echo "README" > api-schemas/README.md
56+
57+
- name: Push processed files to en-api-docs branch
5458
5559
env:
5660
REPO: self
57-
BRANCH: refs/heads/en-api-docs
58-
FOLDER: openapi
61+
BRANCH: en-api-docs
62+
FOLDER: api-schemas
5963
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)