Handle WP source path config for different environments

[MAILPOET-3029]
This commit is contained in:
Rostislav Wolny
2020-11-05 13:18:23 +01:00
committed by Veljko V
parent 76bb139019
commit 688755a9bf
5 changed files with 10 additions and 5 deletions

View File

@ -506,6 +506,9 @@ class RoboFile extends \Robo\Tasks {
// temp dir
->taskExec('mkdir -p ' . __DIR__ . '/temp')
->taskExec('rm -rf ' . __DIR__ . '/temp/phpstan')
// Generate config with correct path to WP source
->taskExec("cp -rf $dir/tasks/phpstan/phpstan-wp-source.neon $dir/tasks/phpstan/_phpstan-wp-source.neon")
->taskExec("sed -i 's+WP_ROOT+" . getenv('WP_ROOT') . "+g' $dir/tasks/phpstan/_phpstan-wp-source.neon")
// lib
->taskExec($task)
->arg("$dir/lib")