diff --git a/trunk/PKGBUILD b/trunk/PKGBUILD index b8561119..97d0c1c9 100644 --- a/trunk/PKGBUILD +++ b/trunk/PKGBUILD @@ -3,14 +3,14 @@ pkgname=filesystem pkgver=2021.11.11 -pkgrel=1 +pkgrel=2 pkgdesc='Base Arch Linux files' arch=('x86_64') license=('GPL') url='https://archlinux.org' depends=('iana-etc') backup=('etc/crypttab' 'etc/fstab' 'etc/group' 'etc/gshadow' 'etc/host.conf' - 'etc/hosts' 'etc/issue' 'etc/ld.so.conf' 'etc/motd' 'etc/nsswitch.conf' + 'etc/hosts' 'etc/issue' 'etc/ld.so.conf' 'etc/nsswitch.conf' 'etc/passwd' 'etc/profile' 'etc/resolv.conf' 'etc/securetty' 'etc/shadow' 'etc/shells') source=('crypttab' 'env-generator' 'fstab' 'group' 'gshadow' 'host.conf' 'hosts' @@ -18,6 +18,7 @@ source=('crypttab' 'env-generator' 'fstab' 'group' 'gshadow' 'host.conf' 'hosts' 'passwd' 'profile' 'resolv.conf' 'securetty' 'shadow' 'shells' 'sysctl' 'sysusers' 'tmpfiles' 'archlinux-logo.svg' 'archlinux-logo.png' 'archlinux-logo-text.svg' 'archlinux-logo-text-dark.svg') +install="$pkgname.install" sha256sums=('e03bede3d258d680548696623d5979c6edf03272e801a813c81ba5a5c64f4f82' 'ed0cb4f1db4021f8c3b5ce78fdf91d2c0624708f58f36c9cf867f4d93c3bc6da' 'e54626e74ed8fee4173b62a545ab1c3a3a069e4217a0ee8fc398d9933e9c1696' @@ -39,7 +40,7 @@ sha256sums=('e03bede3d258d680548696623d5979c6edf03272e801a813c81ba5a5c64f4f82' 'c390b31fffc4a2b5d78ae8c89f5317aadef1f71baac09cfb467b675db1406d61' '89e43a0b7028f52d5c8e7fb961d962c4b4f4e9595880a6157274ddb2c7c0b6b4' 'b5b28f395583d141d88c0b955cd05124f9b8cdf003feab01e55885b8e8c1303e' - '618ac097441c1f2daffc9967e5c3cd18ea8866f776db62d04bf401c53907b1c9' + 'f17efd1c6480c5db1fdab4a0e3cfcd4baa44a3e1ae1210aebeb40f8d5c82f742' '3ffe8ea4e98db43a3ec4dcca55fd4009cd8b8d220f0996aef7a5b427fdf65234' '3f48779141b68a81e07fee710a42025d4f67b16240295aa4cf148a7ba99cab3c' '601069e6e8920309178c397fd8cebe43410827d01899d31777d13212f0dfacf8' @@ -62,7 +63,7 @@ package() { # setup /etc and /usr/share/factory/etc install -d etc/{ld.so.conf.d,skel,profile.d} usr/share/factory/etc - for f in fstab group host.conf hosts issue ld.so.conf motd nsswitch.conf \ + for f in fstab group host.conf hosts issue ld.so.conf nsswitch.conf \ passwd resolv.conf securetty shells profile; do install -m644 "$srcdir"/$f etc/ install -m644 "$srcdir"/$f usr/share/factory/etc/ @@ -126,6 +127,9 @@ package() { # setup systemd.environment-generator install -D -m755 "$srcdir"/env-generator usr/lib/systemd/system-environment-generators/10-arch + # setup motd + install -m644 "$srcdir"/motd usr/lib/motd + # add logo install -D -m644 "$srcdir"/archlinux-logo{.png,.svg,-text.svg,-text-dark.svg} usr/share/pixmaps } diff --git a/trunk/filesystem.install b/trunk/filesystem.install new file mode 100644 index 00000000..296ddac3 --- /dev/null +++ b/trunk/filesystem.install @@ -0,0 +1,8 @@ +post_upgrade() { + # restore custom /etc/motd after the file was removed from the backup array + if (( $(vercmp "$1" '2021.11.11-2') <= 0 )); then + if [[ -e /etc/motd.pacsave ]]; then + mv /etc/motd.pacsave /etc/motd + fi + fi +} diff --git a/trunk/tmpfiles b/trunk/tmpfiles index 8fc77b57..4b5368f8 100644 --- a/trunk/tmpfiles +++ b/trunk/tmpfiles @@ -8,7 +8,6 @@ C /etc/host.conf C /etc/hosts C /etc/issue C /etc/ld.so.conf -C /etc/motd C /etc/nsswitch.conf C /etc/passwd C /etc/profile