diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..4e9daa3 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,57 @@ +name: Test +on: + push: + pull_request: +jobs: + test: + name: Test PHP-${{ matrix.php-versions }} on ${{ matrix.operating-system }} + runs-on: ${{ matrix.operating-system }} + strategy: + fail-fast: false + matrix: + operating-system: [ubuntu-18.04, ubuntu-16.04] + php-versions: ['5.3', '5.4', '5.5'] + steps: + - name: Checkout + uses: actions/checkout@v2 + + - name: Install PHP + run: | + ls + cd php-${{ matrix.php-versions }} || exit + sudo chmod a+x *.sh + ./install.sh + ./post-install.sh + - name: Test versions and extensions + run: | + php$ver -v | head -n 1 + php-cgi$ver -v | head -n 1 + php-config$ver --version + phpize$ver -v + php$ver -m + pecl -V + env: + ver: ${{ matrix.php-versions }} + release: + name: Update dist + needs: test + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v2 + - name: Package and ship + run: | + for v in 5.3 5.4 5.5; do + sudo XZ_OPT=-9 tar cfJ php-$v.tar.xz php-$v + shopt -s nullglob + for f in php-$v.tar.xz; do + sha256sum "$f" >"${f}".sha256sum.txt + done + curl --user "$BINTRAY_USER":"$BINTRAY_KEY" -X DELETE https://api.bintray.com/content/"$BINTRAY_USER"/"$BINTRAY_REPO"/php-$v.tar.xz || true + curl --user "$BINTRAY_USER":"$BINTRAY_KEY" -T php-$v.tar.xz https://api.bintray.com/content/shivammathur/php/"$v"-linux/"$v"/php-$v.tar.xz || true + curl --user "$BINTRAY_USER":"$BINTRAY_KEY" -X POST https://api.bintray.com/content/"$BINTRAY_USER"/"$BINTRAY_REPO"/"$v"-linux/"$v"/publish || true + done + env: + BINTRAY_KEY: ${{ secrets.bintray_key }} + BINTRAY_USER: shivammathur + BINTRAY_REPO: php diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..95f1618 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +/install.sh diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..74a5455 --- /dev/null +++ b/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2020 Shivam Mathur + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/README.md b/README.md new file mode 100644 index 0000000..0125e97 --- /dev/null +++ b/README.md @@ -0,0 +1,36 @@ +# PHP5 for ubuntu + +Build status +LICENSE +PHP Versions Supported + +> Scripts to install end of life PHP versions. + +PHP versions in this project have reached end of life and should not be used except for testing backward-compatibility. + +## Usage + +### PHP 5.3 +```bash +curl -sSL https://github.com/shivammathur/php5-ubuntu/releases/latest/download/install.sh | bash -s 5.3 +``` + +### PHP 5.4 +```bash +curl -sSL https://github.com/shivammathur/php5-ubuntu/releases/latest/download/install.sh | bash -s 5.4 +``` + +### PHP 5.5 +```bash +curl -sSL https://github.com/shivammathur/php5-ubuntu/releases/latest/download/install.sh | bash -s 5.5 +``` + +## License + +The code in this project is licensed under the [MIT license](http://choosealicense.com/licenses/mit/). +Please see the [license file](LICENSE) for more information. + + +## This project uses the following works + +- [dotdeb](https://www.dotdeb.org/ "dotdeb") \ No newline at end of file diff --git a/php-5.3/deps/libdb4.8_4.8.30-11ubuntu1_amd64.deb b/php-5.3/deps/libdb4.8_4.8.30-11ubuntu1_amd64.deb new file mode 100644 index 0000000..6c94978 Binary files /dev/null and b/php-5.3/deps/libdb4.8_4.8.30-11ubuntu1_amd64.deb differ diff --git a/php-5.3/deps/libicu44_4.4.2-2_amd64.deb b/php-5.3/deps/libicu44_4.4.2-2_amd64.deb new file mode 100644 index 0000000..725be57 Binary files /dev/null and b/php-5.3/deps/libicu44_4.4.2-2_amd64.deb differ diff --git a/php-5.3/deps/libonig2_5.9.6-1_amd64.deb b/php-5.3/deps/libonig2_5.9.6-1_amd64.deb new file mode 100644 index 0000000..a6ab12b Binary files /dev/null and b/php-5.3/deps/libonig2_5.9.6-1_amd64.deb differ diff --git a/php-5.3/deps/libreadline6_6.3-8ubuntu2_amd64.deb b/php-5.3/deps/libreadline6_6.3-8ubuntu2_amd64.deb new file mode 100644 index 0000000..9b9cc33 Binary files /dev/null and b/php-5.3/deps/libreadline6_6.3-8ubuntu2_amd64.deb differ diff --git a/php-5.3/deps/libssl0.9.8_0.9.8o-7ubuntu3.1_amd64.deb b/php-5.3/deps/libssl0.9.8_0.9.8o-7ubuntu3.1_amd64.deb new file mode 100644 index 0000000..8c7835b Binary files /dev/null and b/php-5.3/deps/libssl0.9.8_0.9.8o-7ubuntu3.1_amd64.deb differ diff --git a/php-5.3/deps/php5-common_5.3.29-1~dotdeb.0_amd64.deb b/php-5.3/deps/php5-common_5.3.29-1~dotdeb.0_amd64.deb new file mode 100644 index 0000000..6b83c30 Binary files /dev/null and b/php-5.3/deps/php5-common_5.3.29-1~dotdeb.0_amd64.deb differ diff --git a/php-5.3/install.sh b/php-5.3/install.sh new file mode 100644 index 0000000..20db2a1 --- /dev/null +++ b/php-5.3/install.sh @@ -0,0 +1,13 @@ +apt_install="sudo DEBIAN_FRONTEND=noninteractive apt-get install -o Dpkg::Options::=--force-conflicts -y --allow-downgrades --no-upgrade" +dpkg_install="sudo DEBIAN_FRONTEND=noninteractive dpkg -i --force-conflicts" +sudo mkdir -p /var/run /run/php +$dpkg_install ./deps/*.deb +$apt_install libcurl3 +$dpkg_install ./*.deb +for tool in php5 php5-cgi php-config5 phpize5; do + if [ -f /usr/bin/"$tool" ]; then + tool_name=${tool/5/} + sudo cp /usr/bin/"$tool" /usr/bin/"$tool_name"5.3 + sudo update-alternatives --install /usr/bin/"$tool_name" "$tool_name" /usr/bin/"$tool_name"5.3 50 + fi +done \ No newline at end of file diff --git a/php-5.3/php-pear_5.3.29-1~dotdeb.0_all.deb b/php-5.3/php-pear_5.3.29-1~dotdeb.0_all.deb new file mode 100644 index 0000000..a7825e1 Binary files /dev/null and b/php-5.3/php-pear_5.3.29-1~dotdeb.0_all.deb differ diff --git a/php-5.3/php5-cgi_5.3.29-1~dotdeb.0_amd64.deb b/php-5.3/php5-cgi_5.3.29-1~dotdeb.0_amd64.deb new file mode 100644 index 0000000..88689c1 Binary files /dev/null and b/php-5.3/php5-cgi_5.3.29-1~dotdeb.0_amd64.deb differ diff --git a/php-5.3/php5-cli_5.3.29-1~dotdeb.0_amd64.deb b/php-5.3/php5-cli_5.3.29-1~dotdeb.0_amd64.deb new file mode 100644 index 0000000..853c927 Binary files /dev/null and b/php-5.3/php5-cli_5.3.29-1~dotdeb.0_amd64.deb differ diff --git a/php-5.3/php5-curl_5.3.29-1~dotdeb.0_amd64.deb b/php-5.3/php5-curl_5.3.29-1~dotdeb.0_amd64.deb new file mode 100644 index 0000000..8c05911 Binary files /dev/null and b/php-5.3/php5-curl_5.3.29-1~dotdeb.0_amd64.deb differ diff --git a/php-5.3/php5-dev_5.3.29-1~dotdeb.0_amd64.deb b/php-5.3/php5-dev_5.3.29-1~dotdeb.0_amd64.deb new file mode 100644 index 0000000..3fc63b4 Binary files /dev/null and b/php-5.3/php5-dev_5.3.29-1~dotdeb.0_amd64.deb differ diff --git a/php-5.3/php5-intl_5.3.29-1~dotdeb.0_amd64.deb b/php-5.3/php5-intl_5.3.29-1~dotdeb.0_amd64.deb new file mode 100644 index 0000000..455e664 Binary files /dev/null and b/php-5.3/php5-intl_5.3.29-1~dotdeb.0_amd64.deb differ diff --git a/php-5.3/php5-redis_5.3.29-1~dotdeb.0_amd64.deb b/php-5.3/php5-redis_5.3.29-1~dotdeb.0_amd64.deb new file mode 100644 index 0000000..812ae2f Binary files /dev/null and b/php-5.3/php5-redis_5.3.29-1~dotdeb.0_amd64.deb differ diff --git a/php-5.3/php5-xdebug_5.3.29-1~dotdeb.0_amd64.deb b/php-5.3/php5-xdebug_5.3.29-1~dotdeb.0_amd64.deb new file mode 100644 index 0000000..bbfc4b5 Binary files /dev/null and b/php-5.3/php5-xdebug_5.3.29-1~dotdeb.0_amd64.deb differ diff --git a/php-5.3/post-install.sh b/php-5.3/post-install.sh new file mode 100644 index 0000000..ac83449 --- /dev/null +++ b/php-5.3/post-install.sh @@ -0,0 +1,7 @@ +v=5.3 +for tool in php$v php-cgi$v php-config$v phpize$v; do + if [ -f /usr/bin/"$tool" ]; then + tool_name=${tool/[0-9]*/} + sudo update-alternatives --set $tool_name /usr/bin/"$tool_name$v" + fi +done \ No newline at end of file diff --git a/php-5.4/deps/libdb5.1_5.1.29-7ubuntu1_amd64.deb b/php-5.4/deps/libdb5.1_5.1.29-7ubuntu1_amd64.deb new file mode 100644 index 0000000..d036caf Binary files /dev/null and b/php-5.4/deps/libdb5.1_5.1.29-7ubuntu1_amd64.deb differ diff --git a/php-5.4/deps/libicu48_4.8.1.1-3ubuntu0.7_amd64.deb b/php-5.4/deps/libicu48_4.8.1.1-3ubuntu0.7_amd64.deb new file mode 100644 index 0000000..ab7cde8 Binary files /dev/null and b/php-5.4/deps/libicu48_4.8.1.1-3ubuntu0.7_amd64.deb differ diff --git a/php-5.4/deps/libonig2_5.9.6-1_amd64.deb b/php-5.4/deps/libonig2_5.9.6-1_amd64.deb new file mode 100644 index 0000000..a6ab12b Binary files /dev/null and b/php-5.4/deps/libonig2_5.9.6-1_amd64.deb differ diff --git a/php-5.4/deps/libreadline6_6.3-8ubuntu2_amd64.deb b/php-5.4/deps/libreadline6_6.3-8ubuntu2_amd64.deb new file mode 100644 index 0000000..9b9cc33 Binary files /dev/null and b/php-5.4/deps/libreadline6_6.3-8ubuntu2_amd64.deb differ diff --git a/php-5.4/deps/libssl0.9.8_0.9.8o-7ubuntu3.1_amd64.deb b/php-5.4/deps/libssl0.9.8_0.9.8o-7ubuntu3.1_amd64.deb new file mode 100644 index 0000000..8c7835b Binary files /dev/null and b/php-5.4/deps/libssl0.9.8_0.9.8o-7ubuntu3.1_amd64.deb differ diff --git a/php-5.4/deps/php5-common_5.4.45-1~dotdeb+7.1_amd64.deb b/php-5.4/deps/php5-common_5.4.45-1~dotdeb+7.1_amd64.deb new file mode 100644 index 0000000..e3068a7 Binary files /dev/null and b/php-5.4/deps/php5-common_5.4.45-1~dotdeb+7.1_amd64.deb differ diff --git a/php-5.4/install.sh b/php-5.4/install.sh new file mode 100644 index 0000000..97c4e0c --- /dev/null +++ b/php-5.4/install.sh @@ -0,0 +1,13 @@ +apt_install="sudo DEBIAN_FRONTEND=noninteractive apt-get install -o Dpkg::Options::=--force-conflicts -y --allow-downgrades --no-upgrade" +dpkg_install="sudo DEBIAN_FRONTEND=noninteractive dpkg -i --force-conflicts" +sudo mkdir -p /var/run /run/php +$dpkg_install ./deps/*.deb +$apt_install libcurl3 +$dpkg_install ./*.deb +for tool in php5 php5-cgi php-config5 phpize5; do + if [ -f /usr/bin/"$tool" ]; then + tool_name=${tool/5/} + sudo cp /usr/bin/"$tool" /usr/bin/"$tool_name"5.4 + sudo update-alternatives --install /usr/bin/"$tool_name" "$tool_name" /usr/bin/"$tool_name"5.4 50 + fi +done \ No newline at end of file diff --git a/php-5.4/php-pear_5.4.45-1~dotdeb+7.1_all.deb b/php-5.4/php-pear_5.4.45-1~dotdeb+7.1_all.deb new file mode 100644 index 0000000..49f9d57 Binary files /dev/null and b/php-5.4/php-pear_5.4.45-1~dotdeb+7.1_all.deb differ diff --git a/php-5.4/php5-cgi_5.4.45-1~dotdeb+7.1_amd64.deb b/php-5.4/php5-cgi_5.4.45-1~dotdeb+7.1_amd64.deb new file mode 100644 index 0000000..13d1c19 Binary files /dev/null and b/php-5.4/php5-cgi_5.4.45-1~dotdeb+7.1_amd64.deb differ diff --git a/php-5.4/php5-cli_5.4.45-1~dotdeb+7.1_amd64.deb b/php-5.4/php5-cli_5.4.45-1~dotdeb+7.1_amd64.deb new file mode 100644 index 0000000..4d28989 Binary files /dev/null and b/php-5.4/php5-cli_5.4.45-1~dotdeb+7.1_amd64.deb differ diff --git a/php-5.4/php5-curl_5.4.45-1~dotdeb+7.1_amd64.deb b/php-5.4/php5-curl_5.4.45-1~dotdeb+7.1_amd64.deb new file mode 100644 index 0000000..9d3e923 Binary files /dev/null and b/php-5.4/php5-curl_5.4.45-1~dotdeb+7.1_amd64.deb differ diff --git a/php-5.4/php5-dev_5.4.45-1~dotdeb+7.1_amd64.deb b/php-5.4/php5-dev_5.4.45-1~dotdeb+7.1_amd64.deb new file mode 100644 index 0000000..ee3171c Binary files /dev/null and b/php-5.4/php5-dev_5.4.45-1~dotdeb+7.1_amd64.deb differ diff --git a/php-5.4/php5-intl_5.4.45-1~dotdeb+7.1_amd64.deb b/php-5.4/php5-intl_5.4.45-1~dotdeb+7.1_amd64.deb new file mode 100644 index 0000000..3f90392 Binary files /dev/null and b/php-5.4/php5-intl_5.4.45-1~dotdeb+7.1_amd64.deb differ diff --git a/php-5.4/php5-redis_5.4.45-1~dotdeb+7.1_amd64.deb b/php-5.4/php5-redis_5.4.45-1~dotdeb+7.1_amd64.deb new file mode 100644 index 0000000..ecb3687 Binary files /dev/null and b/php-5.4/php5-redis_5.4.45-1~dotdeb+7.1_amd64.deb differ diff --git a/php-5.4/php5-xdebug_5.4.45-1~dotdeb+7.1_amd64.deb b/php-5.4/php5-xdebug_5.4.45-1~dotdeb+7.1_amd64.deb new file mode 100644 index 0000000..6c41ca5 Binary files /dev/null and b/php-5.4/php5-xdebug_5.4.45-1~dotdeb+7.1_amd64.deb differ diff --git a/php-5.4/php5-zendopcache_5.4.45-1~dotdeb+7.1_amd64.deb b/php-5.4/php5-zendopcache_5.4.45-1~dotdeb+7.1_amd64.deb new file mode 100644 index 0000000..7e50b67 Binary files /dev/null and b/php-5.4/php5-zendopcache_5.4.45-1~dotdeb+7.1_amd64.deb differ diff --git a/php-5.4/post-install.sh b/php-5.4/post-install.sh new file mode 100644 index 0000000..ad38fc2 --- /dev/null +++ b/php-5.4/post-install.sh @@ -0,0 +1,9 @@ +v=5.4 +for tool in php$v php-cgi$v php-config$v phpize$v; do + if [ -f /usr/bin/"$tool" ]; then + tool_name=${tool/[0-9]*/} + sudo update-alternatives --set $tool_name /usr/bin/"$tool_name$v" + fi +done +sudo php5enmod redis +sudo php5enmod xdebug \ No newline at end of file diff --git a/php-5.5/deps/libdb5.1_5.1.29-7ubuntu1_amd64.deb b/php-5.5/deps/libdb5.1_5.1.29-7ubuntu1_amd64.deb new file mode 100644 index 0000000..d036caf Binary files /dev/null and b/php-5.5/deps/libdb5.1_5.1.29-7ubuntu1_amd64.deb differ diff --git a/php-5.5/deps/libicu48_4.8.1.1-3ubuntu0.7_amd64.deb b/php-5.5/deps/libicu48_4.8.1.1-3ubuntu0.7_amd64.deb new file mode 100644 index 0000000..ab7cde8 Binary files /dev/null and b/php-5.5/deps/libicu48_4.8.1.1-3ubuntu0.7_amd64.deb differ diff --git a/php-5.5/deps/libonig2_5.9.6-1_amd64.deb b/php-5.5/deps/libonig2_5.9.6-1_amd64.deb new file mode 100644 index 0000000..a6ab12b Binary files /dev/null and b/php-5.5/deps/libonig2_5.9.6-1_amd64.deb differ diff --git a/php-5.5/deps/libreadline6_6.3-8ubuntu2_amd64.deb b/php-5.5/deps/libreadline6_6.3-8ubuntu2_amd64.deb new file mode 100644 index 0000000..9b9cc33 Binary files /dev/null and b/php-5.5/deps/libreadline6_6.3-8ubuntu2_amd64.deb differ diff --git a/php-5.5/deps/libssl0.9.8_0.9.8o-7ubuntu3.1_amd64.deb b/php-5.5/deps/libssl0.9.8_0.9.8o-7ubuntu3.1_amd64.deb new file mode 100644 index 0000000..8c7835b Binary files /dev/null and b/php-5.5/deps/libssl0.9.8_0.9.8o-7ubuntu3.1_amd64.deb differ diff --git a/php-5.5/deps/php5-common_5.5.38-1~dotdeb+7.1_amd64.deb b/php-5.5/deps/php5-common_5.5.38-1~dotdeb+7.1_amd64.deb new file mode 100644 index 0000000..e493ce0 Binary files /dev/null and b/php-5.5/deps/php5-common_5.5.38-1~dotdeb+7.1_amd64.deb differ diff --git a/php-5.5/install.sh b/php-5.5/install.sh new file mode 100644 index 0000000..c589e73 --- /dev/null +++ b/php-5.5/install.sh @@ -0,0 +1,15 @@ +apt_install="sudo DEBIAN_FRONTEND=noninteractive apt-get install -o Dpkg::Options::=--force-conflicts -y --allow-downgrades" +dpkg_install="sudo DEBIAN_FRONTEND=noninteractive dpkg -i --force-conflicts" +sudo mkdir -p /var/run /run/php +$dpkg_install ./deps/*.deb +if [ "$(lsb_release -s -r)" = "18.04" ]; then + $apt_install libcurl3 +fi +$dpkg_install ./*.deb +for tool in php5 php5-cgi php-config5 phpize5; do + if [ -f /usr/bin/"$tool" ]; then + tool_name=${tool/5/} + sudo cp /usr/bin/"$tool" /usr/bin/"$tool_name"5.5 + sudo update-alternatives --install /usr/bin/"$tool_name" "$tool_name" /usr/bin/"$tool_name"5.5 50 + fi +done \ No newline at end of file diff --git a/php-5.5/php-pear_5.5.38-1~dotdeb+7.1_all.deb b/php-5.5/php-pear_5.5.38-1~dotdeb+7.1_all.deb new file mode 100644 index 0000000..ca48fbf Binary files /dev/null and b/php-5.5/php-pear_5.5.38-1~dotdeb+7.1_all.deb differ diff --git a/php-5.5/php5-cgi_5.5.38-1~dotdeb+7.1_amd64.deb b/php-5.5/php5-cgi_5.5.38-1~dotdeb+7.1_amd64.deb new file mode 100644 index 0000000..dc1625b Binary files /dev/null and b/php-5.5/php5-cgi_5.5.38-1~dotdeb+7.1_amd64.deb differ diff --git a/php-5.5/php5-cli_5.5.38-1~dotdeb+7.1_amd64.deb b/php-5.5/php5-cli_5.5.38-1~dotdeb+7.1_amd64.deb new file mode 100644 index 0000000..77e92b2 Binary files /dev/null and b/php-5.5/php5-cli_5.5.38-1~dotdeb+7.1_amd64.deb differ diff --git a/php-5.5/php5-curl_5.5.38-1~dotdeb+7.1_amd64.deb b/php-5.5/php5-curl_5.5.38-1~dotdeb+7.1_amd64.deb new file mode 100644 index 0000000..cf3c2e8 Binary files /dev/null and b/php-5.5/php5-curl_5.5.38-1~dotdeb+7.1_amd64.deb differ diff --git a/php-5.5/php5-dev_5.5.38-1~dotdeb+7.1_amd64.deb b/php-5.5/php5-dev_5.5.38-1~dotdeb+7.1_amd64.deb new file mode 100644 index 0000000..3432cf8 Binary files /dev/null and b/php-5.5/php5-dev_5.5.38-1~dotdeb+7.1_amd64.deb differ diff --git a/php-5.5/php5-intl_5.5.38-1~dotdeb+7.1_amd64.deb b/php-5.5/php5-intl_5.5.38-1~dotdeb+7.1_amd64.deb new file mode 100644 index 0000000..d7a36f3 Binary files /dev/null and b/php-5.5/php5-intl_5.5.38-1~dotdeb+7.1_amd64.deb differ diff --git a/php-5.5/php5-redis_5.5.38-1~dotdeb+7.1_amd64.deb b/php-5.5/php5-redis_5.5.38-1~dotdeb+7.1_amd64.deb new file mode 100644 index 0000000..848c478 Binary files /dev/null and b/php-5.5/php5-redis_5.5.38-1~dotdeb+7.1_amd64.deb differ diff --git a/php-5.5/php5-xdebug_5.5.38-1~dotdeb+7.1_amd64.deb b/php-5.5/php5-xdebug_5.5.38-1~dotdeb+7.1_amd64.deb new file mode 100644 index 0000000..a74f0c0 Binary files /dev/null and b/php-5.5/php5-xdebug_5.5.38-1~dotdeb+7.1_amd64.deb differ diff --git a/php-5.5/post-install.sh b/php-5.5/post-install.sh new file mode 100644 index 0000000..3f93256 --- /dev/null +++ b/php-5.5/post-install.sh @@ -0,0 +1,9 @@ +v=5.5 +for tool in php$v php-cgi$v php-config$v phpize$v; do + if [ -f /usr/bin/"$tool" ]; then + tool_name=${tool/[0-9]*/} + sudo update-alternatives --set $tool_name /usr/bin/"$tool_name$v" + fi +done +sudo php5enmod redis +sudo php5enmod xdebug \ No newline at end of file