diff options
| author | Martin Whitaker <xxxx@martin-whitaker.me.uk> | 2025-12-25 16:54:30 +0000 |
|---|---|---|
| committer | Martin Whitaker <xxxx@martin-whitaker.me.uk> | 2025-12-25 16:54:30 +0000 |
| commit | 6cc273d2b093be559c0ef55084e434446e641c71 (patch) | |
| tree | 310319c155515e12cac084b989f98e8bebfd9027 | |
| parent | ef521298d22c8e40ba6c1c94176e02e577a93007 (diff) | |
| download | mageia-dracut-conf-0.5.tar mageia-dracut-conf-0.5.tar.gz mageia-dracut-conf-0.5.tar.bz2 mageia-dracut-conf-0.5.tar.xz mageia-dracut-conf-0.5.zip | |
Restore test for /run/mgalive/installed in mgalive-shutdown.sh.0.5
We want to eject the Live media on shutdown if draklive-install has
been run, to ensure the machine reboots into the newly installed
system. The code to do this was lost when it was moved from svn to
git.
| -rw-r--r-- | modules.d/90mgalive/mgalive-shutdown.sh | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/modules.d/90mgalive/mgalive-shutdown.sh b/modules.d/90mgalive/mgalive-shutdown.sh index d587fb0..a4d3656 100644 --- a/modules.d/90mgalive/mgalive-shutdown.sh +++ b/modules.d/90mgalive/mgalive-shutdown.sh @@ -1,7 +1,7 @@ #!/usr/bin/sh basedev=$(cat /run/mgalive/basedev) -if strstr "$basedev" "/dev/sr" ; then +if [ -e /run/mgalive/installed ] || strstr "$basedev" "/dev/sr" ; then exec < /dev/tty0 > /dev/tty0 eject $basedev clear @@ -10,4 +10,3 @@ if strstr "$basedev" "/dev/sr" ; then read -t 30 a fi return 0 - |
