forked from nicolasperez19/mic-master-flex
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
21 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -16,37 +16,55 @@ jobs: | |
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Install Bun | ||
uses: oven-sh/setup-bun@v1 | ||
|
||
- name: Install dependencies with Bun | ||
run: bun install | ||
|
||
- name: Build the site with Bun | ||
run: bun run build # Produces the `dist` folder | ||
|
||
- name: List build output | ||
run: ls -R dist # Verify if `dist` was created | ||
|
||
- name: Upload build output as artifact | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: dist-folder | ||
path: dist | ||
path: dist/** # Include all files in dist | ||
|
||
lighthouse: | ||
needs: build | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Download build output artifact | ||
uses: actions/download-artifact@v3 | ||
with: | ||
name: dist-folder | ||
path: . | ||
path: dist # Download into the 'dist' directory | ||
|
||
- name: List files in current directory | ||
run: ls -la | ||
|
||
- name: List files in dist directory | ||
run: ls -la dist | ||
|
||
- name: Show lighthouserc.json | ||
run: cat lighthouserc.json || echo "lighthouserc.json not found" | ||
|
||
- name: Install Bun | ||
uses: oven-sh/setup-bun@v1 | ||
|
||
- name: Install Lighthouse CI globally | ||
run: bun install -g @lhci/[email protected] | ||
|
||
- name: Run Lighthouse CI | ||
run: lhci autorun --collect.staticDistDir=./dist | ||
run: lhci autorun --collect.staticDistDir=dist # Remove './' for consistency | ||
|
||
deploy: | ||
needs: [build, lighthouse] | ||
|