Skip to content

Commit

Permalink
minor #11114 adding docs about configurable flex paths (weaverryan)
Browse files Browse the repository at this point in the history
This PR was submitted for the 4.2 branch but it was merged into the 3.4 branch instead (closes #11114).

Discussion
----------

adding docs about configurable flex paths

Hi friends!

Flex is a bit configurable, but it wasn't documented anywhere.

See https://twitter.com/beausimensen/status/1101863042797789192

Commits
-------

d307157 adding docs about configurable flex paths
  • Loading branch information
javiereguiluz committed Mar 11, 2019
2 parents 984c9bb + d307157 commit 7f16dfa
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions setup/flex.rst
Expand Up @@ -184,6 +184,36 @@ manual steps:
original ``web/app_*.php`` front controllers were customized, add those changes
to the new ``public/index.php`` controller.

Customizing Flex Paths
----------------------

The Flex recipes make a few assumptions about your project's directory structure.
Some of these assumptions can be customized by adding a key under the ``extra``
section of your ``composer.json`` file. For example, to tell Flex to copy any
PHP classes into ``src/App`` instead of ``src``:

.. code-block:: json
{
"...": "...",
"extra": {
"src-dir": "src/App"
}
}
The configurable paths are:

* ``bin-dir``: defaults to ``bin/``
* ``config-dir``: defaults to ``config/``
* ``src-dir`` defaults to ``src/``
* ``var-dir`` defaults to ``var/``
* ``public-dir`` defaults to ``public/``

If you customize these paths, some files copied from a recipe still may contain
references to the original path. In other words: you may need to update some things
manually after a recipe is installed.

.. _`Symfony Flex`: https://github.com/symfony/flex
.. _`Symfony Installer`: https://github.com/symfony/symfony-installer
.. _`Symfony Standard Edition`: https://github.com/symfony/symfony-standard
Expand Down

0 comments on commit 7f16dfa

Please sign in to comment.