spacehub

surshar / claude-code

Claude Code is an agentic coding tool that lives in your terminal, understands your codebase, and helps you code faster by executing routine tasks, explaining complex code, and handling git workflows - all through natural language commands.

Built by Anthropic · github.com/anthropics

mods: a blank line between const runs and let runsBrowse files
poteat authored on Sep 13, 2026 parent b593276 · commit 3668b47c37f0
8 changed files+11 -0compared with b593276
Mmods/diff/hooks/ask/fitted-ask-text-of.ts
Mmods/diff/hooks/git/parse/parse-numstat.ts
Mmods/diff/hooks/git/probes/kind-walk-of/kind-walk-of.ts
Mmods/diff/hooks/register.ts
Mmods/diff/hooks/views/detail/code-blocks-of/code-blocks-of.ts
Mmods/diff/hooks/views/detail/sub-hunks-of/sub-hunks-of.ts
Mmods/diff/hooks/views/layout/truncate-start/truncate-start.ts
Mmods/diff/hooks/views/layout/wrapped-lines/wrapped-lines.ts
@@ -17,6 +17,7 @@
1717 }
1818
1919 const kept: string[] = []
20+
2021 let used = ASK_CUT_NOTE.length
2122
2223 for (const line of text.split('\n')) {
@@ -20,6 +20,7 @@
2020 const files: Types.FileStat[] = []
2121 const stats = { filesCount: 0, linesAdded: 0, linesRemoved: 0 }
2222 const records = stdout.split('\0')
23+
2324 let at = 0
2425
2526 while (at < records.length) {
@@ -41,6 +41,7 @@
4141
4242 async function kindOf(path: string): Promise<Types.WalkKind> {
4343 const names = path === '' ? [] : path.split('/')
44+
4445 let directory = ''
4546
4647 for (const [depth, name] of names.entries()) {
@@ -43,8 +43,11 @@
4343 let isRefreshQueued = false
4444 let generation = 0
4545 let bodyKey: string | null = null
46+
4647 const polled = { toplevel: '', headKey: '' }
48+
4749 let model: PaneState.PaneModel = PaneState.INITIAL_MODEL
50+
4851 const timers = new Map<'refresh' | 'redraw' | 'poll', Timer>()
4952 const loggedBaseKinds = new Set<'ok' | 'sad'>()
5053
@@ -23,6 +23,7 @@
2323 */
2424 export function codeBlocksOf(hunks: readonly Git.Hunk[]): Types.CodeBody {
2525 const blocks: Types.CodeBlock[] = []
26+
2627 let chars = 0
2728 let nodes = 0
2829 let isTruncated = false
@@ -19,6 +19,7 @@
1919 maxChars: number,
2020 ): Pick<Git.FileHunks, 'hunks' | 'isTruncated'> {
2121 const hunks: Git.Hunk[] = []
22+
2223 let rest = hunk
2324 let isTruncated = false
2425
@@ -18,6 +18,7 @@
1818 }
1919
2020 const characters = [...text]
21+
2122 let kept = ''
2223
2324 for (let at = characters.length - 1; at >= 0; at--) {
@@ -18,6 +18,7 @@
1818
1919 for (const [index, word] of words.entries()) {
2020 const wordWidth = cellWidth(word)
21+
2122 let rowWidth = cellWidth(rows[rows.length - 1] ?? '')
2223
2324 if (index !== 0) {
@@ -39,6 +40,7 @@
3940 }
4041
4142 const characters = [...word]
43+
4244 let visible = cellWidth(rows[rows.length - 1] ?? '')
4345
4446 for (const [at, character] of characters.entries()) {