Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
Diffstat (limited to 'bin')
-rwxr-xr-xbin/build-packages17
1 files changed, 8 insertions, 9 deletions
diff --git a/bin/build-packages b/bin/build-packages
index 821491a..d18f0e0 100755
--- a/bin/build-packages
+++ b/bin/build-packages
@@ -496,14 +496,11 @@ while [ "${count}" -ne 0 ] && \
set -e
CARCH="${arch}"
. /usr/share/makepkg/util/source.sh
- eval "$(
- sed '
- :a
- s/^\(\S\+\)-/\1_/
- ta
- ' PKGBUILD
- )"
- printf '%s\n' "${source[@]}" \
+ bash -c ' # new shell is intentional
+ CARCH="'"${arch}"'"
+ . PKGBUILD
+ printf '"'"'%s\n'"'"' "${source[@]}"
+ ' \
| grep '^git+' \
| while read -r netfile; do
fragment=$(get_uri_fragment "$netfile")
@@ -519,13 +516,15 @@ while [ "${count}" -ne 0 ] && \
continue
esac
path=$(get_filename "$netfile")
- git init "${path}"
+ [ -d "${path}" ] && continue
+ git init --bare "${path}"
url=$(get_url "$netfile")
url=${url#git+}
url=${url%%#*}
url=${url%%\?*}
git -C "${path}" remote add origin "${url}"
git -C "${path}" fetch --depth=1 origin "${ref}"
+ git -C "${path}" fetch --depth=1 origin
done
)
if CARCH="${arch}" makepkg --verifysource 2> "${log_file}"; then