eriktorsner / wp-bootstrap

Utils for bootstrapping a WordPress installation
MIT License
43 stars 5 forks source link

BASEPATH is incorrectly defined in 0.5.2 vendor/bin/wpbootstrap #7

Open robpblake opened 7 years ago

robpblake commented 7 years ago

I'm following your tutorial here: https://www.wpessentials.io/2016/01/preparing-a-wordpress-site-for-git-using-wp-bootstrap/

When I run vendor/bin/wpbootstrap wp-init-composer using 0.5.2, I get the following error:

vendor/bin/wpbootstrap wp-init-composer
PHP Notice:  Use of undefined constant BASEPATH - assumed 'BASEPATH' in /vagrant/vendor/eriktorsner/wp-bootstrap/bin/wpbootstrap on line 7
PHP Stack trace:
PHP   1. {main}() /vagrant/vendor/eriktorsner/wp-bootstrap/bin/wpbootstrap:0
PHP Warning:  require_once(BASEPATH/vendor/autoload.php): failed to open stream: No such file or directory in /vagrant/vendor/eriktorsner/wp-bootstrap/bin/wpbootstrap on line 7
PHP Stack trace:
PHP   1. {main}() /vagrant/vendor/eriktorsner/wp-bootstrap/bin/wpbootstrap:0
PHP Fatal error:  require_once(): Failed opening required 'BASEPATH/vendor/autoload.php' (include_path='.:/usr/share/php:/usr/share/pear') in /vagrant/vendor/eriktorsner/wp-bootstrap/bin/wpbootstrap on line 7
PHP Stack trace:
PHP   1. {main}() /vagrant/vendor/eriktorsner/wp-bootstrap/bin/wpbootstrap:0

It looks like you did some refactoring for 0.5.2, but missed BASEPATH here.