{"_id":"@chanchi/cli","name":"@chanchi/cli","dist-tags":{"latest":"1.1.1"},"versions":{"1.1.1":{"name":"@chanchi/cli","version":"1.1.1","description":"CLI for Chi","type":"module","repository":{"type":"git","url":"git+https://github.com/navelorange1999/chi-dev-cli.git"},"bugs":{"url":"https://github.com/navelorange1999/chi-dev-cli/issues"},"homepage":"https://github.com/navelorange1999/chi-dev-cli#readme","main":"dist/cli.js","bin":{"chi":"dist/cli.js"},"scripts":{"dev":"tsx src/cli.ts","build":"tsup","start":"node dist/cli.js","cz":"bunx cz","prepublishOnly":"npm run build","prepare":"husky install","test":"echo \"Error: no test specified\" && exit 1"},"keywords":["cli"],"author":{"name":"navelorange1999"},"publishConfig":{"access":"public"},"packageManager":"bun@1.1.45","dependencies":{"chalk":"^5.3.0","commander":"^12.1.0","fs-extra":"^11.2.0","inquirer":"^10.2.2","ora":"^8.1.1"},"devDependencies":{"@commitlint/cli":"^19.6.0","@commitlint/cz-commitlint":"^19.6.0","@commitlint/config-conventional":"^19.6.0","@types/fs-extra":"^11.0.4","@types/inquirer":"^9.0.7","@types/node":"^22.10.2","@typescript-eslint/eslint-plugin":"^8.18.2","@typescript-eslint/parser":"^8.18.2","commitizen":"^4.3.1","eslint":"^9.17.0","husky":"^9.1.7","nodemon":"^3.1.9","tsup":"^8.3.5","tsx":"^4.19.2","typescript":"^5.7.2"},"config":{"commitizen":{"path":"@commitlint/cz-commitlint"}},"_id":"@chanchi/cli@1.1.1","gitHead":"0404fc26b6fd549b605fa0ad330c30d1dbd84f0e","_nodeVersion":"18.20.8","_npmVersion":"10.8.2","dist":{"integrity":"sha512-R24H33XooZzIYdTFH5qBzl0qpAFJf0KDlZvKqvUFRDAETcqVP6E1RY/v3Ac3SLlxF0zii/0cBhqwg5SVTEaxbw==","shasum":"b5c77e119b9253159fdeb79edd88a4f6eec67e3e","tarball":"https://registry.npmjs.org/@chanchi/cli/-/cli-1.1.1.tgz","fileCount":26,"unpackedSize":205632,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIB7sPg5G0PAfJMrxc4bgr3ivEon805KNarNTxeQUoJhZAiEAjDrbFtAPlXHRhAav3mA2x98azbLB3gCjr5ToMvf6O3I="}]},"_npmUser":{"name":"navelorange1999","email":"navelorange1999@gmail.com"},"directories":{},"maintainers":[{"name":"navelorange1999","email":"navelorange1999@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/cli_1.1.1_1768535509831_0.4824186532770276"},"_hasShrinkwrap":false}},"time":{"created":"2026-01-16T03:51:49.771Z","1.1.1":"2026-01-16T03:51:49.975Z","modified":"2026-01-16T03:51:50.195Z"},"maintainers":[{"name":"navelorange1999","email":"navelorange1999@gmail.com"}],"description":"CLI for Chi","homepage":"https://github.com/navelorange1999/chi-dev-cli#readme","keywords":["cli"],"repository":{"type":"git","url":"git+https://github.com/navelorange1999/chi-dev-cli.git"},"author":{"name":"navelorange1999"},"bugs":{"url":"https://github.com/navelorange1999/chi-dev-cli/issues"},"readme":"# Chi CLI\n\nA powerful command-line tool for quickly initializing modern web projects with your preferred tech stack.\n\n## Features\n\n- 🚀 **Interactive Setup**: Step-by-step interactive prompts to configure your project\n- 📦 **Multiple Package Managers**: Support for npm, yarn, pnpm, and bun\n- ⚛️ **Framework Support**: React, Vue, Next.js, and Astro\n- 🎨 **CSS Tools**: Tailwind CSS, SCSS, or plain CSS\n- 📝 **TypeScript/JavaScript**: Choose your preferred language\n- 🔧 **Code Quality**: Optional ESLint and Prettier configuration\n- 🔄 **Git Integration**: Automatic Git repository initialization\n\n## Installation\n\n### Global Installation\n\n```bash\nnpm install -g @chanchi/cli\n# or\nyarn global add @chanchi/cli\n# or\npnpm add -g @chanchi/cli\n# or\nbun install -g @chanchi/cli\n```\n\n### Local Development\n\n```bash\n# Clone the repository\ngit clone <repository-url>\ncd chi-dev-cli\n\n# Install dependencies (recommended)\nbun install --frozen-lockfile\n\n# Build the project\nbun run build\n```\n\n## Usage\n\n### Initialize a New Project\n\n```bash\nchi init [project-name]\n```\n\nIf you don't provide a project name, you'll be prompted to enter one.\n\n### Interactive Prompts\n\nThe CLI will guide you through the following steps:\n\n1. **Project Name**: Enter your project name (if not provided as argument)\n2. **Package Manager**: Choose from npm, yarn, pnpm, or bun\n3. **Framework**: Select React, Vue, Next.js, or Astro\n4. **CSS Tool**: Choose Tailwind CSS, SCSS, or plain CSS\n5. **Language**: Select TypeScript or JavaScript\n6. **ESLint**: Choose whether to include ESLint configuration\n7. **Prettier**: Choose whether to include Prettier configuration\n\n### Example\n\n```bash\n$ chi init my-awesome-project\n\n✨ Starting project initialization...\n\n? Select package manager: pnpm\n? Select framework: Next.js\n? Select CSS tool: Tailwind CSS\n? Select language: TypeScript\n? Do you need ESLint? Yes\n? Do you need Prettier? Yes\n\n✅ Project initialized successfully!\n\n📝 Next steps:\n   cd my-awesome-project\n   pnpm install\n   pnpm dev\n```\n\n## Supported Technologies\n\n### Package Managers\n- npm\n- yarn\n- pnpm\n- bun\n\n### Frameworks\n- **React**: With Vite\n- **Vue**: With Vite\n- **Next.js**: Full Next.js setup\n- **Astro**: Astro project structure\n\n### CSS Tools\n- **Tailwind CSS**: With PostCSS and Autoprefixer\n- **SCSS**: Sass/SCSS support\n- **CSS**: Plain CSS\n\n### Languages\n- TypeScript\n- JavaScript\n\n### Code Quality Tools\n- ESLint (optional)\n- Prettier (optional)\n\n## Development\n\n### Prerequisites\n\n- Node.js 18+\n- Bun (recommended)\n\n### Scripts\n\n```bash\n# Install deps\nbun install --frozen-lockfile\n\n# Development mode (runs TypeScript directly)\nbun run dev\n\n# Build for production\nbun run build\n\n# Run built version\nbun run start\n```\n\n### Release / Publish (Maintainers)\n\nThis repo uses **release-please** to manage versions/tags/GitHub Releases, and a separate workflow to publish to **npm** automatically.\n\n**How it works**\n\n1. Every push to `master` updates/creates a **Release PR** (via GitHub Actions).\n2. Merging the Release PR will:\n    - bump `package.json` version\n    - update changelog content in the PR\n    - create a git tag (usually `vX.Y.Z`)\n    - create a GitHub Release\n3. When the GitHub Release is **published**, another workflow builds with Bun and runs `npm publish`.\n\n**Requirements**\n\n- GitHub repo secret: `NPM_TOKEN`\n   - Create an npm **Automation token** and add it at: GitHub repo → Settings → Secrets and variables → Actions → New repository secret\n\n**Commit message convention (recommended)**\n\nrelease-please expects **Conventional Commits** to decide version bumps. For example:\n\n- `feat: add new init option` (minor)\n- `fix: handle empty project name` (patch)\n- `feat!: change default template` (major)\n\nNote: the repo currently bootstraps release-please from a specific commit (see `.release-please-config.json`) to avoid parsing the older, non-conventional history.\n\n### Project Structure\n\n### Project Structure\n\n```\nchi-dev-cli/\n├── src/\n│   ├── cli.ts                  # Main CLI entry point\n│   ├── commands/\n│   │   └── init.ts              # Init command implementation\n│   └── utils/\n│       ├── prompts.ts           # Interactive prompts\n│       ├── configGenerators.ts  # Configuration file generators\n│       └── projectGenerator.ts  # Main project generator\n├── templates/                   # Project templates\n├── dist/                      # Build output\n├── tsconfig.json              # TypeScript configuration\n├── tsup.config.ts             # Build configuration\n└── package.json\n```\n\n## How It Works\n\n1. **Prompts**: The CLI uses `inquirer` to collect user preferences\n2. **Configuration Generation**: Based on selections, generates:\n   - `package.json` with appropriate dependencies\n   - Framework-specific configuration files\n   - TypeScript configuration (if selected)\n   - CSS tool configuration (Tailwind/SCSS)\n   - ESLint and Prettier configs (if selected)\n3. **Template Generation**: Creates starter files based on the selected framework\n4. **Git Initialization**: Automatically initializes a Git repository\n\n## Generated Project Structure\n\nThe CLI generates a complete project structure based on your selections:\n\n- **React/Vue**: Vite-based setup with proper entry points\n- **Next.js**: App Router structure with layout and pages\n- **Astro**: Astro pages structure\n\nAll projects include:\n- Proper configuration files\n- Starter component/page files\n- CSS setup based on your choice\n- `.gitignore` file\n- `README.md` with setup instructions\n\n## Contributing\n\nContributions are welcome! Please feel free to submit a Pull Request.\n\n### Commit Message Policy\n\nThis repo enforces **Conventional Commits** via:\n\n- a local git hook (Husky + commitlint)\n- a GitHub Action check on Pull Requests\n\nIf your PR check fails, rename/squash commits to follow the format (e.g. `feat: ...`, `fix: ...`, `chore: ...`).\n\n## License\n\nMIT\n\n## Author\n\nnavelorange1999\n\n\n","readmeFilename":"README.md","_rev":"1-3ee769d626013eafa9deee30a12a4da4"}