difit 1.1.1 ā 1.1.2
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/dist/cli/index.js +15 -2
- package/dist/client/assets/index-BLEv14wb.js +187 -0
- package/dist/client/assets/index-CmT0VFrk.css +1 -0
- package/dist/client/assets/prism-java-BzVDwsAU.js +1 -0
- package/dist/client/assets/prism-php-CaHq39v2.js +1 -0
- package/dist/client/assets/prism-ruby-ZR-2dwYA.js +1 -0
- package/dist/client/index.html +2 -2
- package/dist/server/server.js +57 -3
- package/package.json +24 -24
- package/dist/client/assets/index-B67TY4_1.js +0 -178
- package/dist/client/assets/index-BHrhjAlZ.css +0 -1
- package/dist/client/assets/prism-java-Bz0cy7o8.js +0 -1
- package/dist/client/assets/prism-php-Y_bwvUTe.js +0 -1
- package/dist/client/assets/prism-ruby-pgU1Zfy6.js +0 -1
package/dist/cli/index.js
CHANGED
|
@@ -54,7 +54,7 @@ program
|
|
|
54
54
|
console.error(`Error: ${validation.error}`);
|
|
55
55
|
process.exit(1);
|
|
56
56
|
}
|
|
57
|
-
const { url } = await startServer({
|
|
57
|
+
const { url, port } = await startServer({
|
|
58
58
|
targetCommitish,
|
|
59
59
|
baseCommitish,
|
|
60
60
|
preferredPort: options.port,
|
|
@@ -69,8 +69,21 @@ program
|
|
|
69
69
|
else {
|
|
70
70
|
console.log('š” Use --open to automatically open browser\n');
|
|
71
71
|
}
|
|
72
|
-
process.on('SIGINT', () => {
|
|
72
|
+
process.on('SIGINT', async () => {
|
|
73
73
|
console.log('\nš Shutting down ReviewIt server...');
|
|
74
|
+
// Try to fetch comments before shutting down
|
|
75
|
+
try {
|
|
76
|
+
const response = await fetch(`http://localhost:${port}/api/comments-output`);
|
|
77
|
+
if (response.ok) {
|
|
78
|
+
const data = await response.text();
|
|
79
|
+
if (data.trim()) {
|
|
80
|
+
console.log(data);
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
catch {
|
|
85
|
+
// Silently ignore fetch errors during shutdown
|
|
86
|
+
}
|
|
74
87
|
process.exit(0);
|
|
75
88
|
});
|
|
76
89
|
}
|