- making bundle from the scratch:
- Symfony docs:
- https://symfony.com/doc/current/service_container.html
- https://symfony.com/doc/current/components/dependency_injection.html
- https://symfony.com/doc/current/components/dependency_injection/compilation.html
- https://symfony.com/doc/current/service_container/compiler_passes.html
- https://symfony.com/doc/current/bundles.html
- https://symfony.com/doc/current/bundles/extension.html
- https://symfony.com/doc/current/service_container/definitions.html
- https://symfony.com/doc/current/bundles/configuration.html
- https://symfony.com/doc/current/configuration/using_parameters_in_dic.html
- https://symfony.com/doc/current/bundles/prepend_extension.html
- https://symfony.com/doc/current/bundles/best_practices.html
- @TOREAD:
https://packagist.org/packages/boolean-type/lorem-ipsum-bundle
- in browser:
- in console:
D:\server\www\LoremIpsumBundle>vendor\bin\simple-phpunit # Run the tests.
Changes, made in vendor
folder, for bundle, installed from packagist (https://packagist.org/packages/boolean-type/lorem-ipsum-bundle) wan't work. So, I need to made them in local (ie this) bundle version.
-
composer remove boolean-type/lorem-ipsum-bundle
-
In app's
composer.json
add this ("../LoremIpsumBundle"
is the path, where my bundle locally exists):
"repositories": [ { "type": "path", "url": "../LoremIpsumBundle" } ]
composer require boolean-type/lorem-ipsum-bundle:*@dev
- In app's
composer.json
delete this:
"repositories": [ { "type": "path", "url": "../LoremIpsumBundle" } ]
-
composer remove boolean-type/lorem-ipsum-bundle
-
composer req "boolean-type/lorem-ipsum-bundle:^1.0"
(1.0
is bundle current version)
This recipe will work only for my bundle on packagist, not for this, local version.
I've forked from https://github.com/symfony/recipes-contrib . Next I git-cloned this repo to my disc and created new folder with my recipe. Then I've created a pull request from a fork, as explained here - https://docs.github.com/en/github/collaborating-with-issues-and-pull-requests/creating-a-pull-request-from-a-fork . From this time all changes, that I pushed to my fork, automatically pushed to created pull request in symfony/recipes-contrib. After successful validation "View deployment" link appeared. This links contains instructions, described below.
composer clearcache
Theory:
Instructions for the recipe, created by me for this bundle:
If instructions for bundle become anavailable by link above, here is the copy:
Step 0. Allow installing "contrib" recipes in your application:
composer config extra.symfony.allow-contrib true
Step 1. Define the SYMFONY_ENDPOINT
environment variable:
# On *nix and Mac export SYMFONY_ENDPOINT=https://flex.symfony.com/r/github.com/symfony/recipes-contrib/1099 # On Windows SET SYMFONY_ENDPOINT=https://flex.symfony.com/r/github.com/symfony/recipes-contrib/1099
Step 2. Install the package(s) related to this recipe:
composer req "boolean-type/lorem-ipsum-bundle:^1.0"
Step 3. Don't forget to unset the SYMFONY_ENDPOINT
environment variable when done:
# On *nix and Mac unset SYMFONY_ENDPOINT # On Windows SET SYMFONY_ENDPOINT=
https://travis-ci.com/github/BooleanType/symfony_knpu_lorem_ipsum_bundle/builds