Skip to content

Commit 7116241

Browse files
committed
Write pr-diff-range JSON file
1 parent affec20 commit 7116241

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/analyze.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -537,6 +537,14 @@ extensions:
537537
`Wrote pr-diff-range extension pack to ${extensionFilePath}:\n${extensionContents}`,
538538
);
539539

540+
// Compute JSON file contents once
541+
const jsonContents = JSON.stringify(ranges, null, 2);
542+
const jsonFilePath = path.join(diffRangeDir, "pr-diff-range.json");
543+
fs.writeFileSync(jsonFilePath, jsonContents);
544+
logger.debug(
545+
`Wrote pr-diff-range JSON file to ${jsonFilePath}:\n${jsonContents}`,
546+
);
547+
540548
return diffRangeDir;
541549
}
542550

0 commit comments

Comments
 (0)