From 85ac4be020f78bee721f9c1252ae269daa9d673d Mon Sep 17 00:00:00 2001 From: Dalton Alexandre <166029845+dl-alexandre@users.noreply.github.com> Date: Thu, 27 Nov 2025 14:55:04 -0800 Subject: [PATCH] fix: formatting issues --- packages/opencode/src/session/summary.ts | 2 +- packages/opencode/src/snapshot/index.ts | 29 ++++++++++++++++-------- packages/plugin/package.json | 2 +- packages/sdk/js/package.json | 2 +- 4 files changed, 22 insertions(+), 13 deletions(-) diff --git a/packages/opencode/src/session/summary.ts b/packages/opencode/src/session/summary.ts index 3bbb8b82d..d9247f182 100644 --- a/packages/opencode/src/session/summary.ts +++ b/packages/opencode/src/session/summary.ts @@ -149,7 +149,7 @@ export namespace SessionSummary { }, ], headers: small.info.headers, - }).catch(() => { }) + }).catch(() => {}) if (result) summary = result.text } userMsg.summary.body = summary diff --git a/packages/opencode/src/snapshot/index.ts b/packages/opencode/src/snapshot/index.ts index 12773dd4e..525a5c648 100644 --- a/packages/opencode/src/snapshot/index.ts +++ b/packages/opencode/src/snapshot/index.ts @@ -30,7 +30,10 @@ export namespace Snapshot { } const realDir = await fs.realpath(Instance.directory) const relative = path.relative(Instance.worktree, realDir) || "." - await $`git --git-dir ${git} --work-tree ${Instance.worktree} add ${relative}`.quiet().cwd(Instance.worktree).nothrow() + await $`git --git-dir ${git} --work-tree ${Instance.worktree} add ${relative}` + .quiet() + .cwd(Instance.worktree) + .nothrow() const hash = await $`git --git-dir ${git} --work-tree ${Instance.worktree} write-tree` .quiet() .cwd(Instance.worktree) @@ -50,7 +53,10 @@ export namespace Snapshot { const git = gitdir() const realDir = await fs.realpath(Instance.directory) const relative = path.relative(Instance.worktree, realDir) || "." - await $`git --git-dir ${git} --work-tree ${Instance.worktree} add ${relative}`.quiet().cwd(Instance.worktree).nothrow() + await $`git --git-dir ${git} --work-tree ${Instance.worktree} add ${relative}` + .quiet() + .cwd(Instance.worktree) + .nothrow() const result = await $`git -c core.autocrlf=false --git-dir ${git} --work-tree ${Instance.worktree} diff --no-ext-diff --name-only ${hash} -- ${relative}` .quiet() @@ -118,7 +124,7 @@ export namespace Snapshot { }) } else { log.info("file did not exist in snapshot, deleting", { file }) - await fs.unlink(file).catch(() => { }) + await fs.unlink(file).catch(() => {}) } } files.add(file) @@ -130,7 +136,10 @@ export namespace Snapshot { const git = gitdir() const realDir = await fs.realpath(Instance.directory) const relative = path.relative(Instance.worktree, realDir) || "." - await $`git --git-dir ${git} --work-tree ${Instance.worktree} add ${relative}`.quiet().cwd(Instance.worktree).nothrow() + await $`git --git-dir ${git} --work-tree ${Instance.worktree} add ${relative}` + .quiet() + .cwd(Instance.worktree) + .nothrow() const result = await $`git -c core.autocrlf=false --git-dir ${git} --work-tree ${Instance.worktree} diff --no-ext-diff ${hash} -- ${relative}` .quiet() @@ -178,15 +187,15 @@ export namespace Snapshot { const before = isBinaryFile ? "" : await $`git -c core.autocrlf=false --git-dir ${git} --work-tree ${Instance.worktree} show ${from}:${file}` - .quiet() - .nothrow() - .text() + .quiet() + .nothrow() + .text() const after = isBinaryFile ? "" : await $`git -c core.autocrlf=false --git-dir ${git} --work-tree ${Instance.worktree} show ${to}:${file}` - .quiet() - .nothrow() - .text() + .quiet() + .nothrow() + .text() result.push({ file, before, diff --git a/packages/plugin/package.json b/packages/plugin/package.json index d4875c3a3..5cf3c465b 100644 --- a/packages/plugin/package.json +++ b/packages/plugin/package.json @@ -24,4 +24,4 @@ "typescript": "catalog:", "@typescript/native-preview": "catalog:" } -} \ No newline at end of file +} diff --git a/packages/sdk/js/package.json b/packages/sdk/js/package.json index 1b9dc0fcf..a0c125c68 100644 --- a/packages/sdk/js/package.json +++ b/packages/sdk/js/package.json @@ -26,4 +26,4 @@ "publishConfig": { "directory": "dist" } -} \ No newline at end of file +}