{"id":37013564,"url":"https://github.com/whilesmartphp/laravel-plugin-engine","last_synced_at":"2026-01-14T01:20:13.860Z","repository":{"id":299493438,"uuid":"1003215975","full_name":"whilesmartphp/laravel-plugin-engine","owner":"whilesmartphp","description":"A flexible and powerful plugin system for Laravel applications.","archived":false,"fork":false,"pushed_at":"2025-10-02T19:58:41.000Z","size":75,"stargazers_count":0,"open_issues_count":5,"forks_count":0,"subscribers_count":0,"default_branch":"dev","last_synced_at":"2025-10-02T20:14:52.800Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/whilesmartphp.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-06-16T20:01:03.000Z","updated_at":"2025-10-02T19:57:08.000Z","dependencies_parsed_at":"2025-06-16T21:24:36.527Z","dependency_job_id":"db63d03b-3a37-4028-8ddc-83f3c8bba977","html_url":"https://github.com/whilesmartphp/laravel-plugin-engine","commit_stats":null,"previous_names":["whilesmart/laravel-plugin-engine","whilesmartphp/laravel-plugin-engine"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/whilesmartphp/laravel-plugin-engine","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/whilesmartphp%2Flaravel-plugin-engine","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/whilesmartphp%2Flaravel-plugin-engine/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/whilesmartphp%2Flaravel-plugin-engine/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/whilesmartphp%2Flaravel-plugin-engine/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/whilesmartphp","download_url":"https://codeload.github.com/whilesmartphp/laravel-plugin-engine/tar.gz/refs/heads/dev","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/whilesmartphp%2Flaravel-plugin-engine/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28407673,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-14T00:40:43.272Z","status":"ssl_error","status_checked_at":"2026-01-14T00:40:42.636Z","response_time":56,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2026-01-14T01:20:13.089Z","updated_at":"2026-01-14T01:20:13.836Z","avatar_url":"https://github.com/whilesmartphp.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Laravel Plugin Engine\n\n[![Tests](https://github.com/whilesmart/laravel-plugin-engine/actions/workflows/tests.yml/badge.svg?branch=main)](https://github.com/whilesmart/laravel-plugin-engine/actions/workflows/tests.yml)\n[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](LICENSE)\n\nA flexible and powerful plugin system for Laravel applications.\n\n## Features\n\n- Plugin discovery and registration\n- Enable/disable plugins\n- Plugin dependencies\n- Console commands for plugin management\n- Event-driven architecture\n- Easy to extend\n\n## Installation\n\n1. Install the package via Composer:\n\n```bash\ncomposer require whilesmart/laravel-plugin-engine\n```\n\n2. Publish the configuration file (optional):\n\n```bash\nphp artisan vendor:publish --provider=\"WhileSmart\\LaravelPluginEngine\\Providers\\PluginServiceProvider\" --tag=config\n```\n\n## Configuration\n\nPublish the configuration file:\n\n```bash\nphp artisan vendor:publish --provider=\"WhileSmart\\LaravelPluginEngine\\Providers\\PluginServiceProvider\" --tag=config\n```\n\nEdit the `config/plugins.php` file to configure the plugin system:\n\n```php\nreturn [\n    'path' =\u003e base_path('plugins'),  // Path where plugins are stored\n    'namespace' =\u003e 'Plugins',        // Root namespace for plugins\n];\n```\n\n## Usage\n\n### Available Commands\n\n- `plugin:list` - List all available plugins\n- `plugin:info {id}` - Show information about a plugin\n- `plugin:enable {id}` - Enable a plugin\n- `plugin:disable {id}` - Disable a plugin\n- `plugin:install {package}` - Install a plugin\n- `plugin:discover` - Discover and register all available plugins\n\n### Creating a Plugin\n\n1. Create a new directory in the `plugins` directory (or your configured path)\n2. Create a `plugin.json` file with the following structure:\n\n```json\n{\n    \"id\": \"example-plugin\",\n    \"name\": \"Example Plugin\",\n    \"description\": \"A sample plugin\",\n    \"version\": \"1.0.0\",\n    \"namespace\": \"Plugins\\\\Example\",\n    \"provider\": \"Plugins\\\\Example\\\\ExampleServiceProvider\",\n    \"enabled\": true,\n    \"requires\": {\n        \"php\": \"\u003e=8.1\",\n        \"laravel/framework\": \"^10.0\"\n    }\n}\n```\n\n3. Create a service provider for your plugin:\n\n```php\n\u003c?php\n\nnamespace Plugins\\Example;\n\nuse Illuminate\\Support\\ServiceProvider;\n\nclass ExampleServiceProvider extends ServiceProvider\n{\n    public function register()\n    {\n        // Register bindings\n    }\n\n    public function boot()\n    {\n        // Boot logic\n        $this-\u003eloadRoutesFrom(__DIR__.'/routes/web.php');\n        $this-\u003eloadViewsFrom(__DIR__.'/resources/views', 'example');\n        $this-\u003eloadMigrationsFrom(__DIR__.'/database/migrations');\n    }\n}\n```\n\n## Plugin Structure\n\n```\nplugins/\n  example-plugin/\n    src/\n      Http/\n        Controllers/\n      Models/\n      Providers/\n        ExampleServiceProvider.php\n    resources/\n      views/\n    routes/\n      web.php\n    database/\n      migrations/\n    plugin.json\n    README.md\n```\n\n## Events\n\nThe plugin system dispatches several events that you can listen for:\n\n- `WhileSmart\\PluginEngine\\Events\\PluginEnabling` - Fired before a plugin is enabled\n- `WhileSmart\\PluginEngine\\Events\\PluginEnabled` - Fired after a plugin is enabled\n- `WhileSmart\\PluginEngine\\Events\\PluginDisabling` - Fired before a plugin is disabled\n- `WhileSmart\\PluginEngine\\Events\\PluginDisabled` - Fired after a plugin is disabled\n- `WhileSmart\\PluginEngine\\Events\\PluginInstalled` - Fired after a plugin is installed\n- `WhileSmart\\PluginEngine\\Events\\PluginDiscovered` - Fired when a plugin is discovered\n\n## License\n\nThis project is open-source and licensed under the [MIT License](./LICENSE). \n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwhilesmartphp%2Flaravel-plugin-engine","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwhilesmartphp%2Flaravel-plugin-engine","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwhilesmartphp%2Flaravel-plugin-engine/lists"}