From 840a3f10e7e2a17ee6902fc3e190b92396fa6f9b Mon Sep 17 00:00:00 2001 From: Abd Shomad Date: Tue, 2 Sep 2025 22:36:14 +0700 Subject: [PATCH] feat: rename project from next-method to lazy-method and update package identity --- .next-context.json | 24 +++ README.md | 65 +++++--- package-lock.json | 321 +----------------------------------- package.json | 21 ++- tools/installer/bin/next.js | 204 ++++++++++++----------- 5 files changed, 188 insertions(+), 447 deletions(-) diff --git a/.next-context.json b/.next-context.json index e88e2bb7..6fcc9f0f 100644 --- a/.next-context.json +++ b/.next-context.json @@ -46,6 +46,30 @@ "status": "project_created" }, "phase": "start" + }, + { + "timestamp": "2025-09-02T15:32:16.356Z", + "action": "requirements", + "result": { + "status": "requirements_generated" + }, + "phase": "start" + }, + { + "timestamp": "2025-09-02T15:32:34.650Z", + "action": "architecture", + "result": { + "status": "architecture_designed" + }, + "phase": "start" + }, + { + "timestamp": "2025-09-02T15:32:37.448Z", + "action": "create", + "result": { + "status": "project_created" + }, + "phase": "start" } ], "metadata": {} diff --git a/README.md b/README.md index cb6f6c3b..80f06164 100644 --- a/README.md +++ b/README.md @@ -1,14 +1,14 @@ -# NEXT-METHOD™ +# LAZY-METHOD™ -**Next Method - Iterative AI-driven development with BMAD-METHOD™** +**LAZY-METHOD - Iterative AI-driven development with BMAD-METHOD™** -NEXT-METHOD is an intelligent wrapper around BMAD-METHOD that provides an iterative, guided development experience. Instead of manually choosing which tasks or commands to run, you simply type `next` repeatedly, and the system intelligently suggests and executes the next appropriate step. +LAZY-METHOD is an intelligent wrapper around BMAD-METHOD that provides an iterative, guided development experience. Instead of manually choosing which tasks or commands to run, you simply type `lazy` or `next` repeatedly, and the system intelligently suggests and executes the next appropriate step. -## 🧠 The Philosophy of "Next": Beyond Vanilla BMAD +## 🧠 The Philosophy of "LAZY-METHOD": Beyond Vanilla BMAD ### The Evolution from Method -The choice of "Next Method" over vanilla BMAD method represents a fundamental philosophical shift in how we approach AI-driven development. While BMAD (Brainstorming, Modeling, Analysis, and Development) provides a robust framework for systematic software creation, it operates within the traditional paradigm of explicit choice and conscious decision-making. +The choice of "LAZY-METHOD" over vanilla BMAD method represents a fundamental philosophical shift in how we approach AI-driven development. While BMAD (Brainstorming, Modeling, Analysis, and Development) provides a robust framework for systematic software creation, it operates within the traditional paradigm of explicit choice and conscious decision-making. ### The Paradox of Choice in Development @@ -22,9 +22,9 @@ Vanilla BMAD method, despite its sophistication, presents developers with what p - **Emergent Intelligence Arises**: The system's suggestions become more sophisticated as context accumulates, creating a form of collective intelligence - **Serendipity is Amplified**: Unexpected connections and insights emerge through the iterative process rather than upfront planning -### The Zen of "Just Next" +### The Zen of "Just Lazy/Next" -The name "Next" carries profound philosophical weight. It represents: +The commands "lazy" and "next" carry profound philosophical weight. They represent: 1. **Present-Moment Focus**: Unlike comprehensive planning that spans the entire project lifecycle, "Next" keeps us anchored in the current moment 2. **Trust in Emergence**: It embodies the belief that the right path reveals itself through iteration, not through exhaustive upfront analysis @@ -32,7 +32,7 @@ The name "Next" carries profound philosophical weight. It represents: ### Beyond Method: The Meta-Method -"Next Method" is not merely a method; it's a meta-method that transcends the traditional boundaries of development methodology. It represents: +"LAZY-METHOD" is not merely a method; it's a meta-method that transcends the traditional boundaries of development methodology. It represents: - **Methodological Evolution**: Moving from static frameworks to adaptive, context-aware systems - **Cognitive Enhancement**: Augmenting human decision-making rather than replacing it @@ -48,18 +48,18 @@ This approach is grounded in several philosophical traditions: ### Why Not Vanilla BMAD? -Vanilla BMAD method, while excellent, represents the culmination of 20th-century software engineering thinking - comprehensive, systematic, and deterministic. "Next Method" represents 21st-century thinking - adaptive, emergent, and contextually intelligent. +Vanilla BMAD method, while excellent, represents the culmination of 20th-century software engineering thinking - comprehensive, systematic, and deterministic. "LAZY-METHOD" represents 21st-century thinking - adaptive, emergent, and contextually intelligent. -The difference is not in capability but in philosophy: vanilla BMAD gives you all the tools and asks you to choose wisely; "Next Method" gives you the next tool and trusts that wisdom emerges through use. +The difference is not in capability but in philosophy: vanilla BMAD gives you all the tools and asks you to choose wisely; "LAZY-METHOD" gives you the next tool and trusts that wisdom emerges through use. ## 🚀 Quick Start ```bash -# Install NEXT-METHOD -npm install -g next-method +# Install LAZY-METHOD +npm install -g lazy-method # Or use npx -npx next-method install +npx lazy-method install # Initialize a new project start @@ -67,6 +67,8 @@ start init # Start the iterative development process +lazy +# or next ``` @@ -101,22 +103,25 @@ next --auto ## 📋 Available Commands ### Core Commands -- `start` or `init` - Initialize a new Next Method project or reset existing project -- `next` - Get next suggested action and execute it -- `next --auto` - Automatically execute the most logical next step -- `next --suggest` - Show all available next steps without executing -- `next status` - Show current project status and context -- `next reset` - Reset the Next Method context + +- `start` or `init` - Initialize a new LAZY-METHOD project or reset existing project +- `lazy` or `next` - Get next suggested action and execute it +- `lazy --auto` or `next --auto` - Automatically execute the most logical next step +- `lazy --suggest` or `next --suggest` - Show all available next steps without executing +- `lazy status` or `next status` - Show current project status and context +- `lazy reset` or `next reset` - Reset the LAZY-METHOD context ### BMAD-METHOD Wrappers + - `next install` - Install BMAD Method (wraps bmad install) - `next update` - Update existing BMAD installation (wraps bmad update) ### NPM Scripts -- `npm run start` or `npm run init` - Initialize a new Next Method project -- `npm run next` - Run the next command locally -- `npm run next:auto` - Auto-execute next step -- `npm run next:suggest` - Show suggestions only + +- `npm run start` or `npm run init` - Initialize a new LAZY-METHOD project +- `npm run lazy` or `npm run next` - Run the lazy/next command locally +- `npm run lazy:auto` or `npm run next:auto` - Auto-execute next step +- `npm run lazy:suggest` or `npm run next:suggest` - Show suggestions only ## 🏗️ Project Phases @@ -133,16 +138,19 @@ NEXT-METHOD guides you through these development phases: ## 🎯 Use Cases ### Greenfield Development + - Start with `next` to detect empty directory - Follow suggestions to create new project structure - Progress through requirements, architecture, and implementation ### Brownfield Development + - Start with `next` to analyze existing codebase - Get suggestions for improving or extending current project - Follow iterative improvement workflow ### Learning & Exploration + - Use `next --suggest` to see all available options - Understand the development workflow step by step - Learn BMAD-METHOD concepts through guided execution @@ -174,16 +182,19 @@ NEXT-METHOD creates a `.next-context.json` file in your project directory to mai ## 🚀 Getting Started 1. **Install NEXT-METHOD:** + ```bash npm install -g next-method ``` 2. **Navigate to your project directory:** + ```bash cd your-project ``` 3. **Initialize the project:** + ```bash start # or @@ -191,6 +202,7 @@ NEXT-METHOD creates a `.next-context.json` file in your project directory to mai ``` 4. **Start the iterative process:** + ```bash next ``` @@ -204,7 +216,8 @@ NEXT-METHOD creates a `.next-context.json` file in your project directory to mai ## 🔗 Integration with BMAD-METHOD -NEXT-METHOD is built on top of BMAD-METHOD and provides: +LAZY-METHOD is built on top of BMAD-METHOD and provides: + - All BMAD-METHOD features and capabilities - Intelligent workflow orchestration - Context-aware development guidance @@ -227,4 +240,6 @@ This project is licensed under the MIT License - see the [LICENSE](LICENSE) file --- -**NEXT-METHOD™** - Making AI-driven development as simple as typing "next" repeatedly! 🚀 +**LAZY-METHOD™** - Making AI-driven development as simple as typing "lazy" or "next" repeatedly! 🚀 + +> **Note**: Both `lazy` and `next` commands work identically - choose whichever feels more natural to you! diff --git a/package-lock.json b/package-lock.json index 94ee7020..ac039bc0 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,11 +1,11 @@ { - "name": "bmad-method", + "name": "lazy-method", "version": "4.42.2", "lockfileVersion": 3, "requires": true, "packages": { "": { - "name": "bmad-method", + "name": "lazy-method", "version": "4.42.2", "license": "MIT", "dependencies": { @@ -22,7 +22,9 @@ }, "bin": { "bmad": "tools/bmad-npx-wrapper.js", - "bmad-method": "tools/bmad-npx-wrapper.js" + "bmad-method": "tools/bmad-npx-wrapper.js", + "lazy": "tools/next-npx-wrapper.js", + "next": "tools/next-npx-wrapper.js" }, "devDependencies": { "@eslint/js": "^9.34.0", @@ -587,40 +589,6 @@ "node": ">=0.1.90" } }, - "node_modules/@emnapi/core": { - "version": "1.4.5", - "resolved": "https://registry.npmjs.org/@emnapi/core/-/core-1.4.5.tgz", - "integrity": "sha512-XsLw1dEOpkSX/WucdqUhPWP7hDxSvZiY+fsUC14h+FtQ2Ifni4znbBt8punRX+Uj2JG/uDb8nEHVKvrVlvdZ5Q==", - "dev": true, - "license": "MIT", - "optional": true, - "dependencies": { - "@emnapi/wasi-threads": "1.0.4", - "tslib": "^2.4.0" - } - }, - "node_modules/@emnapi/runtime": { - "version": "1.4.5", - "resolved": "https://registry.npmjs.org/@emnapi/runtime/-/runtime-1.4.5.tgz", - "integrity": "sha512-++LApOtY0pEEz1zrd9vy1/zXVaVJJ/EbAF3u0fXIzPJEDtnITsBGbbK0EkM72amhl/R5b+5xx0Y/QhcVOpuulg==", - "dev": true, - "license": "MIT", - "optional": true, - "dependencies": { - "tslib": "^2.4.0" - } - }, - "node_modules/@emnapi/wasi-threads": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/@emnapi/wasi-threads/-/wasi-threads-1.0.4.tgz", - "integrity": "sha512-PJR+bOmMOPH8AtcTGAyYNiuJ3/Fcoj2XN/gBEWzDIKh254XO+mM9XoXHk5GNEhodxeMznbg7BlRojVbKN+gC6g==", - "dev": true, - "license": "MIT", - "optional": true, - "dependencies": { - "tslib": "^2.4.0" - } - }, "node_modules/@eslint-community/eslint-utils": { "version": "4.7.0", "resolved": "https://registry.npmjs.org/@eslint-community/eslint-utils/-/eslint-utils-4.7.0.tgz", @@ -1552,19 +1520,6 @@ "url": "https://github.com/sponsors/ksylvan" } }, - "node_modules/@napi-rs/wasm-runtime": { - "version": "0.2.12", - "resolved": "https://registry.npmjs.org/@napi-rs/wasm-runtime/-/wasm-runtime-0.2.12.tgz", - "integrity": "sha512-ZVWUcfwY4E/yPitQJl481FjFo3K22D6qF0DuFH6Y/nbnE11GY5uguDxZMGXPQ8WQ0128MXQD7TnfHyK4oWoIJQ==", - "dev": true, - "license": "MIT", - "optional": true, - "dependencies": { - "@emnapi/core": "^1.4.3", - "@emnapi/runtime": "^1.4.3", - "@tybys/wasm-util": "^0.10.0" - } - }, "node_modules/@nodelib/fs.scandir": { "version": "2.1.5", "resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz", @@ -2363,17 +2318,6 @@ "@sinonjs/commons": "^3.0.1" } }, - "node_modules/@tybys/wasm-util": { - "version": "0.10.0", - "resolved": "https://registry.npmjs.org/@tybys/wasm-util/-/wasm-util-0.10.0.tgz", - "integrity": "sha512-VyyPYFlOMNylG45GoAe0xDoLwWuowvf92F9kySqzYh8vmYm7D2u4iUJKa1tOUpS70Ku13ASrOkS4ScXFsTaCNQ==", - "dev": true, - "license": "MIT", - "optional": true, - "dependencies": { - "tslib": "^2.4.0" - } - }, "node_modules/@types/babel__core": { "version": "7.20.5", "resolved": "https://registry.npmjs.org/@types/babel__core/-/babel__core-7.20.5.tgz", @@ -2537,34 +2481,6 @@ "dev": true, "license": "ISC" }, - "node_modules/@unrs/resolver-binding-android-arm-eabi": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-android-arm-eabi/-/resolver-binding-android-arm-eabi-1.11.1.tgz", - "integrity": "sha512-ppLRUgHVaGRWUx0R0Ut06Mjo9gBaBkg3v/8AxusGLhsIotbBLuRk51rAzqLC8gq6NyyAojEXglNjzf6R948DNw==", - "cpu": [ - "arm" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "android" - ] - }, - "node_modules/@unrs/resolver-binding-android-arm64": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-android-arm64/-/resolver-binding-android-arm64-1.11.1.tgz", - "integrity": "sha512-lCxkVtb4wp1v+EoN+HjIG9cIIzPkX5OtM03pQYkG+U5O/wL53LC4QbIeazgiKqluGeVEeBlZahHalCaBvU1a2g==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "android" - ] - }, "node_modules/@unrs/resolver-binding-darwin-arm64": { "version": "1.11.1", "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-darwin-arm64/-/resolver-binding-darwin-arm64-1.11.1.tgz", @@ -2579,233 +2495,6 @@ "darwin" ] }, - "node_modules/@unrs/resolver-binding-darwin-x64": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-darwin-x64/-/resolver-binding-darwin-x64-1.11.1.tgz", - "integrity": "sha512-cFzP7rWKd3lZaCsDze07QX1SC24lO8mPty9vdP+YVa3MGdVgPmFc59317b2ioXtgCMKGiCLxJ4HQs62oz6GfRQ==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "darwin" - ] - }, - "node_modules/@unrs/resolver-binding-freebsd-x64": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-freebsd-x64/-/resolver-binding-freebsd-x64-1.11.1.tgz", - "integrity": "sha512-fqtGgak3zX4DCB6PFpsH5+Kmt/8CIi4Bry4rb1ho6Av2QHTREM+47y282Uqiu3ZRF5IQioJQ5qWRV6jduA+iGw==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "freebsd" - ] - }, - "node_modules/@unrs/resolver-binding-linux-arm-gnueabihf": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-arm-gnueabihf/-/resolver-binding-linux-arm-gnueabihf-1.11.1.tgz", - "integrity": "sha512-u92mvlcYtp9MRKmP+ZvMmtPN34+/3lMHlyMj7wXJDeXxuM0Vgzz0+PPJNsro1m3IZPYChIkn944wW8TYgGKFHw==", - "cpu": [ - "arm" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@unrs/resolver-binding-linux-arm-musleabihf": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-arm-musleabihf/-/resolver-binding-linux-arm-musleabihf-1.11.1.tgz", - "integrity": "sha512-cINaoY2z7LVCrfHkIcmvj7osTOtm6VVT16b5oQdS4beibX2SYBwgYLmqhBjA1t51CarSaBuX5YNsWLjsqfW5Cw==", - "cpu": [ - "arm" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@unrs/resolver-binding-linux-arm64-gnu": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-arm64-gnu/-/resolver-binding-linux-arm64-gnu-1.11.1.tgz", - "integrity": "sha512-34gw7PjDGB9JgePJEmhEqBhWvCiiWCuXsL9hYphDF7crW7UgI05gyBAi6MF58uGcMOiOqSJ2ybEeCvHcq0BCmQ==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@unrs/resolver-binding-linux-arm64-musl": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-arm64-musl/-/resolver-binding-linux-arm64-musl-1.11.1.tgz", - "integrity": "sha512-RyMIx6Uf53hhOtJDIamSbTskA99sPHS96wxVE/bJtePJJtpdKGXO1wY90oRdXuYOGOTuqjT8ACccMc4K6QmT3w==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@unrs/resolver-binding-linux-ppc64-gnu": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-ppc64-gnu/-/resolver-binding-linux-ppc64-gnu-1.11.1.tgz", - "integrity": "sha512-D8Vae74A4/a+mZH0FbOkFJL9DSK2R6TFPC9M+jCWYia/q2einCubX10pecpDiTmkJVUH+y8K3BZClycD8nCShA==", - "cpu": [ - "ppc64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@unrs/resolver-binding-linux-riscv64-gnu": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-riscv64-gnu/-/resolver-binding-linux-riscv64-gnu-1.11.1.tgz", - "integrity": "sha512-frxL4OrzOWVVsOc96+V3aqTIQl1O2TjgExV4EKgRY09AJ9leZpEg8Ak9phadbuX0BA4k8U5qtvMSQQGGmaJqcQ==", - "cpu": [ - "riscv64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@unrs/resolver-binding-linux-riscv64-musl": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-riscv64-musl/-/resolver-binding-linux-riscv64-musl-1.11.1.tgz", - "integrity": "sha512-mJ5vuDaIZ+l/acv01sHoXfpnyrNKOk/3aDoEdLO/Xtn9HuZlDD6jKxHlkN8ZhWyLJsRBxfv9GYM2utQ1SChKew==", - "cpu": [ - "riscv64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@unrs/resolver-binding-linux-s390x-gnu": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-s390x-gnu/-/resolver-binding-linux-s390x-gnu-1.11.1.tgz", - "integrity": "sha512-kELo8ebBVtb9sA7rMe1Cph4QHreByhaZ2QEADd9NzIQsYNQpt9UkM9iqr2lhGr5afh885d/cB5QeTXSbZHTYPg==", - "cpu": [ - "s390x" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@unrs/resolver-binding-linux-x64-gnu": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-x64-gnu/-/resolver-binding-linux-x64-gnu-1.11.1.tgz", - "integrity": "sha512-C3ZAHugKgovV5YvAMsxhq0gtXuwESUKc5MhEtjBpLoHPLYM+iuwSj3lflFwK3DPm68660rZ7G8BMcwSro7hD5w==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@unrs/resolver-binding-linux-x64-musl": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-linux-x64-musl/-/resolver-binding-linux-x64-musl-1.11.1.tgz", - "integrity": "sha512-rV0YSoyhK2nZ4vEswT/QwqzqQXw5I6CjoaYMOX0TqBlWhojUf8P94mvI7nuJTeaCkkds3QE4+zS8Ko+GdXuZtA==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@unrs/resolver-binding-wasm32-wasi": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-wasm32-wasi/-/resolver-binding-wasm32-wasi-1.11.1.tgz", - "integrity": "sha512-5u4RkfxJm+Ng7IWgkzi3qrFOvLvQYnPBmjmZQ8+szTK/b31fQCnleNl1GgEt7nIsZRIf5PLhPwT0WM+q45x/UQ==", - "cpu": [ - "wasm32" - ], - "dev": true, - "license": "MIT", - "optional": true, - "dependencies": { - "@napi-rs/wasm-runtime": "^0.2.11" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "node_modules/@unrs/resolver-binding-win32-arm64-msvc": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-win32-arm64-msvc/-/resolver-binding-win32-arm64-msvc-1.11.1.tgz", - "integrity": "sha512-nRcz5Il4ln0kMhfL8S3hLkxI85BXs3o8EYoattsJNdsX4YUU89iOkVn7g0VHSRxFuVMdM4Q1jEpIId1Ihim/Uw==", - "cpu": [ - "arm64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "win32" - ] - }, - "node_modules/@unrs/resolver-binding-win32-ia32-msvc": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-win32-ia32-msvc/-/resolver-binding-win32-ia32-msvc-1.11.1.tgz", - "integrity": "sha512-DCEI6t5i1NmAZp6pFonpD5m7i6aFrpofcp4LA2i8IIq60Jyo28hamKBxNrZcyOwVOZkgsRp9O2sXWBWP8MnvIQ==", - "cpu": [ - "ia32" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "win32" - ] - }, - "node_modules/@unrs/resolver-binding-win32-x64-msvc": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-win32-x64-msvc/-/resolver-binding-win32-x64-msvc-1.11.1.tgz", - "integrity": "sha512-lrW200hZdbfRtztbygyaq/6jP6AKE8qQN2KvPcJ+x7wiD038YtnYtZ82IMNJ69GJibV7bwL3y9FgK+5w/pYt6g==", - "cpu": [ - "x64" - ], - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "win32" - ] - }, "node_modules/acorn": { "version": "8.15.0", "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.15.0.tgz", diff --git a/package.json b/package.json index 9ed06ce8..b13dfe8b 100644 --- a/package.json +++ b/package.json @@ -1,8 +1,8 @@ { "$schema": "https://json.schemastore.org/package.json", - "name": "@abdshomad/next-method", + "name": "lazy-method", "version": "4.42.2", - "description": "Next Method - Iterative AI-driven development with BMAD-METHOD™", + "description": "Lazy Method - Iterative AI-driven development with BMAD-METHOD™", "keywords": [ "agile", "ai", @@ -12,11 +12,12 @@ "agents", "bmad", "next", + "lazy", "iterative" ], "repository": { "type": "git", - "url": "git+https://github.com/abdshomad/NEXT-METHOD.git" + "url": "git+https://github.com/abdshomad/LAZY-METHOD.git" }, "license": "MIT", "author": "Brian (BMad) Madison", @@ -24,14 +25,10 @@ "bin": { "bmad": "tools/bmad-npx-wrapper.js", "bmad-method": "tools/bmad-npx-wrapper.js", + "lazy": "tools/next-npx-wrapper.js", "next": "tools/next-npx-wrapper.js" }, "scripts": { - "next": "node tools/installer/bin/next.js", - "next:auto": "node tools/installer/bin/next.js next --auto", - "next:suggest": "node tools/installer/bin/next.js next --suggest", - "start": "node tools/installer/bin/next.js start", - "init": "node tools/installer/bin/next.js start", "build": "node tools/cli.js build", "build:agents": "node tools/cli.js build --agents-only", "build:teams": "node tools/cli.js build --teams-only", @@ -39,10 +36,17 @@ "flatten": "node tools/flattener/main.js", "format": "prettier --write \"**/*.{js,cjs,mjs,json,md,yaml}\"", "format:check": "prettier --check \"**/*.{js,cjs,mjs,json,md,yaml}\"", + "init": "node tools/installer/bin/next.js start", "install:bmad": "node tools/installer/bin/bmad.js install", + "lazy": "node tools/installer/bin/next.js next", + "lazy:auto": "node tools/installer/bin/next.js next --auto", + "lazy:suggest": "node tools/installer/bin/next.js next --suggest", "lint": "eslint . --ext .js,.cjs,.mjs,.yaml --max-warnings=0", "lint:fix": "eslint . --ext .js,.cjs,.mjs,.yaml --fix", "list:agents": "node tools/cli.js list:agents", + "next": "node tools/installer/bin/next.js", + "next:auto": "node tools/installer/bin/next.js next --auto", + "next:suggest": "node tools/installer/bin/next.js next --suggest", "pre-release": "npm run validate && npm run format:check && npm run lint", "prepare": "husky", "preview:release": "node tools/preview-release-notes.js", @@ -51,6 +55,7 @@ "release:patch": "gh workflow run \"Manual Release\" -f version_bump=patch", "release:watch": "gh run watch", "setup:hooks": "chmod +x tools/setup-hooks.sh && ./tools/setup-hooks.sh", + "start": "node tools/installer/bin/next.js start", "validate": "node tools/cli.js validate", "version:all": "node tools/bump-all-versions.js", "version:all:major": "node tools/bump-all-versions.js major", diff --git a/tools/installer/bin/next.js b/tools/installer/bin/next.js index b26e0da5..e694ffbb 100644 --- a/tools/installer/bin/next.js +++ b/tools/installer/bin/next.js @@ -1,5 +1,3 @@ -#!/usr/bin/env node - const { program } = require('commander'); const path = require('node:path'); const fs = require('node:fs'); @@ -51,17 +49,17 @@ class NextMethodContext { const data = fs.readFileSync(this.contextFile, 'utf8'); return JSON.parse(data); } - } catch (error) { + } catch { console.log('Creating new context...'); } - + return { currentPhase: 'start', projectType: null, lastAction: null, suggestions: [], history: [], - metadata: {} + metadata: {}, }; } @@ -83,20 +81,20 @@ class NextMethodContext { timestamp: new Date().toISOString(), action, result, - phase: this.context.currentPhase + phase: this.context.currentPhase, }); this.saveContext(); } getNextSuggestions() { const suggestions = []; - + if (!this.context.projectType) { suggestions.push({ id: 'detect-project', title: 'Detect Project Type', description: 'Analyze current directory to determine project type', - action: 'detect' + action: 'detect', }); } @@ -105,7 +103,7 @@ class NextMethodContext { id: 'create-project', title: 'Create New Project', description: 'Start a new project from scratch', - action: 'create' + action: 'create', }); } @@ -114,7 +112,7 @@ class NextMethodContext { id: 'analyze-existing', title: 'Analyze Existing Project', description: 'Analyze current codebase and requirements', - action: 'analyze' + action: 'analyze', }); } @@ -123,7 +121,7 @@ class NextMethodContext { id: 'generate-requirements', title: 'Generate Requirements', description: 'Create user stories and requirements', - action: 'requirements' + action: 'requirements', }); } @@ -132,7 +130,7 @@ class NextMethodContext { id: 'design-architecture', title: 'Design Architecture', description: 'Create technical architecture and design', - action: 'architecture' + action: 'architecture', }); } @@ -141,7 +139,7 @@ class NextMethodContext { id: 'implement-features', title: 'Implement Features', description: 'Start coding and implementation', - action: 'implement' + action: 'implement', }); } @@ -150,7 +148,7 @@ class NextMethodContext { id: 'test-and-validate', title: 'Test and Validate', description: 'Run tests and validate implementation', - action: 'test' + action: 'test', }); } @@ -159,24 +157,25 @@ class NextMethodContext { id: 'deploy', title: 'Deploy', description: 'Deploy the application', - action: 'deploy' + action: 'deploy', }); } // Always show these options - suggestions.push({ - id: 'custom-command', - title: 'Run Custom Command', - description: 'Execute a specific BMAD command', - action: 'custom' - }); - - suggestions.push({ - id: 'show-status', - title: 'Show Project Status', - description: 'Display current project context and progress', - action: 'status' - }); + suggestions.push( + { + id: 'custom-command', + title: 'Run Custom Command', + description: 'Execute a specific BMAD command', + action: 'custom', + }, + { + id: 'show-status', + title: 'Show Project Status', + description: 'Display current project context and progress', + action: 'status', + }, + ); return suggestions; } @@ -186,7 +185,7 @@ const nextContext = new NextMethodContext(); program .version(version) - .description('Next Method - Iterative AI-driven development with BMAD-METHOD™'); + .description('Lazy Method - Iterative AI-driven development with BMAD-METHOD™'); program .command('next') @@ -196,7 +195,7 @@ program .action(async (options) => { try { const suggestions = nextContext.getNextSuggestions(); - + if (suggestions.length === 0) { console.log(chalk.green('🎉 Project completed! All phases finished.')); return; @@ -204,10 +203,10 @@ program if (options.suggest) { console.log(chalk.blue('\n📋 Available next steps:')); - suggestions.forEach((suggestion, index) => { + for (const [index, suggestion] of suggestions.entries()) { console.log(chalk.cyan(` ${index + 1}. ${suggestion.title}`)); console.log(chalk.gray(` ${suggestion.description}`)); - }); + } return; } @@ -221,11 +220,11 @@ program // Interactive mode console.log(chalk.blue('\n🚀 What would you like to do next?')); - + const choices = suggestions.map((suggestion, index) => ({ name: `${suggestion.title} - ${suggestion.description}`, value: suggestion.id, - short: suggestion.title + short: suggestion.title, })); const { selectedAction } = await inquirer.prompt([ @@ -234,15 +233,14 @@ program name: 'selectedAction', message: 'Choose the next step:', choices, - pageSize: 10 - } + pageSize: 10, + }, ]); - const suggestion = suggestions.find(s => s.id === selectedAction); + const suggestion = suggestions.find((s) => s.id === selectedAction); if (suggestion) { await executeSuggestion(suggestion); } - } catch (error) { console.error(chalk.red('Next command failed:'), error.message); process.exit(1); @@ -257,7 +255,7 @@ program .action(async (options) => { try { console.log(chalk.blue('🚀 Initializing Next Method project...')); - + // Check if project already exists if (nextContext.context.projectType && !options.force) { const { confirmReset } = await inquirer.prompt([ @@ -265,10 +263,10 @@ program type: 'confirm', name: 'confirmReset', message: 'Project already exists. Do you want to reset and start over?', - default: false - } + default: false, + }, ]); - + if (!confirmReset) { console.log(chalk.yellow('Project initialization cancelled.')); return; @@ -282,7 +280,7 @@ program lastAction: null, suggestions: [], history: [], - metadata: {} + metadata: {}, }); // Detect or set project type @@ -294,28 +292,27 @@ program // Update context with detected type nextContext.updateContext({ projectType }); - + // Add to history nextContext.addToHistory('start', { status: 'project_initialized', type: projectType, - timestamp: new Date().toISOString() + timestamp: new Date().toISOString(), }); console.log(chalk.green(`✅ Project initialized successfully!`)); console.log(chalk.cyan(` Project Type: ${projectType}`)); console.log(chalk.cyan(` Current Phase: start`)); - + // Show next suggestions const suggestions = nextContext.getNextSuggestions(); if (suggestions.length > 0) { console.log(chalk.blue('\n💡 Next suggested steps:')); - suggestions.slice(0, 3).forEach((s, index) => { + for (const [index, s] of suggestions.slice(0, 3).entries()) { console.log(chalk.cyan(` ${index + 1}. ${s.title}`)); - }); + } console.log(chalk.gray('\nRun "next" to continue or "next --suggest" to see all options')); } - } catch (error) { console.error(chalk.red('Project initialization failed:'), error.message); process.exit(1); @@ -330,7 +327,7 @@ program .action(async (options) => { try { console.log(chalk.blue('🚀 Initializing Next Method project...')); - + // Check if project already exists if (nextContext.context.projectType && !options.force) { const { confirmReset } = await inquirer.prompt([ @@ -338,10 +335,10 @@ program type: 'confirm', name: 'confirmReset', message: 'Project already exists. Do you want to reset and start over?', - default: false - } + default: false, + }, ]); - + if (!confirmReset) { console.log(chalk.yellow('Project initialization cancelled.')); return; @@ -355,7 +352,7 @@ program lastAction: null, suggestions: [], history: [], - metadata: {} + metadata: {}, }); // Detect or set project type @@ -367,28 +364,27 @@ program // Update context with detected type nextContext.updateContext({ projectType }); - + // Add to history nextContext.addToHistory('start', { status: 'project_initialized', type: projectType, - timestamp: new Date().toISOString() + timestamp: new Date().toISOString(), }); console.log(chalk.green(`✅ Project initialized successfully!`)); console.log(chalk.cyan(` Project Type: ${projectType}`)); console.log(chalk.cyan(` Current Phase: start`)); - + // Show next suggestions const suggestions = nextContext.getNextSuggestions(); if (suggestions.length > 0) { console.log(chalk.blue('\n💡 Next suggested steps:')); - suggestions.slice(0, 3).forEach((s, index) => { + for (const [index, s] of suggestions.slice(0, 3).entries()) { console.log(chalk.cyan(` ${index + 1}. ${s.title}`)); - }); + } console.log(chalk.gray('\nRun "next" to continue or "next --suggest" to see all options')); } - } catch (error) { console.error(chalk.red('Project initialization failed:'), error.message); process.exit(1); @@ -397,61 +393,71 @@ program async function executeSuggestion(suggestion) { console.log(chalk.green(`\n▶️ Executing: ${suggestion.title}`)); - + try { let result; - + switch (suggestion.action) { - case 'detect': + case 'detect': { result = await detectProjectType(); break; - case 'create': + } + case 'create': { result = await createProject(); break; - case 'analyze': + } + case 'analyze': { result = await analyzeProject(); break; - case 'requirements': + } + case 'requirements': { result = await generateRequirements(); break; - case 'architecture': + } + case 'architecture': { result = await designArchitecture(); break; - case 'implement': + } + case 'implement': { result = await implementFeatures(); break; - case 'test': + } + case 'test': { result = await testAndValidate(); break; - case 'deploy': + } + case 'deploy': { result = await deployProject(); break; - case 'custom': + } + case 'custom': { result = await runCustomCommand(); break; - case 'status': + } + case 'status': { result = await showStatus(); break; - default: + } + default: { console.log(chalk.yellow(`Unknown action: ${suggestion.action}`)); return; + } } nextContext.addToHistory(suggestion.action, result); nextContext.updateContext({ lastAction: suggestion.action }); - + console.log(chalk.green(`✅ ${suggestion.title} completed successfully!`)); - + // Show next suggestions const nextSuggestions = nextContext.getNextSuggestions(); if (nextSuggestions.length > 0) { console.log(chalk.blue('\n💡 Next suggested steps:')); - nextSuggestions.slice(0, 3).forEach((s, index) => { + for (const [index, s] of nextSuggestions.slice(0, 3).entries()) { console.log(chalk.cyan(` ${index + 1}. ${s.title}`)); - }); + } console.log(chalk.gray('\nRun "next" to continue or "next --suggest" to see all options')); } - } catch (error) { console.error(chalk.red(`❌ ${suggestion.title} failed:`), error.message); nextContext.addToHistory(suggestion.action, { error: error.message }); @@ -463,8 +469,10 @@ async function detectProjectType() { const files = await fsPromises.readdir(process.cwd()); const hasPackageJson = files.includes('package.json'); const hasGit = files.includes('.git'); - const hasSourceFiles = files.some(f => f.endsWith('.js') || f.endsWith('.ts') || f.endsWith('.py') || f.endsWith('.java')); - + const hasSourceFiles = files.some( + (f) => f.endsWith('.js') || f.endsWith('.ts') || f.endsWith('.py') || f.endsWith('.java'), + ); + let projectType = 'empty'; if (hasSourceFiles && hasPackageJson) { projectType = 'brownfield'; @@ -473,13 +481,13 @@ async function detectProjectType() { } else if (hasGit || hasSourceFiles) { projectType = 'greenfield'; } - + nextContext.updateContext({ projectType }); - + return { type: projectType, detectedType: projectType, - files: files.filter(f => !f.startsWith('.') && !f.includes('node_modules')) + files: files.filter((f) => !f.startsWith('.') && !f.includes('node_modules')), }; } @@ -531,10 +539,10 @@ async function runCustomCommand() { type: 'input', name: 'command', message: 'Enter BMAD command to execute:', - default: 'bmad install' - } + default: 'bmad install', + }, ]); - + console.log(chalk.blue(`Executing: ${command}`)); // This would execute the BMAD command return { command, status: 'executed' }; @@ -545,15 +553,15 @@ async function showStatus() { console.log(chalk.cyan(` Current Phase: ${nextContext.context.currentPhase}`)); console.log(chalk.cyan(` Project Type: ${nextContext.context.projectType || 'Not determined'}`)); console.log(chalk.cyan(` Last Action: ${nextContext.context.lastAction || 'None'}`)); - + if (nextContext.context.history.length > 0) { console.log(chalk.blue('\n📝 Recent Actions:')); - nextContext.context.history.slice(-5).forEach((entry, index) => { + for (const [index, entry] of nextContext.context.history.slice(-5).entries()) { const status = entry.result?.error ? '❌' : '✅'; console.log(chalk.gray(` ${status} ${entry.action} (${entry.timestamp})`)); - }); + } } - + return { status: 'status_displayed' }; } @@ -569,11 +577,11 @@ program .action(async (options) => { try { // Forward to BMAD installer - const { execSync } = require('child_process'); + const { execSync } = require('node:child_process'); const args = process.argv.slice(3).join(' '); execSync(`node "${path.join(__dirname, 'bmad.js')}" install ${args}`, { stdio: 'inherit', - cwd: process.cwd() + cwd: process.cwd(), }); } catch (error) { console.error(chalk.red('Installation failed:'), error.message); @@ -588,11 +596,11 @@ program .option('--dry-run', 'Show what would be updated without making changes') .action(async (options) => { try { - const { execSync } = require('child_process'); + const { execSync } = require('node:child_process'); const args = process.argv.slice(3).join(' '); execSync(`node "${path.join(__dirname, 'bmad.js')}" update ${args}`, { stdio: 'inherit', - cwd: process.cwd() + cwd: process.cwd(), }); } catch (error) { console.error(chalk.red('Update failed:'), error.message); @@ -616,16 +624,16 @@ program type: 'confirm', name: 'confirm', message: 'Are you sure you want to reset the Next Method context?', - default: false - } + default: false, + }, ]); - + if (confirm) { try { fs.unlinkSync(nextContext.contextFile); nextContext.context = nextContext.loadContext(); console.log(chalk.green('✅ Context reset successfully!')); - } catch (error) { + } catch { console.log(chalk.blue('Context file not found, already reset.')); } }