Linting, unit tests, CI pipeline, sidebar usePathname refactor#3
Draft
Copilot wants to merge 3 commits into
Draft
Linting, unit tests, CI pipeline, sidebar usePathname refactor#3Copilot wants to merge 3 commits into
Copilot wants to merge 3 commits into
Conversation
✅ Deploy Preview for personalcommandcenter ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
…dule pages Co-authored-by: saifsoub <35741624+saifsoub@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Migrate to a real database and restructure the repository
Migrate to Prisma + SQLite/Postgres, restructure into standard Next.js layout, add all module pages and API routes
Mar 14, 2026
…mic pages Co-authored-by: saifsoub <35741624+saifsoub@users.noreply.github.com>
Copilot
AI
changed the title
Migrate to Prisma + SQLite/Postgres, restructure into standard Next.js layout, add all module pages and API routes
Linting, unit tests, CI pipeline, sidebar usePathname refactor
Mar 14, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The repo had no linting, no tests, no CI, and a fragile sidebar that required every page to manually pass its own route as a prop.
Sidebar / AppShell
Sidebarconverted to"use client", usesusePathname()for active-link detectionpathnameprop removed fromAppShelland all 9 pagesESLint
eslint.config.mjsusingeslint-config-nextflat config;npm run lintscript addedpostcss.config.mjsanonymous-default-export warningUnit tests (Vitest)
__tests__/scoring.test.ts— 16 tests coveringclamp,computeOpportunityScore,computeEmpireScore(boundary values, weight ordering, integer output)__tests__/validators.test.ts— 29 tests covering all 5 Zod schemas (required fields, string→number coercion, defaults, rejection cases)GitHub Actions CI
Single job, runs in order:
typecheck → lint → test → db:push+seed → build. Uses SQLite; no external DB needed.Build fix
Added
export const dynamic = "force-dynamic"to all 8 DB-reading pages so Next.js doesn't attempt static pre-rendering at build time without a database present. Pages are now correctly emitted asƒ (Dynamic)in the build manifest.Cleanup
Removed stray
demo-db.jsonfrom repo root (canonical copy is atdata/demo-db.json).Warning
Firewall rules blocked me from connecting to one or more addresses (expand for details)
I tried to connect to the following addresses, but was blocked by firewall rules:
checkpoint.prisma.io/opt/hostedtoolcache/node/24.14.0/x64/bin/node /opt/hostedtoolcache/node/24.14.0/x64/bin/node /home/REDACTED/work/AgentEmpire/AgentEmpire/node_modules/prisma/build/child {"product":"prisma","version":"7.5.0","cli_install_type":"local","information":"","local_timestamp":"2026-03-14T06:44:14Z","project_hash":"4825cfe7","cli_path":"/home/REDACTED/work/AgentEmpire/AgentEmpire/node_modules/.bin/prisma","cli_path_hash":"bfdfd4ef"(dns block)If you need me to access, download, or install something from one of these locations, you can either:
💬 Send tasks to Copilot coding agent from Slack and Teams to turn conversations into code. Copilot posts an update in your thread when it's finished.