定制 ascend/laravel-artisan-list-mine 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

ascend/laravel-artisan-list-mine

Composer 安装命令:

composer require ascend/laravel-artisan-list-mine

包简介

Filter laravel artisan commands to show only your application commands

README 文档

README

Latest Version on Packagist Tests Test Count PHP Version Laravel Version License

Ever used php artisan list to see what commands are available, or to remind yourself of a command's signature, but found yourself trawling through the long list of built-in Laravel commands? Easily filter them out by only showing your own artisan commands with php artisan list --mine.

Terminal screenshot

Installation

composer require ascend/laravel-artisan-list-mine

The package will automatically register itself via Laravel's package discovery.

Usage

Use the --mine flag with the list command to show only your application's commands:

php artisan list --mine

This filters out:

  • Built-in Laravel commands (make:*, migrate, etc.)
  • Commands from vendor packages
  • Any command not defined in your configured namespaces (default: App\)

Example Output

Laravel Framework 12.x

Usage:
  command [options] [arguments]

Options:
  ...
  --mine            Only show application commands (excludes vendor)
  ...

Available commands:
 app
  app:sync-data        Synchronize data from external API
  app:generate-report  Generate monthly reports
 orders
  orders:process       Process pending orders

Configuration

By default, commands in the App\ namespace are considered application commands. If your project uses additional namespaces (e.g., Domain\, Modules\), publish the config file:

php artisan vendor:publish --tag=artisan-list-mine-config

Then edit config/artisan-list-mine.php:

return [
    'namespaces' => [
        'App\\',
        'Domain\\',
        'Modules\\',
    ],
];

How It Works

The package identifies "application commands" by:

  1. Checking if the command class is in a configured namespace
  2. Checking if the command has a handler/action in a configured namespace (for closure-based or action-based commands)

Requirements

  • PHP 8.0+
  • Laravel 9.0+

Testing

composer test

License

MIT License. See LICENSE for more information.

统计信息

  • 总下载量: 859
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 1
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 1
  • Watchers: 0
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2026-02-26

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固