Last active
July 8, 2019 18:17
-
-
Save nabeelio/d46baf8daf6811243449b4e372ec8945 to your computer and use it in GitHub Desktop.
Install PHP on OSX
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# PHP Install Script | |
# Requires homebrew and phpbrew | |
# Minimum reqs for phpvms development | |
PHP_VERSION=7.3.7 | |
# Prereqs | |
brew install bzip2 libzip libxml2 mhash mcrypt pcre autoconf | |
# Install PHP | |
phpbrew install $(PHP_VERSION) \ | |
+default \ | |
+bz2="$(brew --prefix bzip2)" \ | |
+zlib="$(brew --prefix zlib)" \ | |
+zip="$(brew --prefix libzip)" \ | |
+debug \ | |
+mysql \ | |
+sqlite \ | |
+fpm \ | |
+pdo | |
phpbrew switch php-$(PHP_VERSION) | |
# Extensions | |
phpbrew ext install xdebug stable | |
# Composer, etc | |
phpbrew app get composer | |
phpbrew app get phpunit | |
echo "Done!" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment