Support » Developing with WordPress » wp cli issue with includes in wp-config.php

  • Resolved 5lions

    (@5lions)


    If I modify a wp-config.php file to include an extra file like:

    include “extras.php”

    wp cli then throws this error when trying to do almost anything:

    Warning: include(extras.php): failed to open stream: No such file or directory in phar:///usr/local/bin/wp/vendor/wp-cli/wp-cli/php/WP_CLI/Runner.php(1153) : eval()’d code on line 49″

    We use this extras.php file to dynamically switch certain #DEFINE variables on and off for clients.

    Really dont want to regenerate the entire wp-config.php file through automation when we need a slight change, thus the extras.php file. We change that file automatically for certain tasks.

    Any idea why wp cli BREAKS by simply adding an extra include to wp-config.php? Any workaround???

Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘wp cli issue with includes in wp-config.php’ is closed to new replies.