@@ -2,6 +2,14 @@ const Octokit = require('@octokit/rest');
22const fs = require ( 'fs' ) ;
33let { parseArgs} = require ( 'util' ) ;
44
5+ /**
6+ * Instructions:
7+ *
8+ * 1. Update Octokit to use your token
9+ * 2. Run the following script: node scripts/getCommitsForTesting.js 2025-10-07 2025-10-18
10+ * 3. Go to output.csv, copy it to Google sheets, highlight the rows, go to "Data" in the toolbar -> split text to columns -> separator: comma
11+ */
12+
513const octokit = new Octokit ( ) ;
614
715let options = {
@@ -38,21 +46,25 @@ async function writeTestingCSV() {
3846 let info = await getPR ( num ) ;
3947
4048 // Get testing instructions if it exists
41- let content = info . data . body ;
42- const match = content . match ( / # # 📝 T e s t I n s t r u c t i o n s : \s * ( [ \s \S ] * ?) (? = # # | $ ) / ) ;
43- let testInstructions = '' ;
44- if ( match ) {
45- testInstructions = match [ 1 ] ;
46- testInstructions = testInstructions . replace ( / < ! - - [ \s \S ] * ?- - > / g, '' ) ;
47- testInstructions = testInstructions . trim ( ) ;
48- testInstructions = escapeCSV ( testInstructions ) ;
49- }
50-
51- if ( testInstructions . length > 350 ) {
52- row . push ( 'See PR for testing instructions' ) ;
53- } else {
54- row . push ( testInstructions ) ;
55- }
49+ // let content = info.data.body;
50+ // let match = undefined;
51+ // if (content) {
52+ // match = content.match(/## 📝 Test Instructions:\s*([\s\S]*?)(?=##|$)/);
53+ // }
54+ // let testInstructions = '';
55+ // if (match) {
56+ // testInstructions = match[1];
57+ // testInstructions = testInstructions.replace(/<!--[\s\S]*?-->/g, '');
58+ // testInstructions = testInstructions.trim();
59+ // testInstructions = escapeCSV(testInstructions);
60+ // }
61+
62+ // if (testInstructions.length > 350) {
63+ // row.push('See PR for testing instructions');
64+ // } else {
65+ // row.push(testInstructions);
66+ // }
67+ row . push ( ',' ) ;
5668 row . push ( info . data . html_url ) ;
5769
5870 if ( ( / \b s 2 \b / gi) . test ( title ) ) {
0 commit comments