templui-mcp-server
Version:
A Model Context Protocol (MCP) server for TemplUI components, providing AI assistants with access to component source code, documentation, demos, and metadata.
27 lines • 957 B
JavaScript
import { logError, logInfo } from '../utils/logger.js';
// Dynamic import for updater
let updater = null;
// Initialize updater integration
export function initializeUpdater(updateService) {
updater = updateService;
}
export async function handleCheckUpdates() {
try {
logInfo('Checking for TemplUI repository updates...');
if (!updater) {
throw new Error('Update service not initialized');
}
// Get update status from updater service
const updateStatus = await updater.getUpdateStatus();
logInfo('Update check completed successfully');
return {
content: [{ type: "text", text: updateStatus }]
};
}
catch (error) {
logError('Failed to check updates', error);
throw new Error(`Failed to check updates: ${error instanceof Error ? error.message : String(error)}`);
}
}
export const schema = {};
//# sourceMappingURL=check-updates.js.map