Skip to content

Bashism in systemd-hook

Description:

This line in /usr/share/libalpm/scripts/systemd-hook contains a bashism:

if ! systemd-notify --booted &>/dev/null; then

Please consider making it POSIX-compliant:

if ! systemd-notify --booted > /dev/null 2>&1; then

On my system, /bin/sh is linked to dash so I keep getting "Current root is not booted" messages when using pacman.

:: Running post-transaction hooks...
( 1/10) Reloading system manager configuration...
  Skipped: Current root is not booted.
( 2/10) Reloading user manager configuration...
  Skipped: Current root is not booted.
( 3/10) Updating udev hardware database...
( 4/10) Reloading device manager configuration...
( 5/10) Arming ConditionNeedsUpdate...
( 6/10) Reloading system bus configuration...
  Skipped: Current root is not booted.
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information