Skip to content

Instantly share code, notes, and snippets.

@juliocapuano
Forked from agarzon/install-php-tools.sh
Created January 28, 2018 14:05
Show Gist options
  • Save juliocapuano/76542bcd8c3a1bd38c576a2a00cdeaa2 to your computer and use it in GitHub Desktop.
Save juliocapuano/76542bcd8c3a1bd38c576a2a00cdeaa2 to your computer and use it in GitHub Desktop.
Install globally popular PHP dev tools like composer, phpunit, phpcs, phpmd, phpcpd, deployer, robo, codeception, etc.
#!/bin/bash
#To execute it directly: sudo bash <(curl -s https://gist.githubusercontent.com/agarzon/ecb0b92d4c8e1bbde126534c76721a58/raw/install-php-tools.sh)
BIN_PATH=/usr/local/bin/
#COMPOSER
sudo curl -LsS https://getcomposer.org/composer.phar -o ${BIN_PATH}composer
sudo chmod a+x ${BIN_PATH}composer
#CODECEPTION
sudo curl -LsS http://codeception.com/codecept.phar -o ${BIN_PATH}codecept
sudo chmod a+x ${BIN_PATH}codecept
#PHPMD
sudo curl -LsS http://static.phpmd.org/php/latest/phpmd.phar -o ${BIN_PATH}phpmd
sudo chmod a+x ${BIN_PATH}phpmd
#DEPLOYER
sudo curl -LsS http://deployer.org/deployer.phar -o ${BIN_PATH}dep
sudo chmod a+x ${BIN_PATH}dep
#ROBO
sudo curl -LsS http://robo.li/robo.phar -o ${BIN_PATH}robo
sudo chmod a+x ${BIN_PATH}robo
#PHPCPD
sudo curl -LsS https://phar.phpunit.de/phpcpd.phar -o ${BIN_PATH}phpcpd
sudo chmod a+x ${BIN_PATH}phpcpd
#PHPCS
sudo curl -LsS https://squizlabs.github.io/PHP_CodeSniffer/phpcs.phar -o ${BIN_PATH}phpcs
sudo chmod a+x ${BIN_PATH}phpcs
#PHPCBF
sudo curl -LsS https://squizlabs.github.io/PHP_CodeSniffer/phpcbf.phar -o ${BIN_PATH}phpcbf
sudo chmod a+x ${BIN_PATH}phpcbf
#PHPUNIT
sudo curl -LsS https://phar.phpunit.de/phpunit.phar -o ${BIN_PATH}phpunit
sudo chmod a+x ${BIN_PATH}phpunit
#PSYSH
sudo curl -LsS https://git.io/psysh -o ${BIN_PATH}psysh
sudo chmod a+x ${BIN_PATH}psysh
#PHP-CS-FIXER
sudo curl -LsS http://cs.sensiolabs.org/download/php-cs-fixer-v2.phar -o ${BIN_PATH}php-cs-fixer
sudo chmod a+x ${BIN_PATH}php-cs-fixer
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment