Skip to content

Commit 0e0280c

Browse files
Merge pull request #613 from GDGAhmedabad/update-validate-job-workflow
[Update] validate job workflow
2 parents 7a31c0d + b2de9c5 commit 0e0280c

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

.github/workflows/validate-job-data.yaml

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ name: CI
55
# Controls when the workflow will run
66
on:
77
# Triggers the workflow on push or pull request events but only for the "develop" branch
8-
pull_request:
8+
pull_request_target:
99
branches: ["develop"]
1010
paths:
1111
- 'public/data/job-openings-data.json'
@@ -21,14 +21,17 @@ jobs:
2121
runs-on: ubuntu-latest
2222
steps:
2323
- uses: actions/checkout@v4
24+
with:
25+
# Must checkout the PR’s code, not base branch
26+
ref: ${{ github.event.pull_request.head.sha }}
2427

2528
- name: json-yaml-validate
2629
id: json-yaml-validate
27-
uses: GrantBirki/json-yaml-validate@v3.2.1 # replace with the latest version
30+
uses: GrantBirki/json-yaml-validate@v3.2.1
2831
with:
29-
comment: "true" # enable comment mode
32+
comment: "true"
3033
json_schema: public/data/schema/job-openings-schema.json
3134
files: |
3235
public/data/job-openings-data.json
3336
use_gitignore: false
34-
ajv_strict_mode: false
37+
ajv_strict_mode: false

0 commit comments

Comments
 (0)