fix(git-diff): refresh diff data on screen mount and ignore agents.json

- Always request fresh git diff when screen opens (no caching)
- Add packages/server/agents.json to .gitignore (runtime data)
- Remove agents.json from git tracking

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Mohamed Boudra
2025-10-26 22:36:24 +01:00
co-authored by Claude
parent c5446e808d
commit 54c19f89bf
3 changed files with 6 additions and 462 deletions
+3 -6
View File
@@ -64,11 +64,8 @@ export default function GitDiffScreen() {
return;
}
if (diffText !== undefined) {
setIsLoading(false);
return;
}
// Always request fresh diff when screen mounts
setIsLoading(true);
requestGitDiff(agentId);
const timeout = setTimeout(() => {
@@ -76,7 +73,7 @@ export default function GitDiffScreen() {
}, 5000);
return () => clearTimeout(timeout);
}, [agentId, diffText, requestGitDiff]);
}, [agentId, requestGitDiff]);
useEffect(() => {
if (diffText !== undefined) {