function PostApplySubscriber::postApply
Writes a file when staged changes are applied to the active directory.
File
-
core/
modules/ package_manager/ tests/ fixtures/ build_test_projects/ updated_module/ 1.1.0/ src/ PostApplySubscriber.php, line 40
Class
- PostApplySubscriber
- Writes a file after staged changes are applied to the active directory.
Namespace
Drupal\updated_moduleCode
public function postApply() : void {
$dir = $this->pathLocator
->getProjectRoot();
file_put_contents("{$dir}/bravo.txt", 'Bravo!');
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.