updated on Wed Jan 18 08:00:29 UTC 2012
[aur-mirror.git] / systemd-arch-units-git / systemd-arch-units.install
blob7d671a781d9bbbf7ce4c28a01a6336cd1d3a8f59
1 #!/bin/bash
3 ## arg 1: the new package version
4 post_install() {
5 cat << EOF
6 -- NOTICE --------------------------------------------------------------------------
7 All unit files have been installed to /lib/systemd/system. This only allows systemd
8 to be aware of them. It will not register them for automatic activation on boot. Use
9 'systemctl enable <unit>' to ensure that a unit is started at boot.
10 ------------------------------------------------------------------------------------
11 EOF
13 # this might be installed at the same time as systemd which means that it's
14 # not running yet. the daemon-reload call will fail with a bogus error.
15 post_upgrade 2>/dev/null
18 post_upgrade() {
19 # reread all known unit files
20 ps hp 1 o command | {
21 read -r argv0 _
22 [[ "$argv0" = "/bin/systemd" ]] && systemctl daemon-reload || :
23 } || :
24 } >/dev/null 2>&1
26 # vim:set ts=2 sw=2 et: