Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 28 additions & 0 deletions .copy-verify-sizes.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
import { readFileSync, statSync } from 'node:fs';

const files = [
'src/discord/discordHandlers.ts',
'src/discord/discordPair.ts',
'src/runners/cliRunner.ts',
];

const srcRoot = '/work/OpenSwarm/src';
const dstRoot = '/work/OpenSwarm/worktree/c1f52155-1371-412d-973f-9a7855febc82/src';

for (const rel of files) {
const src = `${srcRoot}/${rel.replace(/^src\//, '')}`;
const dst = `${dstRoot}/${rel.replace(/^src\//, '')}`;
const sb = readFileSync(src);
const db = readFileSync(dst);
const same = sb.equals(db);
console.log(JSON.stringify({
file: rel,
srcBytes: sb.length,
dstBytes: db.length,
srcLines: sb.toString('utf8').split(/\n/).length - (sb[sb.length - 1] === 10 ? 1 : 0) || sb.toString('utf8').split('\n').length,
// wc -l counts newline chars
srcNewlines: sb.filter((b) => b === 0x0a).length,
dstNewlines: db.filter((b) => b === 0x0a).length,
identical: same,
}));
}
100 changes: 100 additions & 0 deletions .line-lens-cliRunner.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,100 @@
44
25
53
44
0
64
35
0
78
69
67
115
46
48
84
47
62
60
0
8
0
33
15
24
16
21
22
26
19
94
17
1
0
10
0
81
0
76
54
70
1
0
68
33
67
105
20
3
22
1
0
45
44
29
29
48
41
36
46
1
0
16
0
60
52
18
0
41
37
45
53
69
22
35
62
58
6
20
3
0
28
74
48
8
37
24
48
18
42
61
62
6
20
3
39
71
20
3
8
58
1 change: 1 addition & 0 deletions .size-calc-cliRunner.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
PLACEHOLDER
Loading