Skip to content

feat(dashboard): move repo/base-branch/branch-prefix fields to Integrations > Source Control#840

Merged
aaight merged 1 commit intodevfrom
feature/move-scm-fields-to-integrations-tab
Mar 14, 2026
Merged

feat(dashboard): move repo/base-branch/branch-prefix fields to Integrations > Source Control#840
aaight merged 1 commit intodevfrom
feature/move-scm-fields-to-integrations-tab

Conversation

@aaight
Copy link
Copy Markdown
Collaborator

@aaight aaight commented Mar 14, 2026

Summary

Moves the Repository, Base Branch, and Branch Prefix fields from the General tab to the Integrations > Source Control tab in project configuration. This is a UI-only change — storage and backend contract are unchanged.

  • Removes repo, baseBranch, and branchPrefix inputs from ProjectGeneralForm (General tab)
  • Adds a Repository Settings section at the top of the Source Control tab (SCMTab) with the three fields
  • The Source Control save flow now calls projects.update for the project-level fields in addition to the integration upsert and credential mutations
  • Invalidates project queries on successful save so the UI stays in sync
  • IntegrationForm fetches the project via trpc.projects.getById and passes it to SCMTab for prefilling

Test plan

  • Verify repo, baseBranch, branchPrefix fields are gone from the General tab
  • Verify the three fields appear at the top of Integrations > Source Control, prefilled with current values
  • Save from the Source Control tab and confirm values persist after page reload
  • Confirm GitHub credentials and webhook management still work on the Source Control tab
  • Run unit tests: npm test — all pre-existing tests pass
  • Run npm run typecheck and npm run lint — both pass clean

Related

Trello card: https://trello.com/c/69b5c9435bce8324cf97b3fd

🤖 Generated with Claude Code

🕵️ claude-code · claude-sonnet-4-6 · run details

Copy link
Copy Markdown
Collaborator

@nhopeatall nhopeatall left a comment

Choose a reason for hiding this comment

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

Summary

Clean UI-only refactor that moves repository settings to their logical home under Integrations > Source Control. The implementation is correct and all CI checks pass.

Should Fix (non-blocking)

  • web/src/components/projects/integration-form.tsx:437 — The saveMutation calls trpcClient.projects.update.mutate directly instead of reusing the existing useProjectUpdate hook (defined in use-project-update.ts, already used by ProjectGeneralForm and ProjectHarnessForm). This duplicates the mutation call and cache invalidation logic. It's understandable since the SCM save combines multiple operations (project update + integration upsert + credential set), but worth noting — if cache invalidation logic changes in useProjectUpdate, this spot will need a manual update too. Consider reusing the hook's mutateAsync as the first step of the combined mutationFn to keep invalidation logic DRY.

  • web/src/components/projects/integration-form.tsx:636IntegrationForm creates a new useQuery(trpc.projects.getById.queryOptions({ id: projectId })) call, but the parent component ($projectId.tsx:25) already fetches the same query. TanStack Query deduplication means no extra network request, but this could be simplified by passing the project data as a prop from the parent page instead of re-querying. This would also avoid the brief moment where SCMTab renders with default values before projectQuery resolves.

Both are minor — the implementation is functionally correct and safe to merge.

🕵️ claude-code · claude-opus-4-6 · run details

@aaight aaight merged commit 58af171 into dev Mar 14, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants