Skip to content

feat: deploy website to GitHub Pages on release#68

Merged
MathurAditya724 merged 3 commits intomainfrom
deploy-website-on-release
Mar 27, 2026
Merged

feat: deploy website to GitHub Pages on release#68
MathurAditya724 merged 3 commits intomainfrom
deploy-website-on-release

Conversation

@MathurAditya724
Copy link
Copy Markdown
Member

Summary

Adds automatic deployment of the website dashboard to GitHub Pages whenever a release is published via Craft.

Changes

  • .github/workflows/build.yml: Add a build_website job that builds the Vite app in website/, zips the output as gh-pages.zip, and uploads it as a gh-pages artifact (matching the convention used by getsentry/cli)
  • .craft.yml: Register the gh-pages artifact from the Build & Test workflow and add the gh-pages Craft target so it gets deployed on craft publish
  • website/vite.config.ts: Set base: "/codecov-action/" so asset paths work correctly when served from https://getsentry.github.io/codecov-action/
  • website/src/App.tsx: Add basename={import.meta.env.BASE_URL} to BrowserRouter so client-side routing respects the subpath
  • website/src/pages/HomePage.tsx: Replace Github icon with GitBranch — the Github brand icon was removed in lucide-react 1.x (broken by chore(deps): bump lucide-react from 0.555.0 to 1.6.0 #60)

Setup required after merge

After the first release deploys to the gh-pages branch, enable GitHub Pages in repo Settings > Pages:

  • Source: Deploy from a branch
  • Branch: gh-pages / / (root)

References

Add gh-pages target to craft configuration so the website dashboard
is automatically deployed to GitHub Pages when a release is published.

Changes:
- Add build_website job to CI workflow that builds the Vite app and
  uploads a gh-pages.zip artifact
- Register the gh-pages artifact and target in .craft.yml
- Set Vite base path to /codecov-action/ for correct asset URLs
- Add basename to BrowserRouter for subpath routing
- Fix broken Github icon import (removed in lucide-react 1.x)
Comment thread .github/workflows/build.yml Fixed
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Mar 27, 2026

Codecov Results 📊

194 passed | Total: 194 | Pass Rate: 100% | Execution Time: 287ms

📊 Comparison with Base Branch

Metric Change
Total Tests
Passed Tests
Failed Tests
Skipped Tests

✨ No test changes detected

All tests are passing successfully.

✅ Patch coverage is 100.00%. Project has 759 uncovered lines.
✅ Project coverage is 56.82%. Comparing base (base) to head (head).

Coverage diff
@@            Coverage Diff             @@
##          main       #PR       +/-##
==========================================
+ Coverage    56.82%    56.82%        —%
==========================================
  Files           24        24         —
  Lines         1753      1753         —
  Branches      1257      1257         —
==========================================
+ Hits           994       994         —
- Misses         759       759         —
- Partials        97        97         —

Generated by Codecov Action

@MathurAditya724 MathurAditya724 marked this pull request as ready for review March 27, 2026 08:25
Restrict GITHUB_TOKEN to contents:read only, as flagged by
github-advanced-security.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants