Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
15 commits
Select commit Hold shift + click to select a range
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
106 changes: 106 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,106 @@
# =============================================================================
# VibeDev ID — Environment Variables (TanStack Start + Vite + Nitro)
# =============================================================================
#
# Copy this file to `.env.local` for local development:
# cp .env.example .env.local
#
# Vite loads `.env`, `.env.local`, and `.env.[mode]` automatically.
# Restart `bun run dev` after changing values.
#
# Public vs server-only:
# - `NEXT_PUBLIC_*` — read on server; also used by legacy helpers
# - `VITE_*` — exposed to browser (preferred for client-side Supabase)
# - no prefix — server-only (never sent to browser)
#
# For Supabase public keys, set BOTH `NEXT_PUBLIC_*` and matching `VITE_*`
# (same values) so SSR loaders and client components both work.
# =============================================================================

# -----------------------------------------------------------------------------
# Required — Supabase (database + auth)
# Get from: Supabase Dashboard → Project Settings → API
# -----------------------------------------------------------------------------

# Project URL (must start with https://)
NEXT_PUBLIC_SUPABASE_URL=https://your-project-ref.supabase.co
VITE_SUPABASE_URL=https://your-project-ref.supabase.co

# anon / public key (safe for browser with RLS enabled)
NEXT_PUBLIC_SUPABASE_ANON_KEY=your_supabase_anon_key
VITE_SUPABASE_ANON_KEY=your_supabase_anon_key

# service role key — SERVER ONLY, bypasses RLS (admin actions, migrations)
# Never expose to client or commit real values to git
SUPABASE_SERVICE_ROLE_KEY=your_supabase_service_role_key

# -----------------------------------------------------------------------------
# Required — Site URL (SEO, auth redirects, OAuth callbacks)
# -----------------------------------------------------------------------------

# Canonical public URL of this deployment
NEXT_PUBLIC_SITE_URL=http://localhost:3000

# Optional alias (used by getSiteUrl() fallback chain)
# SITE_URL=http://localhost:3000

# Where Supabase should redirect after email signup / password reset in dev
# Must be listed in Supabase → Authentication → URL Configuration → Redirect URLs
NEXT_PUBLIC_DEV_SUPABASE_REDIRECT_URL=http://localhost:3000

# Supabase auth callback (add this URL in Supabase redirect allowlist too):
# http://localhost:3000/auth/callback

# -----------------------------------------------------------------------------
# File uploads — UploadThing
# Get from: https://uploadthing.com/dashboard
# Required for project/blog image uploads; app returns 503 without it
# -----------------------------------------------------------------------------

UPLOADTHING_TOKEN=your_uploadthing_token

# Optional legacy UploadThing app ID (if your dashboard still shows it)
# UPLOADTHING_APP_ID=your_uploadthing_app_id

# -----------------------------------------------------------------------------
# AI features — OpenRouter
# Used by /api/ai/completion and /api/ai/enhance-description (blog editor)
# Get from: https://openrouter.ai/keys
# -----------------------------------------------------------------------------

OPENROUTER_API_KEY=sk-or-v1-your_openrouter_api_key

# -----------------------------------------------------------------------------
# Optional — GitHub import
# Used by /api/github-import for higher rate limits when importing repos
# Create at: GitHub → Settings → Developer settings → Personal access tokens
# -----------------------------------------------------------------------------

# GITHUB_TOKEN=ghp_your_github_personal_access_token
# GH_TOKEN=ghp_your_github_personal_access_token

# -----------------------------------------------------------------------------
# Optional — Vercel Analytics / Speed Insights
# Set on Vercel automatically; only needed if you want insights locally
# -----------------------------------------------------------------------------

# VITE_VERCEL=1
# VERCEL=1

# -----------------------------------------------------------------------------
# Optional — Production / hosting (usually auto-set by platform)
# Do not set manually unless you know what you're doing
# -----------------------------------------------------------------------------

# VERCEL_URL=your-app.vercel.app
# VERCEL_PROJECT_PRODUCTION_URL=https://www.vibedevid.com

# Nitro production server (default: 3000)
# PORT=3000
# HOST=0.0.0.0

# -----------------------------------------------------------------------------
# CI / testing (set by CI runner, not needed locally)
# -----------------------------------------------------------------------------

# CI=true
6 changes: 6 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@

# production
/build
.output/
.tanstack/

# debug
npm-debug.log*
Expand All @@ -18,6 +20,7 @@ yarn-error.log*

# env files
.env*
!.env.example

# vercel
.vercel
Expand All @@ -29,3 +32,6 @@ next-env.d.ts
nul
# next-agents-md
.next-docs/

# Editor settings
.zed/
1 change: 1 addition & 0 deletions .vite-hooks/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
vp staged
Loading
Loading