blob: 5293d0e25fc3d1bf772aa031c12efb63d380dae8 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
|
# Archlinux system installation and compare
# vim: ft=sh
# Installs pacaur
# This expect base and base-devel to be installed
arch_pacaur() {
set -e
# Make sure that we have wget
sudo pacman -S wget
# Download pacaur tar
wget https://aur.archlinux.org/cgit/aur.git/snapshot/pacaur.tar.gz
# Download cower (pacaur dependency)
wget https://aur.archlinux.org/cgit/aur.git/snapshot/cower.tar.gz
tar -xzf cower.tar.gz
cd cower
makepkg -cis
cd ..
rm -rf cower cower.tar.gz
tar -xzf pacaur.tar.gz
cd pacaur
makepkg -cis
cd ..
rm -rf pacaur pacaur.tar.gz
unset -e
}
archlinux_inst() {
# Check if we are on archlinux
if ! [ -e /etc/arch-release ]; then
echo Archlinux not detected! >&2
return
fi
# Now check for pacaur and optionally install
if ! pacaur --version 2>&1 >/dev/null; then
arch_pacaur
fi
TFILE1=$(mktemp myconfigs-pacaur1-XXXXX)
grep -E '^[^# ]+$' archlinux.pkgs | sort > "$TFILE1"
TFILE2=$(mktemp myconfigs-pacaur2-XXXXX)
pacaur -Qqet | sort > "$TFILE2"
diff --suppress-common-lines -ay "$TFILE1" "$TFILE2"
rm "$TFILE1" "$TFILE2"
}
|