feat(cli): add foundation - package setup and entry point
Add @paseo/cli package with: - Package structure with npm workspace integration - bin/paseo entry point using tsx - Commander.js setup with --version and --help - Placeholder subcommands: agent, daemon, permit, worktree, provider
This commit is contained in:
Executable
+2
@@ -0,0 +1,2 @@
|
||||
#!/usr/bin/env npx tsx
|
||||
import '../src/index.js'
|
||||
@@ -0,0 +1,21 @@
|
||||
{
|
||||
"name": "@paseo/cli",
|
||||
"version": "0.1.0",
|
||||
"description": "Paseo CLI - control your AI coding agents from the command line",
|
||||
"type": "module",
|
||||
"bin": {
|
||||
"paseo": "./bin/paseo"
|
||||
},
|
||||
"scripts": {
|
||||
"typecheck": "tsc --noEmit"
|
||||
},
|
||||
"dependencies": {
|
||||
"@paseo/server": "*",
|
||||
"commander": "^12.0.0",
|
||||
"chalk": "^5.3.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"typescript": "^5.2.2",
|
||||
"tsx": "^4.6.0"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,50 @@
|
||||
import { Command } from 'commander'
|
||||
|
||||
const VERSION = '0.1.0'
|
||||
|
||||
export function createCli(): Command {
|
||||
const program = new Command()
|
||||
|
||||
program
|
||||
.name('paseo')
|
||||
.description('Paseo CLI - control your AI coding agents from the command line')
|
||||
.version(VERSION, '-v, --version', 'output the version number')
|
||||
|
||||
// Placeholder subcommands for Phase 1
|
||||
program
|
||||
.command('agent')
|
||||
.description('Manage agents')
|
||||
.action(() => {
|
||||
console.log('agent command (not yet implemented)')
|
||||
})
|
||||
|
||||
program
|
||||
.command('daemon')
|
||||
.description('Manage the Paseo daemon')
|
||||
.action(() => {
|
||||
console.log('daemon command (not yet implemented)')
|
||||
})
|
||||
|
||||
program
|
||||
.command('permit')
|
||||
.description('Manage permission requests')
|
||||
.action(() => {
|
||||
console.log('permit command (not yet implemented)')
|
||||
})
|
||||
|
||||
program
|
||||
.command('worktree')
|
||||
.description('Manage git worktrees')
|
||||
.action(() => {
|
||||
console.log('worktree command (not yet implemented)')
|
||||
})
|
||||
|
||||
program
|
||||
.command('provider')
|
||||
.description('Manage agent providers')
|
||||
.action(() => {
|
||||
console.log('provider command (not yet implemented)')
|
||||
})
|
||||
|
||||
return program
|
||||
}
|
||||
@@ -0,0 +1,4 @@
|
||||
import { createCli } from './cli.js'
|
||||
|
||||
const program = createCli()
|
||||
program.parse()
|
||||
@@ -0,0 +1,17 @@
|
||||
{
|
||||
"extends": "../../tsconfig.base.json",
|
||||
"compilerOptions": {
|
||||
"module": "NodeNext",
|
||||
"moduleResolution": "NodeNext",
|
||||
"outDir": "./dist",
|
||||
"rootDir": "./src",
|
||||
"declaration": true,
|
||||
"declarationMap": true,
|
||||
"sourceMap": true,
|
||||
"noUnusedLocals": true,
|
||||
"noUnusedParameters": true,
|
||||
"noFallthroughCasesInSwitch": true
|
||||
},
|
||||
"include": ["src/**/*"],
|
||||
"exclude": ["node_modules", "dist", "src/**/*.test.ts"]
|
||||
}
|
||||
Reference in New Issue
Block a user