https://github.com/thecodingmachine/symfony-console-universal-module
https://github.com/thecodingmachine/symfony-console-universal-module
Last synced: 8 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/thecodingmachine/symfony-console-universal-module
- Owner: thecodingmachine
- Created: 2016-12-12T16:13:56.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2017-12-14T15:40:54.000Z (over 8 years ago)
- Last Synced: 2025-09-30T05:47:12.586Z (9 months ago)
- Language: PHP
- Size: 5.86 KB
- Stars: 0
- Watchers: 8
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
[](https://packagist.org/packages/thecodingmachine/symfony-console-universal-module)
[](https://packagist.org/packages/thecodingmachine/symfony-console-universal-module)
[](https://packagist.org/packages/thecodingmachine/symfony-console-universal-module)
# Symfony console universal module
This package integrates [symfony/console](https://github.com/symfony/console) in any [container-interop](https://github.com/container-interop/service-provider) compatible framework/container.
## Installation
```
composer require thecodingmachine/symfony-console-universal-module
```
Once installed, you need to register the [`TheCodingMachine\SymfonyConsoleServiceProvider`](src/SymfonyConsoleServiceProvider.php) into your container.
If your container supports thecodingmachine/discovery integration, you have nothing to do. Otherwise, refer to your framework or container's documentation to learn how to register *service providers*.
## Introduction
This service provider is meant to create a Symfony console in your container.
You can access the console using: `vendor/bin/app_console`.
For the console to work, you need to have a `container.php` file at the root of your project or in the 'config' directory. This file MUST returns your application's container.
This file will be used by the Symfony console to access and start the application.
Sample:
**container.php** (or **config/container.php**)
```php
Project template courtesy of thecodingmachine/service-provider-template