1 # Maintainer: Pierre Schmitz <pierre@archlinux.de>
6 pkgdesc="Dependency Manager for PHP"
9 url='https://getcomposer.org/'
10 depends=('php' 'unzip')
12 source=("${pkgname}::git+https://github.com/composer/composer.git#tag=${pkgver}"
13 "${pkgname}-${pkgver}.phar::https://getcomposer.org/download/${pkgver}/composer.phar")
15 '566a6d1cf4be1cc3ac882d2a2a13817ffae54e60f5aa7c9137434810a5809ffc')
18 cd "${srcdir}/${pkgname}"
20 php "${srcdir}/${pkgname}-${pkgver}.phar" install --no-interaction --no-dev --no-progress --prefer-dist
24 cd "${srcdir}/${pkgname}"
26 php -d phar.readonly=Off bin/compile
27 php composer.phar completion bash > completion.bash
33 mkdir integration-test
36 php "${srcdir}/${pkgname}/composer.phar" init \
39 --name='archlinux/test' \
40 --description='Composer Test Project' \
41 --license='GPL-3.0-or-later' \
42 --require='symfony/console:*'
43 php "${srcdir}/${pkgname}/composer.phar" update --no-interaction --no-progress --prefer-dist
44 php "${srcdir}/${pkgname}/composer.phar" validate --no-interaction
48 cd "${srcdir}/${pkgname}"
50 install -Dm644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
51 install -Dm755 composer.phar "${pkgdir}/usr/bin/composer"
52 install -Dm644 completion.bash "${pkgdir}/usr/share/bash-completion/completions/composer"