Skip to content
Merged
Show file tree
Hide file tree
Changes from 21 commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
49802c0
feat(web): add Hero section with Terminal Chic theme and typewriter a…
Mar 3, 2026
5eb1b5c
feat(web): add landing page sections - FeatureGrid, Pricing, Stats, F…
Mar 3, 2026
db6d10a
fix(web): memory leaks in useTypewriter and AnimatedCounter hooks
BillChirico Mar 4, 2026
405d585
fix(web): add missing semantic CSS tokens for landing components
BillChirico Mar 4, 2026
8c01343
fix(web): wire up CTA buttons to bot invite URL
BillChirico Mar 4, 2026
5a493ef
fix(web): update stale landing page tests
BillChirico Mar 4, 2026
4ec14de
fix(web): resolve remaining lint issues
BillChirico Mar 4, 2026
e7e07c0
fix(web): add testimonial IDs type and update lockfile
BillChirico Mar 4, 2026
978d89d
fix(landing): handle null bot invite URL in footer CTA
BillChirico Mar 4, 2026
bca628f
fix(web): use Inter font as default sans-serif
BillChirico Mar 4, 2026
6191554
fix(landing): use GitHub link for free tier, handle null bot invite
BillChirico Mar 4, 2026
4bfe414
test: fix framer-motion mock to support refs
BillChirico Mar 4, 2026
152534c
fix(landing): remove non-null assertions for bot invite URL
BillChirico Mar 4, 2026
73b6bf0
fix: add useReducedMotion support for accessibility
BillChirico Mar 4, 2026
79e2ad7
fix: remove duplicate --font-mono from globals.css
BillChirico Mar 4, 2026
5c9eef3
fix: initialize startTime to null for TypeScript strict mode
BillChirico Mar 4, 2026
30f29d8
fix(a11y): change hero headline to semantic h1
BillChirico Mar 4, 2026
f6f2cae
fix(landing): use fictional company names in testimonials
BillChirico Mar 4, 2026
f19eb3c
fix(test): improve Framer Motion mock for ESM compatibility
BillChirico Mar 4, 2026
66120bd
fix(test): use async import in framer-motion mock for ESM compatibility
Mar 4, 2026
e83b855
ci: add Railway preview deployment for PRs
Mar 4, 2026
23a7acf
fix(ci): add closed trigger and NEXT_PUBLIC_DISCORD_CLIENT_ID for pre…
BillChirico Mar 4, 2026
08bcb3b
style: fix linter warnings in landing components
BillChirico Mar 4, 2026
44ad7b2
fix(ci): pin pnpm/action-setup to commit SHA for supply-chain security
BillChirico Mar 4, 2026
5cb6ebc
chore: update project configuration and improve layout styling
BillChirico Mar 4, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
148 changes: 148 additions & 0 deletions .github/workflows/railway-preview.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,148 @@
name: Railway Preview Deploy

on:
pull_request:
types: [opened, synchronize, reopened]
branches: [main]

concurrency:
group: railway-preview-${{ github.ref }}
cancel-in-progress: true

permissions:
contents: read
pull-requests: write

jobs:
deploy-preview:
name: Deploy to Railway Preview
runs-on: ubuntu-latest
if: github.event.pull_request.head.repo.full_name == github.repository
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

deploy job runs unnecessarily when PR closes

when action is closed, both deploy-preview and cleanup-preview jobs run simultaneously, wasting CI resources. add condition to skip:

Suggested change
if: github.event.pull_request.head.repo.full_name == github.repository
if: github.event.action != 'closed' && github.event.pull_request.head.repo.full_name == github.repository
Prompt To Fix With AI
This is a comment left during a code review.
Path: .github/workflows/railway-preview.yml
Line: 20

Comment:
deploy job runs unnecessarily when PR closes

when action is `closed`, both deploy-preview and cleanup-preview jobs run simultaneously, wasting CI resources. add condition to skip:

```suggestion
    if: github.event.action != 'closed' && github.event.pull_request.head.repo.full_name == github.repository
```

How can I resolve this? If you propose a fix, please make it concise.


steps:
- name: Checkout
uses: actions/[email protected]

- name: Setup pnpm
uses: pnpm/[email protected]

- name: Setup Node.js
uses: actions/[email protected]
with:
node-version: 22
cache: pnpm

- name: Install dependencies
run: pnpm install --frozen-lockfile

- name: Build web dashboard
run: cd web && pnpm build
env:
NEXT_PUBLIC_BOT_API_URL: ${{ secrets.NEXT_PUBLIC_BOT_API_URL }}
NEXTAUTH_URL: ${{ secrets.NEXTAUTH_URL_PREVIEW || 'https://preview.volvox.dev' }}
NEXTAUTH_SECRET: ${{ secrets.NEXTAUTH_SECRET }}
DISCORD_CLIENT_ID: ${{ secrets.DISCORD_CLIENT_ID }}
DISCORD_CLIENT_SECRET: ${{ secrets.DISCORD_CLIENT_SECRET }}

- name: Install Railway CLI
run: npm install -g @railway/cli

- name: Deploy to Railway Preview
id: railway-deploy
run: |
# Generate a unique preview environment name based on PR number
PREVIEW_ENV="pr-${{ github.event.number }}"
echo "Deploying to preview environment: $PREVIEW_ENV"

# Deploy using Railway CLI
railway up --service=volvox-bot --environment=$PREVIEW_ENV --detach

# Get the deployment URL
DEPLOY_URL=$(railway domain --service=volvox-bot --environment=$PREVIEW_ENV)
echo "deploy_url=$DEPLOY_URL" >> $GITHUB_OUTPUT
env:
RAILWAY_TOKEN: ${{ secrets.RAILWAY_TOKEN }}

- name: Comment PR with preview URL
uses: actions/[email protected]
with:
script: |
const deployUrl = '${{ steps.railway-deploy.outputs.deploy_url }}';
const prNumber = context.issue.number;

// Find existing comment
const { data: comments } = await github.rest.issues.listComments({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: prNumber,
});

const botComment = comments.find(comment =>
comment.user.type === 'Bot' &&
comment.body.includes('🚀 Railway Preview Deployment')
);

const body = `## 🚀 Railway Preview Deployment

Your PR has been deployed to a preview environment!

**Preview URL:** ${deployUrl}

**Environment:** \`pr-${prNumber}\`

This deployment will be updated automatically when you push new commits.

---
*Last updated: ${new Date().toISOString()}*`;

if (botComment) {
// Update existing comment
await github.rest.issues.updateComment({
owner: context.repo.owner,
repo: context.repo.repo,
comment_id: botComment.id,
body: body,
});
} else {
// Create new comment
await github.rest.issues.createComment({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: prNumber,
body: body,
});
}

cleanup-preview:
name: Cleanup Railway Preview
runs-on: ubuntu-latest
if: github.event.action == 'closed'

steps:
- name: Install Railway CLI
run: npm install -g @railway/cli

- name: Remove Preview Environment
run: |
PREVIEW_ENV="pr-${{ github.event.number }}"
echo "Removing preview environment: $PREVIEW_ENV"
railway environment delete $PREVIEW_ENV --yes || true
env:
RAILWAY_TOKEN: ${{ secrets.RAILWAY_TOKEN }}

- name: Comment PR about cleanup
uses: actions/[email protected]
with:
script: |
const prNumber = context.issue.number;

await github.rest.issues.createComment({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: prNumber,
body: `## 🧹 Preview Environment Cleaned Up

The Railway preview environment for this PR has been removed.

**Environment:** \`pr-${prNumber}\``,
});
38 changes: 38 additions & 0 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions web/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
"clsx": "^2.1.1",
"cmdk": "^1.1.1",
"diff": "^8.0.3",
"framer-motion": "^12.34.5",
"lucide-react": "^0.525.0",
"next": "^16.1.6",
"next-auth": "^4.24.13",
Expand Down
Loading
Loading