diff --git a/.gitignore b/.gitignore index 3f00341b..352fc8f6 100644 --- a/.gitignore +++ b/.gitignore @@ -80,7 +80,9 @@ out # Nuxt.js build / generate output .nuxt -dist + +# Build output +dist/ # Gatsby files .cache/ diff --git a/bin/openspec.js b/bin/openspec.js new file mode 100755 index 00000000..3341bce5 --- /dev/null +++ b/bin/openspec.js @@ -0,0 +1,3 @@ +#!/usr/bin/env node + +import '../dist/cli/index.js'; \ No newline at end of file diff --git a/build.js b/build.js new file mode 100644 index 00000000..c63568af --- /dev/null +++ b/build.js @@ -0,0 +1,22 @@ +#!/usr/bin/env node + +import { execSync } from 'child_process'; +import { existsSync, rmSync } from 'fs'; + +console.log('šŸ”Ø Building OpenSpec...\n'); + +// Clean dist directory +if (existsSync('dist')) { + console.log('Cleaning dist directory...'); + rmSync('dist', { recursive: true, force: true }); +} + +// Run TypeScript compiler +console.log('Compiling TypeScript...'); +try { + execSync('tsc', { stdio: 'inherit' }); + console.log('\nāœ… Build completed successfully!'); +} catch (error) { + console.error('\nāŒ Build failed!'); + process.exit(1); +} \ No newline at end of file diff --git a/openspec/README.md b/openspec/README.md index 1f8ccc28..1e084fa2 100644 --- a/openspec/README.md +++ b/openspec/README.md @@ -111,7 +111,7 @@ patches/ 2. **Review** → User reviews and approves the proposal 3. **Implement** → Follow the approved tasks.md 4. **Deploy** → User confirms deployment -5. **Update Specs** → Sync specs/ with new reality +5. **Update Specs** → Sync specs/ with new reality (IF the change affects system capabilities) 6. **Archive** → Move to `changes/archive/YYYY-MM-DD-[name]/` ### 5. Implementing Changes @@ -128,6 +128,27 @@ Once a change is deployed: 2. If design.md exists, move proven patterns to `specs/[capability]/design.md` 3. Archive the change directory with date prefix +### 7. Types of Changes That Don't Require Specs + +Some changes only affect development infrastructure and don't need specs: +- Initial project setup (package.json, tsconfig.json, etc.) +- Development tooling changes (linters, formatters, build tools) +- CI/CD configuration +- Development dependencies + +For these changes: +1. Implement → Deploy → Mark tasks complete → Archive +2. Skip the "Update Specs" step entirely + +### What Deserves a Spec? + +Ask yourself: +- Is this a system capability that users or other systems interact with? +- Does it have ongoing behavior that needs documentation? +- Would a new developer need to understand this to work with the system? + +If NO to all → No spec needed (likely just tooling/infrastructure) + ## Understanding Specs vs Code ### Specs Document WHAT and WHY @@ -174,6 +195,17 @@ You should: 3. If no → Create change proposal (it's a behavior change) ``` +### Infrastructure Setup +``` +User: "Initialize TypeScript project" + +You should: +1. Create change proposal for TypeScript setup +2. Implement configuration files +3. Mark tasks complete +4. Archive (no specs needed - this is tooling, not a capability) +``` + ## Summary Workflow 1. **Receive request** → Determine if it needs a change proposal diff --git a/openspec/changes/initialize-typescript-project/design.md b/openspec/changes/archive/2025-08-05-initialize-typescript-project/design.md similarity index 100% rename from openspec/changes/initialize-typescript-project/design.md rename to openspec/changes/archive/2025-08-05-initialize-typescript-project/design.md diff --git a/openspec/changes/initialize-typescript-project/proposal.md b/openspec/changes/archive/2025-08-05-initialize-typescript-project/proposal.md similarity index 100% rename from openspec/changes/initialize-typescript-project/proposal.md rename to openspec/changes/archive/2025-08-05-initialize-typescript-project/proposal.md diff --git a/openspec/changes/archive/2025-08-05-initialize-typescript-project/tasks.md b/openspec/changes/archive/2025-08-05-initialize-typescript-project/tasks.md new file mode 100644 index 00000000..7b68896c --- /dev/null +++ b/openspec/changes/archive/2025-08-05-initialize-typescript-project/tasks.md @@ -0,0 +1,25 @@ +# Tasks + +## 1. Project Configuration +- [x] 1.1 Create package.json with project metadata, scripts, and ESM configuration +- [x] 1.2 Configure TypeScript with tsconfig.json for ESM output +- [x] 1.3 Add .gitignore for Node.js/TypeScript projects +- [x] 1.4 Set Node.js engine requirement to >=20.19.0 + +## 2. Directory Structure +- [x] 2.1 Create src/ directory for source code +- [x] 2.2 Create src/cli/ for CLI commands +- [x] 2.3 Create src/core/ for core OpenSpec logic +- [x] 2.4 Create src/utils/ for shared utilities + +## 3. Build Configuration +- [x] 3.1 Create build.js for native TypeScript compilation +- [x] 3.2 Configure development scripts (build, dev) +- [x] 3.3 Set up package entry points with ESM exports +- [x] 3.4 Configure proper file extensions handling for ESM + +## 4. Initial Dependencies +- [x] 4.1 Add TypeScript as dev dependency +- [x] 4.2 Add commander for CLI framework +- [x] 4.3 Add @inquirer/prompts for user interaction +- [x] 4.4 Add necessary type definitions \ No newline at end of file diff --git a/openspec/changes/initialize-typescript-project/tasks.md b/openspec/changes/initialize-typescript-project/tasks.md deleted file mode 100644 index 5a8b26b4..00000000 --- a/openspec/changes/initialize-typescript-project/tasks.md +++ /dev/null @@ -1,25 +0,0 @@ -# Tasks - -## 1. Project Configuration -- [ ] 1.1 Create package.json with project metadata, scripts, and ESM configuration -- [ ] 1.2 Configure TypeScript with tsconfig.json for ESM output -- [ ] 1.3 Add .gitignore for Node.js/TypeScript projects -- [ ] 1.4 Set Node.js engine requirement to >=20.19.0 - -## 2. Directory Structure -- [ ] 2.1 Create src/ directory for source code -- [ ] 2.2 Create src/cli/ for CLI commands -- [ ] 2.3 Create src/core/ for core OpenSpec logic -- [ ] 2.4 Create src/utils/ for shared utilities - -## 3. Build Configuration -- [ ] 3.1 Create build.js for native TypeScript compilation -- [ ] 3.2 Configure development scripts (build, dev) -- [ ] 3.3 Set up package entry points with ESM exports -- [ ] 3.4 Configure proper file extensions handling for ESM - -## 4. Initial Dependencies -- [ ] 4.1 Add TypeScript as dev dependency -- [ ] 4.2 Add commander for CLI framework -- [ ] 4.3 Add @inquirer/prompts for user interaction -- [ ] 4.4 Add necessary type definitions \ No newline at end of file diff --git a/package.json b/package.json new file mode 100644 index 00000000..a0ead9f2 --- /dev/null +++ b/package.json @@ -0,0 +1,53 @@ +{ + "name": "openspec", + "version": "0.0.1", + "description": "AI-native system for spec-driven development", + "keywords": [ + "openspec", + "specs", + "cli", + "ai", + "development" + ], + "homepage": "https://github.com/tabdilsaidixit/openspec", + "repository": { + "type": "git", + "url": "git+https://github.com/tabdilsaidixit/openspec.git" + }, + "license": "MIT", + "author": "OpenSpec Contributors", + "type": "module", + "exports": { + ".": { + "types": "./dist/index.d.ts", + "default": "./dist/index.js" + } + }, + "bin": { + "openspec": "./bin/openspec.js" + }, + "files": [ + "dist", + "bin", + "!dist/**/*.test.js", + "!dist/**/__tests__", + "!dist/**/*.map" + ], + "scripts": { + "build": "node build.js", + "dev": "tsc --watch", + "dev:cli": "pnpm build && node bin/openspec.js", + "prepare": "npm run build" + }, + "engines": { + "node": ">=20.19.0" + }, + "devDependencies": { + "@types/node": "^24.2.0", + "typescript": "^5.9.2" + }, + "dependencies": { + "@inquirer/prompts": "^7.8.0", + "commander": "^14.0.0" + } +} \ No newline at end of file diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml new file mode 100644 index 00000000..38fd2c6b --- /dev/null +++ b/pnpm-lock.yaml @@ -0,0 +1,435 @@ +lockfileVersion: '9.0' + +settings: + autoInstallPeers: true + excludeLinksFromLockfile: false + +importers: + + .: + dependencies: + '@inquirer/prompts': + specifier: ^7.8.0 + version: 7.8.0(@types/node@24.2.0) + commander: + specifier: ^14.0.0 + version: 14.0.0 + devDependencies: + '@types/node': + specifier: ^24.2.0 + version: 24.2.0 + typescript: + specifier: ^5.9.2 + version: 5.9.2 + +packages: + + '@inquirer/checkbox@4.2.0': + resolution: {integrity: sha512-fdSw07FLJEU5vbpOPzXo5c6xmMGDzbZE2+niuDHX5N6mc6V0Ebso/q3xiHra4D73+PMsC8MJmcaZKuAAoaQsSA==} + engines: {node: '>=18'} + peerDependencies: + '@types/node': '>=18' + peerDependenciesMeta: + '@types/node': + optional: true + + '@inquirer/confirm@5.1.14': + resolution: {integrity: sha512-5yR4IBfe0kXe59r1YCTG8WXkUbl7Z35HK87Sw+WUyGD8wNUx7JvY7laahzeytyE1oLn74bQnL7hstctQxisQ8Q==} + engines: {node: '>=18'} + peerDependencies: + '@types/node': '>=18' + peerDependenciesMeta: + '@types/node': + optional: true + + '@inquirer/core@10.1.15': + resolution: {integrity: sha512-8xrp836RZvKkpNbVvgWUlxjT4CraKk2q+I3Ksy+seI2zkcE+y6wNs1BVhgcv8VyImFecUhdQrYLdW32pAjwBdA==} + engines: {node: '>=18'} + peerDependencies: + '@types/node': '>=18' + peerDependenciesMeta: + '@types/node': + optional: true + + '@inquirer/editor@4.2.15': + resolution: {integrity: sha512-wst31XT8DnGOSS4nNJDIklGKnf+8shuauVrWzgKegWUe28zfCftcWZ2vktGdzJgcylWSS2SrDnYUb6alZcwnCQ==} + engines: {node: '>=18'} + peerDependencies: + '@types/node': '>=18' + peerDependenciesMeta: + '@types/node': + optional: true + + '@inquirer/expand@4.0.17': + resolution: {integrity: sha512-PSqy9VmJx/VbE3CT453yOfNa+PykpKg/0SYP7odez1/NWBGuDXgPhp4AeGYYKjhLn5lUUavVS/JbeYMPdH50Mw==} + engines: {node: '>=18'} + peerDependencies: + '@types/node': '>=18' + peerDependenciesMeta: + '@types/node': + optional: true + + '@inquirer/figures@1.0.13': + resolution: {integrity: sha512-lGPVU3yO9ZNqA7vTYz26jny41lE7yoQansmqdMLBEfqaGsmdg7V3W9mK9Pvb5IL4EVZ9GnSDGMO/cJXud5dMaw==} + engines: {node: '>=18'} + + '@inquirer/input@4.2.1': + resolution: {integrity: sha512-tVC+O1rBl0lJpoUZv4xY+WGWY8V5b0zxU1XDsMsIHYregdh7bN5X5QnIONNBAl0K765FYlAfNHS2Bhn7SSOVow==} + engines: {node: '>=18'} + peerDependencies: + '@types/node': '>=18' + peerDependenciesMeta: + '@types/node': + optional: true + + '@inquirer/number@3.0.17': + resolution: {integrity: sha512-GcvGHkyIgfZgVnnimURdOueMk0CztycfC8NZTiIY9arIAkeOgt6zG57G+7vC59Jns3UX27LMkPKnKWAOF5xEYg==} + engines: {node: '>=18'} + peerDependencies: + '@types/node': '>=18' + peerDependenciesMeta: + '@types/node': + optional: true + + '@inquirer/password@4.0.17': + resolution: {integrity: sha512-DJolTnNeZ00E1+1TW+8614F7rOJJCM4y4BAGQ3Gq6kQIG+OJ4zr3GLjIjVVJCbKsk2jmkmv6v2kQuN/vriHdZA==} + engines: {node: '>=18'} + peerDependencies: + '@types/node': '>=18' + peerDependenciesMeta: + '@types/node': + optional: true + + '@inquirer/prompts@7.8.0': + resolution: {integrity: sha512-JHwGbQ6wjf1dxxnalDYpZwZxUEosT+6CPGD9Zh4sm9WXdtUp9XODCQD3NjSTmu+0OAyxWXNOqf0spjIymJa2Tw==} + engines: {node: '>=18'} + peerDependencies: + '@types/node': '>=18' + peerDependenciesMeta: + '@types/node': + optional: true + + '@inquirer/rawlist@4.1.5': + resolution: {integrity: sha512-R5qMyGJqtDdi4Ht521iAkNqyB6p2UPuZUbMifakg1sWtu24gc2Z8CJuw8rP081OckNDMgtDCuLe42Q2Kr3BolA==} + engines: {node: '>=18'} + peerDependencies: + '@types/node': '>=18' + peerDependenciesMeta: + '@types/node': + optional: true + + '@inquirer/search@3.1.0': + resolution: {integrity: sha512-PMk1+O/WBcYJDq2H7foV0aAZSmDdkzZB9Mw2v/DmONRJopwA/128cS9M/TXWLKKdEQKZnKwBzqu2G4x/2Nqx8Q==} + engines: {node: '>=18'} + peerDependencies: + '@types/node': '>=18' + peerDependenciesMeta: + '@types/node': + optional: true + + '@inquirer/select@4.3.1': + resolution: {integrity: sha512-Gfl/5sqOF5vS/LIrSndFgOh7jgoe0UXEizDqahFRkq5aJBLegZ6WjuMh/hVEJwlFQjyLq1z9fRtvUMkb7jM1LA==} + engines: {node: '>=18'} + peerDependencies: + '@types/node': '>=18' + peerDependenciesMeta: + '@types/node': + optional: true + + '@inquirer/type@3.0.8': + resolution: {integrity: sha512-lg9Whz8onIHRthWaN1Q9EGLa/0LFJjyM8mEUbL1eTi6yMGvBf8gvyDLtxSXztQsxMvhxxNpJYrwa1YHdq+w4Jw==} + engines: {node: '>=18'} + peerDependencies: + '@types/node': '>=18' + peerDependenciesMeta: + '@types/node': + optional: true + + '@types/node@24.2.0': + resolution: {integrity: sha512-3xyG3pMCq3oYCNg7/ZP+E1ooTaGB4cG8JWRsqqOYQdbWNY4zbaV0Ennrd7stjiJEFZCaybcIgpTjJWHRfBSIDw==} + + ansi-escapes@4.3.2: + resolution: {integrity: sha512-gKXj5ALrKWQLsYG9jlTRmR/xKluxHV+Z9QEwNIgCfM1/uwPMCuzVVnh5mwTd+OuBZcwSIMbqssNWRm1lE51QaQ==} + engines: {node: '>=8'} + + ansi-regex@5.0.1: + resolution: {integrity: sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==} + engines: {node: '>=8'} + + ansi-styles@4.3.0: + resolution: {integrity: sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==} + engines: {node: '>=8'} + + chardet@0.7.0: + resolution: {integrity: sha512-mT8iDcrh03qDGRRmoA2hmBJnxpllMR+0/0qlzjqZES6NdiWDcZkCNAk4rPFZ9Q85r27unkiNNg8ZOiwZXBHwcA==} + + cli-width@4.1.0: + resolution: {integrity: sha512-ouuZd4/dm2Sw5Gmqy6bGyNNNe1qt9RpmxveLSO7KcgsTnU7RXfsw+/bukWGo1abgBiMAic068rclZsO4IWmmxQ==} + engines: {node: '>= 12'} + + color-convert@2.0.1: + resolution: {integrity: sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==} + engines: {node: '>=7.0.0'} + + color-name@1.1.4: + resolution: {integrity: sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==} + + commander@14.0.0: + resolution: {integrity: sha512-2uM9rYjPvyq39NwLRqaiLtWHyDC1FvryJDa2ATTVims5YAS4PupsEQsDvP14FqhFr0P49CYDugi59xaxJlTXRA==} + engines: {node: '>=20'} + + emoji-regex@8.0.0: + resolution: {integrity: sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==} + + external-editor@3.1.0: + resolution: {integrity: sha512-hMQ4CX1p1izmuLYyZqLMO/qGNw10wSv9QDCPfzXfyFrOaCSSoRfqE1Kf1s5an66J5JZC62NewG+mK49jOCtQew==} + engines: {node: '>=4'} + + iconv-lite@0.4.24: + resolution: {integrity: sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==} + engines: {node: '>=0.10.0'} + + is-fullwidth-code-point@3.0.0: + resolution: {integrity: sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==} + engines: {node: '>=8'} + + mute-stream@2.0.0: + resolution: {integrity: sha512-WWdIxpyjEn+FhQJQQv9aQAYlHoNVdzIzUySNV1gHUPDSdZJ3yZn7pAAbQcV7B56Mvu881q9FZV+0Vx2xC44VWA==} + engines: {node: ^18.17.0 || >=20.5.0} + + os-tmpdir@1.0.2: + resolution: {integrity: sha512-D2FR03Vir7FIu45XBY20mTb+/ZSWB00sjU9jdQXt83gDrI4Ztz5Fs7/yy74g2N5SVQY4xY1qDr4rNddwYRVX0g==} + engines: {node: '>=0.10.0'} + + safer-buffer@2.1.2: + resolution: {integrity: sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==} + + signal-exit@4.1.0: + resolution: {integrity: sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==} + engines: {node: '>=14'} + + string-width@4.2.3: + resolution: {integrity: sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==} + engines: {node: '>=8'} + + strip-ansi@6.0.1: + resolution: {integrity: sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==} + engines: {node: '>=8'} + + tmp@0.0.33: + resolution: {integrity: sha512-jRCJlojKnZ3addtTOjdIqoRuPEKBvNXcGYqzO6zWZX8KfKEpnGY5jfggJQ3EjKuu8D4bJRr0y+cYJFmYbImXGw==} + engines: {node: '>=0.6.0'} + + type-fest@0.21.3: + resolution: {integrity: sha512-t0rzBq87m3fVcduHDUFhKmyyX+9eo6WQjZvf51Ea/M0Q7+T374Jp1aUiyUl0GKxp8M/OETVHSDvmkyPgvX+X2w==} + engines: {node: '>=10'} + + typescript@5.9.2: + resolution: {integrity: sha512-CWBzXQrc/qOkhidw1OzBTQuYRbfyxDXJMVJ1XNwUHGROVmuaeiEm3OslpZ1RV96d7SKKjZKrSJu3+t/xlw3R9A==} + engines: {node: '>=14.17'} + hasBin: true + + undici-types@7.10.0: + resolution: {integrity: sha512-t5Fy/nfn+14LuOc2KNYg75vZqClpAiqscVvMygNnlsHBFpSXdJaYtXMcdNLpl/Qvc3P2cB3s6lOV51nqsFq4ag==} + + wrap-ansi@6.2.0: + resolution: {integrity: sha512-r6lPcBGxZXlIcymEu7InxDMhdW0KDxpLgoFLcguasxCaJ/SOIZwINatK9KY/tf+ZrlywOKU0UDj3ATXUBfxJXA==} + engines: {node: '>=8'} + + yoctocolors-cjs@2.1.2: + resolution: {integrity: sha512-cYVsTjKl8b+FrnidjibDWskAv7UKOfcwaVZdp/it9n1s9fU3IkgDbhdIRKCW4JDsAlECJY0ytoVPT3sK6kideA==} + engines: {node: '>=18'} + +snapshots: + + '@inquirer/checkbox@4.2.0(@types/node@24.2.0)': + dependencies: + '@inquirer/core': 10.1.15(@types/node@24.2.0) + '@inquirer/figures': 1.0.13 + '@inquirer/type': 3.0.8(@types/node@24.2.0) + ansi-escapes: 4.3.2 + yoctocolors-cjs: 2.1.2 + optionalDependencies: + '@types/node': 24.2.0 + + '@inquirer/confirm@5.1.14(@types/node@24.2.0)': + dependencies: + '@inquirer/core': 10.1.15(@types/node@24.2.0) + '@inquirer/type': 3.0.8(@types/node@24.2.0) + optionalDependencies: + '@types/node': 24.2.0 + + '@inquirer/core@10.1.15(@types/node@24.2.0)': + dependencies: + '@inquirer/figures': 1.0.13 + '@inquirer/type': 3.0.8(@types/node@24.2.0) + ansi-escapes: 4.3.2 + cli-width: 4.1.0 + mute-stream: 2.0.0 + signal-exit: 4.1.0 + wrap-ansi: 6.2.0 + yoctocolors-cjs: 2.1.2 + optionalDependencies: + '@types/node': 24.2.0 + + '@inquirer/editor@4.2.15(@types/node@24.2.0)': + dependencies: + '@inquirer/core': 10.1.15(@types/node@24.2.0) + '@inquirer/type': 3.0.8(@types/node@24.2.0) + external-editor: 3.1.0 + optionalDependencies: + '@types/node': 24.2.0 + + '@inquirer/expand@4.0.17(@types/node@24.2.0)': + dependencies: + '@inquirer/core': 10.1.15(@types/node@24.2.0) + '@inquirer/type': 3.0.8(@types/node@24.2.0) + yoctocolors-cjs: 2.1.2 + optionalDependencies: + '@types/node': 24.2.0 + + '@inquirer/figures@1.0.13': {} + + '@inquirer/input@4.2.1(@types/node@24.2.0)': + dependencies: + '@inquirer/core': 10.1.15(@types/node@24.2.0) + '@inquirer/type': 3.0.8(@types/node@24.2.0) + optionalDependencies: + '@types/node': 24.2.0 + + '@inquirer/number@3.0.17(@types/node@24.2.0)': + dependencies: + '@inquirer/core': 10.1.15(@types/node@24.2.0) + '@inquirer/type': 3.0.8(@types/node@24.2.0) + optionalDependencies: + '@types/node': 24.2.0 + + '@inquirer/password@4.0.17(@types/node@24.2.0)': + dependencies: + '@inquirer/core': 10.1.15(@types/node@24.2.0) + '@inquirer/type': 3.0.8(@types/node@24.2.0) + ansi-escapes: 4.3.2 + optionalDependencies: + '@types/node': 24.2.0 + + '@inquirer/prompts@7.8.0(@types/node@24.2.0)': + dependencies: + '@inquirer/checkbox': 4.2.0(@types/node@24.2.0) + '@inquirer/confirm': 5.1.14(@types/node@24.2.0) + '@inquirer/editor': 4.2.15(@types/node@24.2.0) + '@inquirer/expand': 4.0.17(@types/node@24.2.0) + '@inquirer/input': 4.2.1(@types/node@24.2.0) + '@inquirer/number': 3.0.17(@types/node@24.2.0) + '@inquirer/password': 4.0.17(@types/node@24.2.0) + '@inquirer/rawlist': 4.1.5(@types/node@24.2.0) + '@inquirer/search': 3.1.0(@types/node@24.2.0) + '@inquirer/select': 4.3.1(@types/node@24.2.0) + optionalDependencies: + '@types/node': 24.2.0 + + '@inquirer/rawlist@4.1.5(@types/node@24.2.0)': + dependencies: + '@inquirer/core': 10.1.15(@types/node@24.2.0) + '@inquirer/type': 3.0.8(@types/node@24.2.0) + yoctocolors-cjs: 2.1.2 + optionalDependencies: + '@types/node': 24.2.0 + + '@inquirer/search@3.1.0(@types/node@24.2.0)': + dependencies: + '@inquirer/core': 10.1.15(@types/node@24.2.0) + '@inquirer/figures': 1.0.13 + '@inquirer/type': 3.0.8(@types/node@24.2.0) + yoctocolors-cjs: 2.1.2 + optionalDependencies: + '@types/node': 24.2.0 + + '@inquirer/select@4.3.1(@types/node@24.2.0)': + dependencies: + '@inquirer/core': 10.1.15(@types/node@24.2.0) + '@inquirer/figures': 1.0.13 + '@inquirer/type': 3.0.8(@types/node@24.2.0) + ansi-escapes: 4.3.2 + yoctocolors-cjs: 2.1.2 + optionalDependencies: + '@types/node': 24.2.0 + + '@inquirer/type@3.0.8(@types/node@24.2.0)': + optionalDependencies: + '@types/node': 24.2.0 + + '@types/node@24.2.0': + dependencies: + undici-types: 7.10.0 + + ansi-escapes@4.3.2: + dependencies: + type-fest: 0.21.3 + + ansi-regex@5.0.1: {} + + ansi-styles@4.3.0: + dependencies: + color-convert: 2.0.1 + + chardet@0.7.0: {} + + cli-width@4.1.0: {} + + color-convert@2.0.1: + dependencies: + color-name: 1.1.4 + + color-name@1.1.4: {} + + commander@14.0.0: {} + + emoji-regex@8.0.0: {} + + external-editor@3.1.0: + dependencies: + chardet: 0.7.0 + iconv-lite: 0.4.24 + tmp: 0.0.33 + + iconv-lite@0.4.24: + dependencies: + safer-buffer: 2.1.2 + + is-fullwidth-code-point@3.0.0: {} + + mute-stream@2.0.0: {} + + os-tmpdir@1.0.2: {} + + safer-buffer@2.1.2: {} + + signal-exit@4.1.0: {} + + string-width@4.2.3: + dependencies: + emoji-regex: 8.0.0 + is-fullwidth-code-point: 3.0.0 + strip-ansi: 6.0.1 + + strip-ansi@6.0.1: + dependencies: + ansi-regex: 5.0.1 + + tmp@0.0.33: + dependencies: + os-tmpdir: 1.0.2 + + type-fest@0.21.3: {} + + typescript@5.9.2: {} + + undici-types@7.10.0: {} + + wrap-ansi@6.2.0: + dependencies: + ansi-styles: 4.3.0 + string-width: 4.2.3 + strip-ansi: 6.0.1 + + yoctocolors-cjs@2.1.2: {} diff --git a/src/cli/index.ts b/src/cli/index.ts new file mode 100644 index 00000000..ea324514 --- /dev/null +++ b/src/cli/index.ts @@ -0,0 +1,10 @@ +import { Command } from 'commander'; + +const program = new Command(); + +program + .name('openspec') + .description('AI-native system for spec-driven development') + .version('0.0.1'); + +program.parse(); \ No newline at end of file diff --git a/src/core/index.ts b/src/core/index.ts new file mode 100644 index 00000000..0f52581e --- /dev/null +++ b/src/core/index.ts @@ -0,0 +1,2 @@ +// Core OpenSpec logic will be implemented here +export {}; \ No newline at end of file diff --git a/src/index.ts b/src/index.ts new file mode 100644 index 00000000..9776fb47 --- /dev/null +++ b/src/index.ts @@ -0,0 +1,2 @@ +export * from './cli/index.js'; +export * from './core/index.js'; \ No newline at end of file diff --git a/src/utils/index.ts b/src/utils/index.ts new file mode 100644 index 00000000..b1cb3e64 --- /dev/null +++ b/src/utils/index.ts @@ -0,0 +1,2 @@ +// Shared utilities will be implemented here +export {}; \ No newline at end of file diff --git a/tsconfig.json b/tsconfig.json new file mode 100644 index 00000000..22ea0d27 --- /dev/null +++ b/tsconfig.json @@ -0,0 +1,21 @@ +{ + "compilerOptions": { + "target": "ES2022", + "module": "ESNext", + "lib": ["ES2022"], + "moduleResolution": "node", + "rootDir": "./src", + "outDir": "./dist", + "esModuleInterop": true, + "forceConsistentCasingInFileNames": true, + "strict": true, + "skipLibCheck": true, + "declaration": true, + "declarationMap": true, + "sourceMap": true, + "resolveJsonModule": true, + "allowSyntheticDefaultImports": true + }, + "include": ["src/**/*"], + "exclude": ["node_modules", "dist"] +} \ No newline at end of file