Categories
Fixing Stuff Laravel Php Storm Samuel

Fixing Laravel Valet Error

Sooooo we needed to jump our local environment from PHP 7.4 to PHP 8.1 in order to work on a different project.

We started by running the command:

Valet use php@8.1

That provided the following error:

Fatal error: Composer detected issues in your platform: Your Composer dependencies require a PHP version ">= 8.1.0". You are running 7.4.27. in /Users/sam/.composer/vendor/composer/platform_check.php on line 25

To fix this issue we ran:

brew link php

This command resulted in:

brew link php
Unlinking /usr/local/Cellar/php@7.4/7.4.27.reinstall... 25 symlinks removed.
Linking /usr/local/Cellar/php/8.1.2.reinstall... 24 symlinks created.

From there we could run “valet use php 8.2” and our new project was happy. This post was also super helpful, it provides solutions for a few other versions oh PHP so if anyone else out there is stuck you can try the link below:

https://dev.to/arielmejiadev/switch-to-older-php-versions-with-laravel-valet-33ph

Categories
Fixing Stuff Samuel

Video Editing

We needed to open a .AVI file on our mac computer. This video showed perfectly how to do it: https://www.youtube.com/watch?v=Q0-MAlLkL8A

We then needed to zoom in on a particular spot of the video, and this showed us how to do that: https://www.youtube.com/watch?v=f-Uaz4NyOXU

Categories
Fixing Stuff Laravel Samuel

Fixing Stuck Forge Deployment

We had a forge deployment get stuck today, took a little searching around but the fix actually ended up being super easy. From the forge dashboard select the self-help drop down -> reset deployment state:

Thats pretty much it, your deployment should stop, and you can look into what was causing the issue. In our case it ended up being incorrect DB credentials in our .env file

Categories
Development Fixing Stuff Samuel WordPress

Fixing Laravel Forge No input file specified

We decided to try and setup WordPress on a Laravel Forge account today, we got everything all setup, pulled up the site and saw this ugly white error screen that read:

No input file specified

As far as errors go it’s not the most useful one. Nothing showed in the logs, after spinning my wheels on this for a while this ended up being very easy to fix, just follow the steps below:

  • Login to your forge account
  • Navigate to the site you are working on
  • Click the Meta tab
  • Change the Web Directory from /Public to /
    • it ends up looking like this

Categories
Fixing Stuff Mac Samuel

Updating Mac Hosts File

  1. open iTerm and type sudo nano /etc/hosts
  2. enter in password
  3. Type in the TCP/IP address
  4. Press the Tab key
  5. Type the domain name
  6. Save the file by pressing Ctrl + O (zero)
  7. Exit with Ctrl + X

— Update —

Just add this to your .aliases file so you can open up terminal and type hosts like our buddy Jeffry 🙂

alias hosts=”sudo nano /etc/hosts”

Categories
Fixing Stuff Laravel Samuel

Fixing Laravel Error

We had this error display today when trying to deploy a staging site:

Symfony\Component\Debug\Exception\FatalThrowableError  : Class 'Doctrine\DBAL\Driver\PDOMySql\Driver' not found

to fix this issue we connected to the machine via SSH and ran:

composer require doctrine/dbal --with-all-dependencies

This allowed it to install correctly but we were still getting the same error message, solution TBD…