Skip to content

Commit c32a700

Browse files
authored
Merge pull request #169 from gHashTag/feat/issue-168
refactor(faculty): extract hardcoded paths to constants in faculty_board.zig
2 parents 7fd2a5e + bbecbc8 commit c32a700

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

src/tri/faculty_board.zig

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,8 @@ const Path = three_paths.Path;
2323
const PREV_PATH = ".trinity/faculty_prev.dat";
2424
const TG_HASH_PATH = ".trinity/faculty_tg_hash.dat";
2525
const AGENT_CMD_LOG = ".trinity/agent_commands.log";
26+
const REGEN_REPORT = "specs/REGENERATION_REPORT.md";
27+
const MU_LEARNING_DB = ".trinity/mu/learning_db.json";
2628

2729
// ═══════════════════════════════════════════════════════════════════════════════
2830
// DATA COLLECTION
@@ -496,7 +498,7 @@ fn countBinaries() u8 {
496498
const RegenStats = struct { pass: u16, total: u16 };
497499

498500
fn parseRegenReport(allocator: Allocator) RegenStats {
499-
const content = std.fs.cwd().readFileAlloc(allocator, "specs/REGENERATION_REPORT.md", 256 * 1024) catch
501+
const content = std.fs.cwd().readFileAlloc(allocator, REGEN_REPORT, 256 * 1024) catch
500502
return .{ .pass = 0, .total = 0 };
501503
defer allocator.free(content);
502504

@@ -551,7 +553,7 @@ fn countOpenIssues(allocator: Allocator) u16 {
551553
}
552554

553555
fn countMuPatterns(allocator: Allocator) u16 {
554-
const content = std.fs.cwd().readFileAlloc(allocator, ".trinity/mu/learning_db.json", 64 * 1024) catch
556+
const content = std.fs.cwd().readFileAlloc(allocator, MU_LEARNING_DB, 64 * 1024) catch
555557
return 0;
556558
defer allocator.free(content);
557559
// Count pattern entries

0 commit comments

Comments
 (0)