summaryrefslogtreecommitdiff
path: root/config-winston-base.PKGBUILD.sh
blob: 19119023a21441a2891d3b7c752570bce22d68bf (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
47
pkgver=1
pkgrel=1
arch=(any)
install=${BUILDFILE#${PWD}/}

pkgname=config-winston-base
depends=(linux-libre-lts haveged irqbalance)
conflicts=(linux-libre)

package() {
cd "$pkgdir"

install -Dm644 /dev/stdin etc/hostname <<EOF
winston.parabola.nu
EOF

install -Dm644 /dev/stdin etc/machine-info <<EOF
LOCATION=1984 Hosting Company, Iceland
EOF

install -Dm644 /dev/stdin etc/vconsole.conf <<EOF
KEYMAP=us
CONSOLEMAP=8859-1
FONT_MAP=8859-1_to_uni
EOF

install -Dm644 /dev/stdin etc/locale.conf <<EOF
LANG=en_US.UTF-8
LC_COLLATE=C
EOF

install -dm755 etc/systemd/system/multi-user.target.wants
ln -s /usr/lib/systemd/system/getty@.service     etc/systemd/system/multi-user.target.wants/getty@tty1.service
ln -s /usr/lib/systemd/system/haveged.service    etc/systemd/system/multi-user.target.wants/haveged.service
ln -s /usr/lib/systemd/system/irqbalance.service etc/systemd/system/multi-user.target.wants/irqbalance.service

}

post_install() {
	sed -i 's/^#(en_US\.UTF-8)/\1/' etc/locale.gen
	locale-gen
}

pre_remove() {
	sed -i 's/^[^#]/#&/' etc/locale.gen
	locale-gen
}