codizium-cli
Version:
A CLI tool to scaffold Laravel and Node-based modules with ease.
170 lines (114 loc) โข 3.9 kB
Markdown
# Codizium CLI
____ _ _ _
/ ___| ___ __| | (_) ____ (_) _ _ _ __ ___
| | / _ \ / _` | | | |_ / | | | | | | | '_ ` _ \
| |___ | (_) | | (_| | | | / / | | | |_| | | | | | | |
\____| \___/ \__,_| |_| /___| |_| \__,_| |_| |_| |_|
Codizium CLI Toolkit
<!--  -->
> A powerful CLI tool to scaffold Laravel, Node.js, or Next.js module structures effortlessly.
---
## โจ Features
- ๐ง Generate Laravel modules with full structure
- โ๏ธ Scaffold classes like Controllers, Models, Enums, Services, Requests, etc.
- ๐ฏ Supports modular and non-modular workspaces
- ๐ Directory-aware logic for intelligent file placement
- ๐ง Designed for developer speed and productivity
---
## ๐ฆ Installation
Install globally via [NPM](https://www.npmjs.com/package/codizium-cli):
```bash
npm install -g codizium-cli
```
---
## ๐ Usage
### 1. Generate a Laravel Module
```bash
codizium-cli laravel -t module -n blog
```
```bash
codizium-cli nextjs -t module -n blog
```
```bash
codizium-cli nodejs -t module -n blog
```
### 2. Generate a Controller Inside a Module
```bash
cd blog
codizium-cli generate:[laravel|nodejs|nextjs] -t controller -n PostController
```
### 3. Generate a Model Outside Module (standalone)
```bash
codizium-cli generate:[laravel|nodejs|nextjs] -t model -n User --path ./src
```
### 4. All Supported Types
| Type | Flag | Description |
|-------------|-------------|------------------------------------|
| module | `-t module` | Creates a new Laravel module |
| controller | `-t controller` | Creates a controller class |
| model | `-t model` | Creates a model class |
| enum | `-t enum` | Creates a PHP `enum` class |
| service | `-t service`| Creates a service class |
| request | `-t request`| Creates a Laravel FormRequest |
---
## ๐ง Command Options
```bash
codizium-cli [laravel|nextjs|nodejs] -t <type> -n <name> [--module <moduleName>] [--path <targetPath>]
```
- `-t, --type`: Component type (e.g. module, controller)
- `-n, --name`: Component name (e.g. User, PostController)
- `--module`: Optional. Uses existing module structure
- `--path`: Optional. Overrides default path (defaults to current dir)
---
## ๐ Directory Output
Example for `laravel -t module -n blog`:
```
blog/
โโโ composer.json
โโโ routes/
โ โโโ web.php
โโโ src/
โ โโโ Controllers/
โ โโโ Models/
โ โโโ Requests/
โ โโโ Providers/
โ โโโ ...
```
---
## ๐งช Testing
You can simulate tests using local `npm link`:
```bash
npm link
codizium-cli generate:[laravel|nodejs|nextjs] -t controller -n TestController
```
### โ
Planned Test Automation (coming soon)
- Unit tests using `vitest` or `jest`
- CLI integration tests
- Snapshot testing for file output
---
## ๐จโ๐ป Development
Clone and run locally:
```bash
git clone https://github.com/codizium/codizium-cli.git
cd codizium-cli
npm install
npm link
```
---
## ๐ ๏ธ Dependencies
- [commander](https://www.npmjs.com/package/commander)
- [chalk](https://www.npmjs.com/package/chalk)
- [figlet](https://www.npmjs.com/package/figlet)
- [ora](https://www.npmjs.com/package/ora)
---
## ๐ฃ Contributing
Contributions are welcome!
Please open an issue or submit a pull request.
---
## ๐ License
[ISC](./LICENSE) ยฉ 2025 [Rapha Panchi](https://github.com/ralphxp)
Built with โค๏ธ by [Codizium Innovative Technologies](https://github.com/codizium)
---
## ๐ Related
- [Laravel Module Generator](https://github.com/nWidart/laravel-modules)
- [Codizium GitHub](https://github.com/codizium)