dldir changed to require less actions from user

This commit is contained in:
Von Random 2015-08-05 05:30:26 +03:00
parent 23c1617206
commit a071bfdbe4

View file

@ -1,6 +1,7 @@
#!/usr/bin/env zsh #!/usr/bin/env zsh
# poor man's aur helper # poor man's aur helper
uri='https://aur4.archlinux.org' uri='https://aur4.archlinux.org'
dldir='/tmp/aur'
for i in jq curl; do for i in jq curl; do
whence $i &>/dev/null || { printf "missing %s!\n" $i >&2; exit 1 } whence $i &>/dev/null || { printf "missing %s!\n" $i >&2; exit 1 }
done done
@ -12,8 +13,10 @@ pacman -Qm | while read package version; do
updates+=$package updates+=$package
fi fi
done done
print "Do you want to download the pkgbuilds here? (C-c to cancel)" printf 'Do you want to download the pkgbuilds to %s? (C-c to cancel)' $dldir
read none read none
mkdir -p /tmp/aur
cd /tmp/aur
for i in $updates; do for i in $updates; do
git clone "$uri/$i.git" git clone "$uri/$i.git"
done done