File tree Expand file tree Collapse file tree 1 file changed +27
-17
lines changed
Expand file tree Collapse file tree 1 file changed +27
-17
lines changed Original file line number Diff line number Diff line change @@ -3,50 +3,60 @@ name: documentation
33on : [push, pull_request]
44
55jobs :
6- checks :
6+ test :
77 runs-on : ubuntu-latest
88 steps :
99 - uses : actions/checkout@v3
1010 - uses : actions/setup-node@v3
1111 with :
1212 node-version : 22
1313 cache : yarn
14- - uses : actions/cache@v3
14+ - uses : actions/cache@v4
1515 id : yarn-cache
1616 with :
1717 path : ' node_modules'
1818 key : yarn-${{ hashFiles('yarn.lock') }}
1919 - run : yarn install --frozen-lockfile
2020 if : steps.yarn-cache.outputs.cache-hit != 'true'
21- - name : Test Build
22- run : |
23- yarn lint
24- yarn typecheck
25- yarn build
21+ - run : npm run lint
22+ - run : npm run typecheck
23+ - run : npm run build
2624
27- gh-release :
25+ build :
2826 if : github.ref_name == 'main'
27+ needs : test
2928 runs-on : ubuntu-latest
30- needs : checks
29+ permissions :
30+ contents : write
3131 steps :
3232 - uses : actions/checkout@v3
3333 - uses : actions/setup-node@v3
3434 with :
3535 node-version : 22
36- cache : yarn
37- - uses : actions/cache@v3
36+ - uses : actions/cache@v4
3837 id : yarn-cache
3938 with :
4039 path : ' node_modules'
4140 key : yarn-${{ hashFiles('yarn.lock') }}
4241 - run : yarn install --frozen-lockfile
4342 if : steps.yarn-cache.outputs.cache-hit != 'true'
44- - name : Build website
43+ - run : npm run build
4544 env :
4645 TRACKING_ID : ${{ secrets.TRACKING_ID }}
47- run : yarn build
48- - name : Deploy to GitHub Pages
49- uses : peaceiris/actions-gh-pages@v3
46+ - uses : actions/upload-pages-artifact@v3
5047 with :
51- github_token : ${{ secrets.GITHUB_TOKEN }}
52- publish_dir : ./build
48+ path : ./build
49+
50+ deploy :
51+ needs : build
52+ permissions :
53+ pages : write
54+ id-token : write
55+ environment :
56+ name : github-pages
57+ url : ${{ steps.deployment.outputs.page_url }}
58+ runs-on : ubuntu-latest
59+ steps :
60+ - name : Deploy to GitHub Pages
61+ id : deployment
62+ uses : actions/deploy-pages@v4
You can’t perform that action at this time.
0 commit comments