marceloxp/iartisan
最新稳定版本:0.2.0
Composer 安装命令:
composer require marceloxp/iartisan
包简介
IArtisan — Craft Artisan commands with AI-powered ease
README 文档
README
Craft Artisan commands with AI-powered ease
IArtisan is a command-line tool that uses the Google Gemini API to suggest php artisan commands for Laravel and Filament projects from natural language prompts.
✨ Features
- Natural language prompts: Describe what you want in plain English and get the exact
php artisancommand. - Smart version detection: Automatically detects Laravel and Filament versions from your
composer.json. - Filament support: Use
--f3,--f4,--f5or--f=Xto force a specific Filament version. - Automatic execution: If you're inside a Laravel project, you can confirm and run the command directly.
- Configurable AI model: Change Gemini model via
config:set. - Clean and simple CLI.
🚀 Installation
-
Install via Composer (recommended globally):
composer global require marceloxp/iartisan
-
Set up your Gemini API key:
export GEMINI_API_KEY=your-api-key-hereOr alternatively:
export IARTISAN_GEMINI_KEY=your-api-key-here -
Verify installation:
iartisan --help
🛠 Usage
Basic usage
iartisan create a model Post with migration and controller
Forcing Filament version
iartisan --f5 make a filament resource for User iartisan --f4 create a filament page for dashboard iartisan --f6 make a filament widget # future versions supported
Inside a Laravel project (auto-detection)
When a composer.json exists in the current directory, IArtisan automatically detects:
- Laravel version
- Filament version (if installed)
You can still override with --fX if needed.
Configuration
# Set custom Gemini model iartisan config:set GEMINI_MODEL=gemini-2.5-flash # Clear configuration iartisan config:clear gemini_model
📚 Examples
-
Basic Laravel
iartisan create a migration to add status column to users table
-
Filament 5
iartisan --f5 make a filament resource for Product -
Run migrations
iartisan run all pending migrations
📦 Requirements
- PHP 8.1+
- Composer
- Google Gemini API key
- (Optional) Laravel project for auto-detection and execution
🤝 Contributing
Contributions are welcome! Feel free to fork the repository and submit a pull request. Please follow PSR-12 coding standards.
📄 License
MIT — see LICENSE.
📬 Support
For issues or feature requests, please open an issue on the GitHub repository.
For questions, contact Marcelo at marceloxp@gmail.com.
统计信息
- 总下载量: 5
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2025-09-21
