@lvnt/release-radar 1.9.15 ā 1.9.17
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/index.js +46 -0
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -192,6 +192,39 @@ function saveConfig() {
|
|
|
192
192
|
writeFileSync(CONFIG_PATH, JSON.stringify(configData, null, 2));
|
|
193
193
|
}
|
|
194
194
|
// Bot commands
|
|
195
|
+
bot.onText(/\/help/, async (msg) => {
|
|
196
|
+
if (msg.chat.id.toString() !== validatedChatId)
|
|
197
|
+
return;
|
|
198
|
+
const help = `š *Available Commands*
|
|
199
|
+
|
|
200
|
+
*Version Checking*
|
|
201
|
+
/check - Check all tools for updates
|
|
202
|
+
/status - Show tracked versions and schedule
|
|
203
|
+
|
|
204
|
+
*Scheduling*
|
|
205
|
+
/interval - Show current check interval
|
|
206
|
+
/setinterval <hours> - Set check interval (1-24)
|
|
207
|
+
/schedule - Show schedule mode and settings
|
|
208
|
+
/setmode <interval|daily> - Set schedule mode
|
|
209
|
+
/settime <HH:MM> - Set daily check time
|
|
210
|
+
|
|
211
|
+
*CLI Publishing*
|
|
212
|
+
/clipreview - Preview CLI contents
|
|
213
|
+
/publishcli - Publish CLI to npm
|
|
214
|
+
|
|
215
|
+
*Asset Mirroring*
|
|
216
|
+
/mirrorall - Mirror all tools needing it
|
|
217
|
+
/mirror <tool> [version] - Mirror single tool
|
|
218
|
+
/mirror <tool> --force - Re-mirror existing
|
|
219
|
+
|
|
220
|
+
*Maintenance*
|
|
221
|
+
/generate - Generate versions.json locally
|
|
222
|
+
/resetversion <tool> - Clear cached version
|
|
223
|
+
/resetall - Clear all cached versions
|
|
224
|
+
|
|
225
|
+
/help - Show this message`;
|
|
226
|
+
await bot.sendMessage(validatedChatId, help, { parse_mode: 'Markdown' });
|
|
227
|
+
});
|
|
195
228
|
bot.onText(/\/check/, async (msg) => {
|
|
196
229
|
if (msg.chat.id.toString() !== validatedChatId)
|
|
197
230
|
return;
|
|
@@ -450,6 +483,19 @@ bot.onText(/\/mirrorall/, async (msg) => {
|
|
|
450
483
|
message += `\n\nā ${failCount} failed:\n${failures.join('\n')}`;
|
|
451
484
|
}
|
|
452
485
|
await bot.sendMessage(validatedChatId, message);
|
|
486
|
+
// Auto-publish CLI if mirroring succeeded and publisher is configured
|
|
487
|
+
if (successCount > 0 && cliPublisher.isConfigured()) {
|
|
488
|
+
const state = storage.load();
|
|
489
|
+
const mirrorUrls = storage.getAllMirrorUrls();
|
|
490
|
+
console.log(`[mirrorall] Auto-publishing CLI with ${Object.keys(mirrorUrls).length} mirror URLs`);
|
|
491
|
+
const publishResult = await cliPublisher.publish(state.versions, mirrorUrls);
|
|
492
|
+
if (publishResult.success) {
|
|
493
|
+
await bot.sendMessage(validatedChatId, `š¦ CLI published: v${publishResult.version}`);
|
|
494
|
+
}
|
|
495
|
+
else {
|
|
496
|
+
await bot.sendMessage(validatedChatId, `ā ļø CLI publish failed: ${publishResult.error}`);
|
|
497
|
+
}
|
|
498
|
+
}
|
|
453
499
|
});
|
|
454
500
|
bot.onText(/\/mirror(?:\s+(.+))?/, async (msg, match) => {
|
|
455
501
|
if (msg.chat.id.toString() !== validatedChatId)
|