summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorDaniel Wilhelm2016-12-02 15:16:46 +0100
committerDaniel Wilhelm2016-12-07 15:26:35 +0100
commitf883d70c573abb6cfdc66c701fcd6c9b0217ade1 (patch)
tree64c2e94e28766eceb676d5e988085b33b80e4eba
parent3496cceb9d90177bde4a3e12e02504b1697d4c9f (diff)
downloadaur-python-pyvcloud.tar.gz
fix: do not copy source into destination directory
if makepkg is executed multiple times, the source directory will not be copied into the existing destination directory anymore
-rw-r--r--PKGBUILD7
1 files changed, 4 insertions, 3 deletions
diff --git a/PKGBUILD b/PKGBUILD
index 2f68b78f4660..8789ad229217 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -18,12 +18,13 @@ source=("https://github.com/vmware/pyvcloud/archive/$pkgver.tar.gz")
sha256sums=('962b4b3808fa032508544508210d6e0e5b985ae4935ec63ae93313f3c5be07ca')
prepare() {
- cp -a $_pkgname{,-py2}-$pkgver
+ test -d "$srcdir"/$_pkgname-py2-$pkgver || mkdir "$srcdir"/$_pkgname-py2-$pkgver
+ cp -a "$srcdir"/$_pkgname{-$pkgver/.,-py2-$pkgver/}
find $_pkgname-$pkgver/pyvcloud -name \*.py -exec \
- sed -i "s:^#!.*bin.*python:#!/usr/bin/env python3:" {} +
+ sed -i "s:^#!.*bin.*python$:#!/usr/bin/env python3:" {} +
find $_pkgname-py2-$pkgver/pyvcloud -name \*.py -exec \
- sed -i "s:^#!.*bin.*python:#!/usr/bin/env python2:" {} +
+ sed -i "s:^#!.*bin.*python$:#!/usr/bin/env python2:" {} +
}
package_python-pyvcloud() {