Developers

License

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.

Join this plugin team

Changelog for release 0.1.0 - 19/11/2010

Other releases

Release 0.1.0 - 19/11/2010

sfFilesystemFixturesPlugin

The sfFilesystemFixturesPlugin is a symfony plugin that provides support for
defining sets of data files with which to populate the directory structure of
a symfony project. The plugin works in much the same way as the symfony
database fixtures system does, but in relation to files rather than database
records.

Usage

The plugin will search the data directory (usually data) for a sub-directory
called fs_fixtures and recursively copy the directories and files found
within it to your main symfony project directory. By default, files will not
be overwritten if they already exist.

In addition the plugin will search the data directory for a sub-directory that
follows the naming convention:

fs_fixtures_<environment name>

If found, everything in this directory will be loaded also. For example, when
running in the dev environment, fixtures will be loaded from
data/fs_fixtures_dev.

The plugin treats these 'filesystem fixtures' as a part of the model layer of
the application, and by default will load them at the same time as normal
fixtures are loaded. Simply place the fixture files in the corresponding
directories and they will be loaded any time the data-load task is invoked.

Important points

The default environment for the data-load task is dev, so unless you
specify an environment with the --env option, fixtures in the
fs_fixtures_dev directory will be loaded, which could be very bad in a
production environment.

Fixtures are always loaded from the main fs_fixtures directory
regardless of the current environment.