Generate Yargs-based CLI applications with commands, positional args, middleware, and TypeScript support. Creates a complete scaffolded CLI application with modern patterns.
Scaffolds Yargs CLI applications with TypeScript, commands, middleware, and modern project structure.
npx claudepluginhub a5c-ai/babysitterThis skill is limited to using the following tools:
README.mdGenerate a complete Yargs CLI application with TypeScript, middleware support, and best practices.
Invoke this skill when you need to:
| Parameter | Type | Required | Description |
|---|---|---|---|
| projectName | string | Yes | Name of the CLI project (kebab-case) |
| description | string | Yes | Short description of the CLI |
| commands | array | No | List of commands to scaffold |
| typescript | boolean | No | Use TypeScript (default: true) |
| packageManager | string | No | npm, yarn, or pnpm (default: npm) |
| strictMode | boolean | No | Enable strict mode (default: true) |
{
"commands": [
{
"name": "serve",
"description": "Start the server",
"aliases": ["s"],
"positional": [
{ "name": "port", "type": "number", "default": 3000 }
],
"options": [
{ "name": "host", "type": "string", "default": "localhost" },
{ "name": "watch", "type": "boolean", "alias": "w" }
]
}
]
}
<projectName>/
├── package.json
├── tsconfig.json
├── .gitignore
├── README.md
├── src/
│ ├── index.ts # Entry point
│ ├── cli.ts # Yargs setup
│ ├── commands/
│ │ ├── index.ts # Command exports
│ │ └── <command>.ts # Command modules
│ ├── middleware/
│ │ ├── logger.ts # Logging middleware
│ │ └── config.ts # Config loading middleware
│ ├── utils/
│ │ └── helpers.ts # Helper utilities
│ └── types/
│ └── index.ts # Type definitions
└── tests/
└── commands/
└── <command>.test.ts
import yargs from 'yargs';
import { hideBin } from 'yargs/helpers';
import * as commands from './commands';
import { loggerMiddleware } from './middleware/logger';
export const cli = yargs(hideBin(process.argv))
.scriptName('<projectName>')
.usage('$0 <cmd> [args]')
.middleware([loggerMiddleware])
.command(commands.serveCommand)
.command(commands.buildCommand)
.demandCommand(1, 'You need at least one command')
.strict()
.fail((msg, err, yargs) => {
if (err) throw err;
console.error(msg);
console.error(yargs.help());
process.exit(1);
})
.help()
.alias('help', 'h')
.version()
.alias('version', 'v')
.wrap(Math.min(120, process.stdout.columns || 80));
import { CommandModule, Argv } from 'yargs';
interface ServeArgs {
port: number;
host: string;
watch: boolean;
}
export const serveCommand: CommandModule<{}, ServeArgs> = {
command: 'serve [port]',
aliases: ['s'],
describe: 'Start the development server',
builder: (yargs: Argv) => {
return yargs
.positional('port', {
type: 'number',
default: 3000,
describe: 'Port to listen on'
})
.option('host', {
type: 'string',
default: 'localhost',
describe: 'Host to bind to'
})
.option('watch', {
alias: 'w',
type: 'boolean',
default: false,
describe: 'Enable watch mode'
});
},
handler: async (argv) => {
console.log(`Starting server on ${argv.host}:${argv.port}`);
}
};
{
"dependencies": {
"yargs": "^17.0.0"
},
"devDependencies": {
"@types/node": "^20.0.0",
"@types/yargs": "^17.0.0",
"typescript": "^5.0.0",
"tsx": "^4.0.0",
"vitest": "^1.0.0"
}
}
Activates when the user asks about AI prompts, needs prompt templates, wants to search for prompts, or mentions prompts.chat. Use for discovering, retrieving, and improving prompts.
Search, retrieve, and install Agent Skills from the prompts.chat registry using MCP tools. Use when the user asks to find skills, browse skill catalogs, install a skill for Claude, or extend Claude's capabilities with reusable AI agent components.
This skill should be used when the user asks to "create an agent", "add an agent", "write a subagent", "agent frontmatter", "when to use description", "agent examples", "agent tools", "agent colors", "autonomous agent", or needs guidance on agent structure, system prompts, triggering conditions, or agent development best practices for Claude Code plugins.