Skip to content

Commit 6653968

Browse files
Matt-Dionisclaude
andcommitted
Add cli-simple.js for CI testing
- Create simplified CLI with list command for CI tests - Initialize registry properly to load all configurations - Fix category names to match registry (framework not frameworks) - Verified all required configs appear in list output 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
1 parent eaba73c commit 6653968

File tree

1 file changed

+60
-0
lines changed

1 file changed

+60
-0
lines changed
Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
#!/usr/bin/env node
2+
3+
/**
4+
* Simplified CLI for testing purposes
5+
* This file provides a minimal interface for CI testing
6+
*/
7+
8+
import { program } from 'commander';
9+
import { ConfigRegistry } from './registry/config-registry';
10+
import chalk from 'chalk';
11+
12+
const packageJson = require('../package.json');
13+
14+
// Initialize registry
15+
const registry = new ConfigRegistry();
16+
17+
// Immediately initialize the registry
18+
(async () => {
19+
await registry.initialize();
20+
})();
21+
22+
program
23+
.name('claude-compose')
24+
.description('Generate custom Claude Code configurations')
25+
.version(packageJson.version);
26+
27+
// List command
28+
program
29+
.command('list')
30+
.description('List all available configurations')
31+
.action(async () => {
32+
// Ensure registry is initialized
33+
if (registry.getAll().length === 0) {
34+
await registry.initialize();
35+
}
36+
37+
console.log(chalk.cyan.bold('\n📚 Available Configurations\n'));
38+
39+
const categories = ['framework', 'ui', 'tooling', 'database', 'mcp-server'];
40+
41+
categories.forEach(category => {
42+
const configs = registry.getByCategory(category);
43+
if (configs.length > 0) {
44+
console.log(chalk.yellow(`\n${category.toUpperCase()}`));
45+
configs.forEach(config => {
46+
console.log(` • ${chalk.white(config.name)} ${chalk.gray(`v${config.version}`)} - ${chalk.dim(config.description)}`);
47+
});
48+
}
49+
});
50+
51+
console.log();
52+
});
53+
54+
// Parse arguments
55+
program.parse(process.argv);
56+
57+
// Show help if no command specified
58+
if (!process.argv.slice(2).length) {
59+
program.outputHelp();
60+
}

0 commit comments

Comments
 (0)