A polished, static GitHub profile site you can fork and make your own in minutes. Add your own blogs, videos, projects, and posts through the in-browser admin panel — no local setup required.
- Built with: Vite + React + TypeScript
- Data: stored in
data/*.jsonfiles on yourwebbranch, edited via/admin - Deployed: GitHub Pages, triggered automatically on every change
- License: MIT (see
LICENSE)
This repo uses two branches so forking gives you a clean template with no personal data baked in:
| Branch | Purpose |
|---|---|
main |
Clean template — empty data files, safe to fork |
web |
Your personal branch — holds your data, gets deployed |
All admin panel writes go to web. The deploy workflow triggers on web. main never contains personal data.
Fork to your GitHub account. Optionally rename the fork to yourusername.github.io for a root URL:
Settings → General → Repository name
You’ll get a live site at:
https://yourusername.github.io/(if repo is namedyourusername.github.io)https://yourusername.github.io/gitfolio/(if repo is namedgitfolio)
Go to Actions → Setup web branch (first-time) → Run workflow.
This creates a web branch from your main. GitHub Pages will deploy from web going forward.
In your fork: Settings → Pages → Source → Deploy from a branch → web / / (root).
If you see a
github-pagesenvironment already deploying, it may have already been configured by the workflow — check before changing.
The /admin route lets you edit your site’s content from the browser. It needs a GitHub OAuth App to authenticate you.
- Go to github.com/settings/developers → New OAuth App
- Set:
- Homepage URL: your site URL (e.g.
https://yourusername.github.io/gitfolio) - Authorization callback URL: same as Homepage
- Homepage URL: your site URL (e.g.
- Click Register application and copy the Client ID
Repo → Settings → Secrets and variables → Actions → New repository secret
- Name:
VITE_GITHUB_CLIENT_ID - Value: your OAuth App Client ID
GitHub blocks OAuth token exchange from the browser. You need a small proxy. The easiest option is the included Cloudflare Worker:
cd workers/github-oauth-proxy
npx wrangler deployThen add a repository variable (not secret):
- Name:
VITE_GITHUB_OAUTH_PROXY_URL - Value:
https://YOUR-WORKER.workers.dev(no trailing slash)
- Visit
https://yourusername.github.io/gitfolio/admin - Click Login with GitHub and complete the device flow
- Edit your config, add blogs, videos, projects, posts
- Save → the admin panel commits directly to your
webbranch → GitHub Actions rebuilds → your site updates
You push code to main
↓
sync-to-web.yml runs automatically
↓
merges main → web (your data files are always preserved)
↓
deploy.yml triggers on web → site rebuilds
You save data via /admin
↓
admin panel commits directly to web branch
↓
deploy.yml triggers on web → site rebuilds
You never need to touch the web branch manually.
git clone https://github.com/amide-init/gitfolio.git
cd gitfolio
pnpm install
pnpm devTo build and preview a production bundle:
pnpm build
pnpm previewTo run the admin panel locally:
cp .env.example .envEdit .env:
VITE_GITHUB_CLIENT_ID=your_oauth_app_client_id_here
VITE_GITHUB_OWNER=your-github-username-or-org
VITE_GITHUB_REPO=gitfolio
VITE_DATA_BRANCH=web # branch where data is read/writtenpnpm dev- Main site:
http://localhost:5173/ - Admin panel:
http://localhost:5173/admin
Click Login with GitHub, complete the device flow in the new tab, then edit and save. Only users with admin permission on the repo can save; others see “Unauthorized”.
In dev, OAuth requests are proxied through Vite (
/api/github/login/*) to avoid CORS — no worker needed locally.
Key files:
src/api/github.ts— GitHub API client; all reads/writes target thewebbranchsrc/App.tsx— main React appdata/— content files (blogs.json,posts.json,projects.json,videos.json); empty onmain, populated onwebgitforge.config.json— site config; read/written by the admin panel.github/workflows/deploy.yml— builds and deploys from thewebbranch.github/workflows/sync-to-web.yml— syncs code changes frommain→web.github/workflows/setup-web.yml— one-time setup to create thewebbranch
- Additional themes (minimal, dev-focused)
- Multi-profile / team pages
Open an issue or PR for feature requests.