Switching PHP versions suddenly not switching CLI versions
Posted: Mon Jan 10, 2022 5:18 pm
I haven't needed to switch for weeks, but I use MAMP Pro to switch between PHP versions 5.6 and 7.4, but for some reason, it stopped switching the CLI version. Normally I go into the PHP section and change the PHP version then restart, and I always leave "Activate command line shortcuts..." and "Also activate shortcut for Composer" checked. For certain repos, I have to use Module or CGI, but switching anything there never had an issue before.
The only thing I'm finding that actually switches it for the CLI is to reboot the Mac... I'm on Big Sur, and have put off updating to Monterey because when I updated to Big Sur, it broke MAMP Pro until there was a "compatible" version. I can't tell in my research if there's a Monterey-compatible MAMP Pro, but I'll be in rough waters if I can't use MAMP Pro on my websites.
Can someone advise me on this?! I'm on MAMP Pro version 6.4. I did change MAMP's Apache http.conf just to enable the CustomLog, then I added a site-specific CustomLog (VirtualHost), but I don't see how that could have broken CLI PHP version switching. I don't use Mac's Apache or PHP and I don't think anything hits it but I'm not sure, it came with Catalina. MAMP effectively changes /etc/hosts properly, though I don't think that has anything to do with CLI version, maybe I'm wrong. I don't think the macOS version has anything to do with it either since things were working without me having to update anything. Could the http.conf have anything to do with it?!
The only thing I'm finding that actually switches it for the CLI is to reboot the Mac... I'm on Big Sur, and have put off updating to Monterey because when I updated to Big Sur, it broke MAMP Pro until there was a "compatible" version. I can't tell in my research if there's a Monterey-compatible MAMP Pro, but I'll be in rough waters if I can't use MAMP Pro on my websites.
Can someone advise me on this?! I'm on MAMP Pro version 6.4. I did change MAMP's Apache http.conf just to enable the CustomLog, then I added a site-specific CustomLog (VirtualHost), but I don't see how that could have broken CLI PHP version switching. I don't use Mac's Apache or PHP and I don't think anything hits it but I'm not sure, it came with Catalina. MAMP effectively changes /etc/hosts properly, though I don't think that has anything to do with CLI version, maybe I'm wrong. I don't think the macOS version has anything to do with it either since things were working without me having to update anything. Could the http.conf have anything to do with it?!