kellymears / kellymears/kellymears.me
task(data): move GitHub data import to Netlify build
- Dominant language
- TypeScript
- Stars
- 0
- Forks
- 0
- PR merge metrics
- No merged PRs in 30d
Description
Move `import:github` from local sync to Netlify build time, so GitHub data stays fresh without any local machine involvement. The local launchd sync agent has been removed (it failed nightly and spammed macOS Security settings with node runtime approvals).
## Context
`/open-source` reads committed `public/static/data/github.json` first and only falls back to live fetch (`app/open-source/page.tsx:112`), so a stale committed cache means a stale page. The GitHub import is pure API (`scripts/import-github.ts`) — unlike the rides import, it has no dependency on local iCloud files and can run anywhere.
Rides data stays manual: run `import:rides` + push after riding, which also triggers a deploy that refreshes GitHub data as a side effect.
## Acceptance Criteria
- [ ] Netlify build runs `import:github` before `next build` (e.g. `"build": "npm run import:github && next build"`)
- [ ] `GITHUB_TOKEN` set in Netlify environment variables
- [ ] `github.json` no longer committed to git (generated per-build; remove from repo, gitignore it)
- [ ] Build does not fail on GitHub API errors — fall back to non-strict mode or last-known data instead of `strict: true` killing the deploy
- [ ] Daily freshness: GitHub Actions workflow on `schedule:` cron hits a Netlify build hook URL
- [ ] `/api/cli` route still works (it reads `github.json` from disk at `app/api/cli/route.ts:17`)
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with scripts/import-github.ts, app/open-source/page.tsx:112, and app/api/cli/route.ts:17, then inspect the build command and GitHub Actions workflow. Verify the import runs before next build, generated github.json is available to both routes, API failures do not stop deployment, and the scheduled workflow triggers a daily Netlify build.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- github-actions, nextjs, typescript
- Domain
- build-system, ci-cd, devops
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 58/100