Skip to content

Self-hosted, Self-Improving, Federated Everything App — dev management, agent orchestration, persistent mind, digital twin, second brain, and creative pipeline from a single dashboard over Tailscale to port the user into the OS

fix(git): use trimEnd to preserve porcelain status leading spaces

Adam Eivyf5647f932417
diff --git a/server/services/git.js b/server/services/git.js
index 4d434a06d9..7608abaa9a 100644
--- a/server/services/git.js
+++ b/server/services/git.js
@@ -64,7 +64,8 @@ function execGit(args, cwd, options = {}) {
*/
export async function getStatus(dir) {
const result = await execGit(['status', '--porcelain'], dir);
- const lines = result.stdout.trim().split('\n').filter(Boolean);
+ // trimEnd (not trim): porcelain status codes use leading spaces (e.g. ' M' = unstaged)
+ const lines = result.stdout.trimEnd().split('\n').filter(Boolean);
const files = lines.map(line => {
const status = line.substring(0, 2);