Skip to content

Commit 84cbd4e

Browse files
committed
convert to process-data to cjs
1 parent 771febc commit 84cbd4e

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

tools/pipelines/build-performance-observability-utils/generate-data-json.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ echo "Raw data size: $(du -h "$RAW_FILE" | cut -f1)"
6464

6565
# Process raw data into aggregated metrics using Node.js
6666
echo "Processing raw data into aggregated metrics..."
67-
node "$SCRIPT_DIR/process-data.js" "$RAW_FILE" "$OUTPUT_FILE" "$MODE"
67+
node "$SCRIPT_DIR/process-data.cjs" "$RAW_FILE" "$OUTPUT_FILE" "$MODE"
6868

6969
# Clean up intermediate files
7070
rm -f "$RAW_FILE" "$TIMELINES_FILE"

tools/pipelines/build-performance-observability-utils/process-data.js renamed to tools/pipelines/build-performance-observability-utils/process-data.cjs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
* Pre-processes raw ADO build and timeline data into aggregated dashboard metrics.
88
* This runs during the pipeline to reduce payload size from ~300MB to ~50KB.
99
*
10-
* Usage: node process-data.js <input-raw.json> <output-processed.json> <mode>
10+
* Usage: node process-data.cjs <input-raw.json> <output-processed.json> <mode>
1111
* mode: "public" or "internal"
1212
*/
1313

@@ -350,7 +350,9 @@ function processRawData(rawData, mode) {
350350
function main() {
351351
const args = process.argv.slice(2);
352352
if (args.length < 3) {
353-
console.error("Usage: node process-data.js <input-raw.json> <output-processed.json> <mode>");
353+
console.error(
354+
"Usage: node process-data.cjs <input-raw.json> <output-processed.json> <mode>",
355+
);
354356
console.error(" mode: 'public' or 'internal'");
355357
process.exit(1);
356358
}

0 commit comments

Comments
 (0)