File tree Expand file tree Collapse file tree 6 files changed +269
-116
lines changed
Expand file tree Collapse file tree 6 files changed +269
-116
lines changed Original file line number Diff line number Diff line change 1+ name : Algolia Integrity
2+ on :
3+ pull_request :
4+ paths :
5+ - ' website/**'
6+ branches :
7+ - master
8+ jobs :
9+ algolia-records-check :
10+ runs-on : ubuntu-latest
11+ steps :
12+ - name : Checkout
13+ uses : actions/checkout@v3
14+
15+ - name : Fetch
16+ run : git fetch origin master
17+
18+ - name : Setup env
19+ uses : the-guild-org/shared-config/setup@main
20+ with :
21+ nodeVersion : 18
22+ packageManager : pnpm
23+
24+ - name : Build Packages
25+ run : pnpm build
26+
27+ - name : Typecheck
28+ run : pnpm --filter website build
29+
30+ - name : Algolia generate
31+ run : pnpm --filter website algolia-sync
32+ env :
33+ ALGOLIA_DRY_RUN : true
34+ SITE_URL : https://www.the-guild.dev/graphql/inspector/
35+
36+ - name : Format
37+ run : pnpm prettier
38+
39+ - name : Compare
40+ run : git diff origin/${{ github.base_ref }}.. -- website/algolia-lockfile.json
41+
42+ - name : Diff to file
43+ if : always()
44+ id : diff_result
45+ run : |
46+ OUTPUT=$(git diff origin/${{ github.base_ref }}.. -- website/algolia-lockfile.json)
47+ OUTPUT="${OUTPUT//'%'/'%25'}"
48+ OUTPUT="${OUTPUT//$'\n'/'%0A'}"
49+ OUTPUT="${OUTPUT//$'\r'/'%0D'}"
50+ echo "::set-output name=result::$OUTPUT"
51+
52+ - name : Publish a message
53+ if : always() && contains(steps.diff_result.outputs.result, 'diff')
54+ uses : marocchino/sticky-pull-request-comment@v2
55+ with :
56+ message : |
57+ ```diff
58+ ${{ steps.diff_result.outputs.result }}
59+ ```
Original file line number Diff line number Diff line change 1+ name : Algolia Publish
2+
3+ on :
4+ push :
5+ branches :
6+ - master
7+
8+ jobs :
9+ algolia-push-records :
10+ name : Push new records if changes
11+ runs-on : ubuntu-latest
12+ steps :
13+ - name : Checkout Repo
14+ uses : actions/checkout@v3
15+
16+ - name : Setup env
17+ uses : the-guild-org/shared-config/setup@main
18+ with :
19+ nodeVersion : 18
20+ packageManager : pnpm
21+
22+ - name : Build Packages
23+ run : pnpm build
24+
25+ - name : Typecheck
26+ run : pnpm --filter website build
27+
28+ - name : Algolia push
29+ run : pnpm --filter website algolia-sync
30+ env :
31+ ALGOLIA_APP_ID : ${{ secrets.ALGOLIA_APP_ID }}
32+ ALGOLIA_ADMIN_API_KEY : ${{ secrets.ALGOLIA_ADMIN_API_KEY }}
33+ ALGOLIA_INDEX_NAME : ${{ secrets.ALGOLIA_INDEX_NAME }}
34+ SITE_URL : https://www.the-guild.dev/graphql/inspector/
35+
36+ - name : Format
37+ run : pnpm prettier
38+
39+ - name : Compare
40+ run : git diff website/algolia-lockfile.json
41+
42+ - name : Diff to file
43+ if : always()
44+ id : diff_result
45+ run : |
46+ OUTPUT=$(git diff website/algolia-lockfile.json)
47+ OUTPUT="${OUTPUT//'%'/'%25'}"
48+ OUTPUT="${OUTPUT//$'\n'/'%0A'}"
49+ OUTPUT="${OUTPUT//$'\r'/'%0D'}"
50+ echo "::set-output name=result::$OUTPUT"
51+
52+ - name : Commit algolia-lockfile.json
53+ if : always() && contains(steps.diff_result.outputs.result, 'diff')
54+ uses : EndBug/add-and-commit@v9
55+ with :
56+ commit : website/algolia-lockfile.json
57+ message : Update algolia-lockfile.json
58+ default_author : github_actions
Original file line number Diff line number Diff line change 66 - master
77
88jobs :
9- algolia :
10- uses : the-guild-org/shared-config/.github/workflows/algolia-integrity.yml@main
11- secrets :
12- githubToken : ${{ secrets.GUILD_BOT_TOKEN }}
13- with :
14- domain : https://www.the-guild.dev/graphql/inspector/
15- source : ' Inspector'
169 release :
1710 uses : the-guild-org/shared-config/.github/workflows/release-snapshot.yml@main
1811 with :
Original file line number Diff line number Diff line change @@ -13,3 +13,4 @@ website/algolia-lockfile.json
1313.bob /
1414.changeset /* .md
1515pnpm-lock.yaml
16+ website /algolia-lockfile.json
You can’t perform that action at this time.
0 commit comments