packer-arch/scripts/cleanup.sh
Mike Appleby 2a522c91c4 Don't call pacman-optimize in cleanup.sh
The pacman-optimize script has been removed from pacman.

https://git.archlinux.org/pacman.git/commit/?id=d590a45795b30a14cdb697754749c85907053570

This was causing the installer to complain "/usr/bin/pacman-optimize:
No such file or directory".
2018-10-30 16:28:00 -06:00

10 lines
264 B
Bash
Executable file

#!/usr/bin/bash -x
# Clean the pacman cache.
/usr/bin/yes | /usr/bin/pacman -Scc
# Write zeros to improve virtual disk compaction.
zerofile=$(/usr/bin/mktemp /zerofile.XXXXX)
/usr/bin/dd if=/dev/zero of="$zerofile" bs=1M
/usr/bin/rm -f "$zerofile"
/usr/bin/sync