davedevelopment/phpmig — pull request #60 by ziadoz (2014-10-09 17:14:53+00:00)
Title: Simplified custom migration templates

I was adding a custom migration template to a project the other day and I noticed that because the template gets included, obviously it also gets parsed, so I ended up with this monstrosity of a template to get things working:

```php
getContainer();
}

/**
* Undo the migration.
*/
public function down()
{
\$container = \$this->getContainer();
}
}

PHP;
?>
```

I've submitted a pull request that changes the way the custom template is imported to use `file_get_contents()` and `sprintf` so that the template becomes much simpler:

```php
getContainer();
}

/**
* Undo the migration.
*/
public function down()
{
$container = $this->getContainer();
}
}

```

I've also added a bit of documentation to explain how to use a custom migration template.

I'd appreciate any comments on this change. Thanks.