{"id":16576526,"url":"https://github.com/ipunkt/laravel-package-manager","last_synced_at":"2026-04-21T09:31:31.245Z","repository":{"id":56971035,"uuid":"74980146","full_name":"ipunkt/laravel-package-manager","owner":"ipunkt","description":"Provides more comfort in using and developing php laravel packages","archived":false,"fork":false,"pushed_at":"2020-09-27T16:06:40.000Z","size":31,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-05-07T12:45:56.448Z","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/ipunkt.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-11-28T14:20:28.000Z","updated_at":"2025-04-10T21:32:00.000Z","dependencies_parsed_at":"2022-08-21T10:50:53.422Z","dependency_job_id":null,"html_url":"https://github.com/ipunkt/laravel-package-manager","commit_stats":null,"previous_names":[],"tags_count":10,"template":false,"template_full_name":null,"purl":"pkg:github/ipunkt/laravel-package-manager","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ipunkt%2Flaravel-package-manager","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ipunkt%2Flaravel-package-manager/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ipunkt%2Flaravel-package-manager/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ipunkt%2Flaravel-package-manager/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ipunkt","download_url":"https://codeload.github.com/ipunkt/laravel-package-manager/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ipunkt%2Flaravel-package-manager/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32085409,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-21T06:27:27.065Z","status":"ssl_error","status_checked_at":"2026-04-21T06:27:21.250Z","response_time":128,"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":"2024-10-11T22:08:27.255Z","updated_at":"2026-04-21T09:31:31.181Z","avatar_url":"https://github.com/ipunkt.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Package Manager\n\n[![Total Downloads](https://poser.pugx.org/ipunkt/laravel-package-manager/d/total.svg)](https://packagist.org/packages/ipunkt/laravel-package-manager)\n[![Latest Stable Version](https://poser.pugx.org/ipunkt/laravel-package-manager/v/stable.svg)](https://packagist.org/packages/ipunkt/laravel-package-manager)\n[![Latest Unstable Version](https://poser.pugx.org/ipunkt/laravel-package-manager/v/unstable.svg)](https://packagist.org/packages/ipunkt/laravel-package-manager)\n[![License](https://poser.pugx.org/ipunkt/laravel-package-manager/license.svg)](https://packagist.org/packages/ipunkt/laravel-package-manager)\n\n## Introduction\n\nPackage Manager helps reducing the package creation time. Therefore it supports some basic providers for laravel packages.\n\nThis package plays nicely with the [laravel plugin seeder package](https://github.com/ipunkt/laravel-package).\n\nJust create a new plugin with `composer create-package ipunkt/laravel-package YOUR-PACKAGE-NAME` and you are able to start with all the package manager supports out of the box.\n\n## Installation\n\nAdd this package as dependency by using `composer require ipunkt/laravel-package-manager:^1.0`\n\n\n## Usage\n\nWe suggest using a Package Service Provider extending the `Illuminate\\Support\\AggregateServiceProvider` and register all your package related providers as attribute like so:\n\n```php\n\u003c?php\n\nnamespace MyPackage\\Providers;\n\nuse Illuminate\\Support\\AggregateServiceProvider;\n\nclass MyPackageServiceProvider extends AggregateServiceProvider\n{\n\t/**\n\t * The provider class names.\n\t *\n\t * @var array\n\t */\n\tprotected $providers = [\n\t\tConfigProvider::class,\n\t\tBindingsProvider::class,\n\t\tArtisanProvider::class,\n\t\tMigrationsProvider::class,\n\t\tTranslationsProvider::class,\n\t\tBladeProvider::class,\n\t\tRoutesProvider::class,\n\t\tViewProvider::class,\n\t\tEventsProvider::class,\n\t];\n}\n```\n\nAnd in your `composer.json` simply auto-register only your aggregate service provider like so:\n\n```json\n{\n\t\"extra\": {\n        \"laravel\": {\n            \"providers\": [\n                \"MyPackage\\\\Providers\\\\MyPackageServiceProvider\"\n            ]\n        }\n    }\n}\n```\n\n### Base Service Providers included\n\nWe include various service providers for the most common package needs. So you can simply use / extend them and at it to your package service provider.\n\n### Package Configuration\n\nIf you want to register package configuration you have to extend the `ConfigurationServiceProvider`.\n\nFirst of all, please add a protected `$packagePath` to your extended service provider class and give it a value for the package root folder like so: `protected $packagePath = __DIR__ . '/../../';`. This is necessary to mark your files relative to the package root.\n\nYou have to add your configuration files in attribute `$configurationFiles`. File by file as array item. If you want to give an alias for config you have to set is array key. For example:\n\nWithin your package you have a `config/config.php` and you want to have it published and merged as `my-package` you have to set it like so\n\n`'my-package' =\u003e 'config/config.php'`\n\nThen you can get config values by using `config('my-package.)`.\n\n#### Routes\n\nFor providing routes you have to extend the `RouteServiceProvider`.\n\nFirst of all, please add a protected `$packagePath` to your extended service provider class and give it a value for the package root folder like so: `protected $packagePath = __DIR__ . '/../../';`. This is necessary to mark your files relative to the package root.\n\nJust set `$routesNamespace`, `$routesMiddleware` and `$routesFile` to your needs and you are ready to go. For registering various routes you should have one provider for each type of routes file (api, web, ...).\n\n#### Views / Templates\n\nWe provide the `ViewServiceProvider` for extension.\n\nFirst of all, please add a protected `$packagePath` to your extended service provider class and give it a value for the package root folder like so: `protected $packagePath = __DIR__ . '/../../';`. This is necessary to mark your files relative to the package root.\n\nYou have to set the `$namespace` to your package based identifier. The `$templatesFolder` is set to the `resources/views` by default, you can override it.\n\n#### Database Migrations\n\nWe provide the `MigrationServiceProvider` to provide database migration files from package.\n\nFirst of all, please add a protected `$packagePath` to your extended service provider class and give it a value for the package root folder like so: `protected $packagePath = __DIR__ . '/../../';`. This is necessary to mark your files relative to the package root.\n\nYou have to set the `$migrationsFolder` to your package migrations.\n\n#### Translations\n\nWe provide the `TranslationServiceProvider` for extension.\n\nFirst of all, please add a protected `$packagePath` to your extended service provider class and give it a value for the package root folder like so: `protected $packagePath = __DIR__ . '/../../';`. This is necessary to mark your files relative to the package root.\n\nYou have to set the `$namespace` to your package based identifier. The `$translationsFolder` is set to the `resources/lang` by default, you can override it.\n\nFor the new implemented way for json files we also support the `$useJson` flag. When `true` the given files have to be json format.\n\n#### Artisan Commands\n\nFor registering artisan console command we provide the `ArtisanServiceProvider`.\n\nYou have to fill the `$commands` array with your commands. If you provide a key this key will be the key for registration within the IoC container of laravel. The value should be the command class name like `SuperCommand::class` or a string e.g. `SuperCommand` which gets resolved to lookup a method `registerSuperCommand` within the service provider (protected at least to get called). So you can register more complex commands by using a separate method.\n\nBy default artisan commands will registered only on console runs. If you want to change that behaviour you can overwrite the value of `$registerOnlyForConsole` to make that happen.\n\n#### Aliases\n\nWe provide an `AliasServiceProvider` to register all aliases by hand. But you should provide aliases by the new package discovery:\n```json\n{\n\t\"extra\": {\n\t\t\"laravel\": {\n\t\t\t\"providers\": [\n\t\t\t\t\"YourProvider\"\n\t\t\t],\n\t\t\t\"aliases\": {\n\t\t\t\t\"Alias\": \"Path\\\\To\\\\Facade\"\n\t\t\t}\n\t\t}\n\t},\n}\n```\n\n### Common Resolutions\n\n#### Namespace for views, config, translations, ...\n\nYour aggregated package provider should provide a constant namespace identifier for your package. So you can re-use the same value in all your single package providers consistently.\n\n## License\n\nPackage Manager is open-sourced software licensed under the [MIT license](http://opensource.org/licenses/MIT)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fipunkt%2Flaravel-package-manager","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fipunkt%2Flaravel-package-manager","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fipunkt%2Flaravel-package-manager/lists"}