Skip to content

Commit

Permalink
chore(CI): change way to set URLs of Lighthouse CI
Browse files Browse the repository at this point in the history
  • Loading branch information
macrat committed Jan 1, 2024
1 parent 70ec2f2 commit d4576e4
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 11 deletions.
11 changes: 1 addition & 10 deletions .github/lighthouse.json
Original file line number Diff line number Diff line change
@@ -1,16 +1,7 @@
{
"ci": {
"collect": {
"numberOfRuns": 1,
"staticDistDir": "./dist",
"url": [
"/",
"/blog",
"/blog/2020/05/blanktar-renewal",
"/blog/2023/08/golang-goldmark-custom-renderer",
"/works",
"/photos"
]
"staticDistDir": "./dist"
},
"assert": {
"preset": "lighthouse:no-pwa",
Expand Down
12 changes: 11 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,10 +54,18 @@ jobs:
uses: actions/download-artifact@v4
with:
name: dist
path: dist/

- uses: treosh/lighthouse-ci-action@v10
with:
configPath: '.github/lighthouse.json'
configPath: .github/lighthouse.json
urls: |
/index.html
/blog/index.html
/blog/2020/05/blanktar-renewal/index.html
/blog/2023/08/golang-goldmark-custom-renderer/index.html
/works/index.html
/photos/index.html
uploadArtifacts: true

preview:
Expand All @@ -78,6 +86,7 @@ jobs:
uses: actions/download-artifact@v4
with:
name: dist
path: dist/

- name: Pull Vercel environment information
run: vercel pull --yes --environment=preview --token=${{ secrets.VERCEL_TOKEN }}
Expand Down Expand Up @@ -105,6 +114,7 @@ jobs:
uses: actions/download-artifact@v4
with:
name: dist
path: dist/

- name: Pull Vercel environment information
run: vercel pull --yes --environment=production --token=${{ secrets.VERCEL_TOKEN }}
Expand Down

0 comments on commit d4576e4

Please sign in to comment.