Skip to content

Instantly share code, notes, and snippets.

@solace
Created June 14, 2018 12:04
Show Gist options
  • Save solace/52ccd131c5e7844ff532e48b8959da68 to your computer and use it in GitHub Desktop.
Save solace/52ccd131c5e7844ff532e48b8959da68 to your computer and use it in GitHub Desktop.
Update sphp to support PHP 5.5
# Update the support arrays to include 5.5.
brew_array=("5.5","5.6","7.0","7.1","7.2")
php_array=("php@5.5" "php@5.6" "php@7.0" "php@7.1" "php@7.2")
valet_support_php_version_array=("php@5.5" "php@5.6" "php@7.0" "php@7.1" "php@7.2")
# Search for the `brew link --force "$php_version"` line, and replace it with this.
if [[ $(echo "$php_version" | sed 's/^php@//' | sed 's/\.//') -lt 56 ]]
then
brew link --force --overwrite "$php_version"
else
brew link --force "$php_version"
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment