@ark/attest 0.44.5 → 0.44.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/out/cli/trace.js +13 -20
- package/package.json +1 -1
package/out/cli/trace.js
CHANGED
|
@@ -34,26 +34,19 @@ export const trace = async (args) => {
|
|
|
34
34
|
ensureDir(traceDir);
|
|
35
35
|
let tracingOutput = "";
|
|
36
36
|
outputCapture.clear();
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
const summaryContent = outputCapture.getBuffer().split("\n")[0] +
|
|
51
|
-
"\n" +
|
|
52
|
-
tracingOutput +
|
|
53
|
-
"\n" +
|
|
54
|
-
outputCapture.getBuffer().split("\n").slice(1).join("\n");
|
|
55
|
-
writeFile(summaryPath, summaryContent);
|
|
56
|
-
}
|
|
37
|
+
outputCapture.write(`⏳ Gathering type trace data for ${packageDir}...`);
|
|
38
|
+
tracingOutput = generateTraceData(traceDir, config.tsconfig, packageDir);
|
|
39
|
+
outputCapture.write(`⏳ Analyzing type trace data for ${packageDir}...`);
|
|
40
|
+
analyzeTypeInstantiations(traceDir);
|
|
41
|
+
// Write summary file containing our messages followed by compiler output
|
|
42
|
+
// This ensures the initial message comes first in the file
|
|
43
|
+
const summaryPath = join(traceDir, "summary.txt");
|
|
44
|
+
const summaryContent = outputCapture.getBuffer().split("\n")[0] +
|
|
45
|
+
"\n" +
|
|
46
|
+
tracingOutput +
|
|
47
|
+
"\n" +
|
|
48
|
+
outputCapture.getBuffer().split("\n").slice(1).join("\n");
|
|
49
|
+
writeFile(summaryPath, summaryContent);
|
|
57
50
|
};
|
|
58
51
|
const generateTraceData = (traceDir, tsconfigPath, packageDir) => {
|
|
59
52
|
// Capture the output instead of just displaying it
|