#!/bin/bash # # This script is put in the background by after-dnf-start and gets # the pid of the dnf command as an argument. It waits for the dnf # command to exit then runs the after-dnf-hooks script which contains # any user defined commands desired to be run following a dnf update. # # I don't know if it is necessary here, but my udev scripts weren't # fully backgrounded till I turned them into "user" tasks, so I'll # do the same here just to be paranoid. echo $$ > /sys/fs/cgroup/systemd/user.slice/tasks # Wait for the dnf command to exit if /usr/local/bin/wait-for-pid "$1" then /usr/local/bin/after-dnf-hooks fi