diff options
author | Johannes Schleifenbaum | 2014-12-30 11:38:23 +0100 |
---|---|---|
committer | Johannes Schleifenbaum | 2014-12-30 11:38:23 +0100 |
commit | b580500256e6156286a4eec97753ecd6304d4426 (patch) | |
tree | 5aabd098555ee6cdace9eb6b8c1eeb2bc62c2928 | |
parent | 0c2798f48d6a020ba3aa9c3a083f47cff5787800 (diff) | |
download | aur-b580500256e6156286a4eec97753ecd6304d4426.tar.gz |
use install script to check if phar is enabled
-rw-r--r-- | PKGBUILD | 3 | ||||
-rw-r--r-- | phpcpd.install | 12 |
2 files changed, 14 insertions, 1 deletions
@@ -3,7 +3,7 @@ pkgname="phpcpd" pkgver=2.0.1 -pkgrel=3 +pkgrel=4 pkgdesc="Copy/Paste Detector (CPD) for PHP code." url="https://github.com/sebastianbergmann/phpcpd" license="BSD" @@ -13,6 +13,7 @@ source=( "https://phar.phpunit.de/${pkgname}-${pkgver}.phar" "LICENSE" ) +install="${pkgname}.install" sha1sums=( "f9fb98b688092603adff5ca0f1264fcf77674f90" "6e7d5c0718a2559eb09bd1456606cd1d5ac90dc7" diff --git a/phpcpd.install b/phpcpd.install new file mode 100644 index 000000000000..72360306f81f --- /dev/null +++ b/phpcpd.install @@ -0,0 +1,12 @@ +post_install() { + if ! /usr/bin/php -i | grep Phar >/dev/null; then + echo + echo "the Phar extension of php must be enabled." + echo + echo "check if the line extension=phar.so is commented out in your php.ini" + echo + fi +} +post_upgrade() { + post_install +}
\ No newline at end of file |