Closed ethanclevenger91 closed 1 year ago
@ethanclevenger91 would it be safe to say that this issue is really a proposal that we update the Bedrock driver to check for the roots/bedrock-autoloader
composer package so it's more flexible? If so, great idea--Sculpin already checks Composer for dependencies in its driver and I can make similar Composer checks available to all drivers pretty freaking easily, especially in v4.
@mattstauffer exactly. I considered a PR myself but that must have been the one driver I didn't look through to see if any of the others were already doing this 😆
Fixing in #1345, coming out in v4. :) Thanks!
Description:
The Bedrock driver depends on the
app
directory existing. However, when retrofitting an existing WordPress site into Bedrock, it can sometimes reduce friction/alleviate (potentially unsubstantiated) SEO concerns to simply renameapp
towp-content
and update the BedrockCONTENT_DIR
config accordingly. In this case, the Bedrock driver won't recognize the site. You could name it whatever you want, of course.In the meantime, I've created a custom local driver for this project. Right now, the Bedrock driver looks first for the Bedrock autoloader mu-plugin. This could be determined by parsing the
composer.json
file in the root rather than traversing to the best guess at the location of themu-plugins
directory. It's possible these rules were written before the autoloader was a Composer dependency and are due for an update, or at least an expansion.Something like (complete pseudo-code here)...
if($composer->requires->includes('roots/bedrock-autoloader')) || ...
Steps To Reproduce:
app
directory towp-content
config/application.php
, update theCONTENT_DIR
configuration to/wp-content
.valet park
orvalet link
or whateverDiagnosis
sw_vers
valet --version
cat ~/.config/valet/config.json
cat ~/.composer/composer.json
composer global diagnose
composer global outdated
ls -al /etc/sudoers.d/
brew config
brew services list
brew list --formula --versions | grep -E "(php|nginx|dnsmasq|mariadb|mysql|mailhog|openssl)(@\d\..*)?\s"
brew outdated
brew tap
php -v
which -a php
php --ini
nginx -v
curl --version
php --ri curl
~/.composer/vendor/laravel/valet/bin/ngrok version
ls -al ~/.ngrok2
brew info nginx
brew info php
brew info openssl
openssl version -a
openssl ciphers
sudo nginx -t
which -a php-fpm
/opt/homebrew/opt/php/sbin/php-fpm -v
sudo /opt/homebrew/opt/php/sbin/php-fpm -y /opt/homebrew/etc/php/8.0/php-fpm.conf --test
ls -al ~/Library/LaunchAgents | grep homebrew
ls -al /Library/LaunchAgents | grep homebrew
ls -al /Library/LaunchDaemons | grep homebrew
ls -al /Library/LaunchDaemons | grep "com.laravel.valet."
ls -aln /etc/resolv.conf
cat /etc/resolv.conf
ifconfig lo0
sh -c 'echo "------\n/opt/homebrew/etc/nginx/valet/valet.conf\n---\n"; cat /opt/homebrew/etc/nginx/valet/valet.conf | grep -n "# valet loopback"; echo "\n------\n"'
sh -c 'for file in ~/.config/valet/dnsmasq.d/*; do echo "------\n~/.config/valet/dnsmasq.d/$(basename $file)\n---\n"; cat $file; echo "\n------\n"; done'
sh -c 'for file in ~/.config/valet/nginx/*; do echo "------\n~/.config/valet/nginx/$(basename $file)\n---\n"; cat $file | grep -n "# valet loopback"; echo "\n------\n"; done'