Skip to content

Add support for custom stubs for generate migrations #86

@seticzech

Description

@seticzech

Command doctrine:migrations:generate uses 'stubs' files as templates for generate migration classes. It would be nice to have support for create custom stubs.

We need to add the same custom postUp() and postDown() methods to every generated migration. Now we have to add these methods manually and custom stub file is exactly the solution we need for adding these two methods to migration classes automatically.

How to implement:

Add new configuration option like stubs_path which can be pointed to directory with custom stubs files (blank.stub, create.stub, update.stub). In case the custom stub file doesn't exists the default one will be used.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions