diff options
Diffstat (limited to 'source/installer/sources/initrd/usr/lib/setup/unmigrate.sh')
-rwxr-xr-x | source/installer/sources/initrd/usr/lib/setup/unmigrate.sh | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/source/installer/sources/initrd/usr/lib/setup/unmigrate.sh b/source/installer/sources/initrd/usr/lib/setup/unmigrate.sh new file mode 100755 index 000000000..fa374bcd6 --- /dev/null +++ b/source/installer/sources/initrd/usr/lib/setup/unmigrate.sh @@ -0,0 +1,13 @@ +#!/bin/sh +# +# This resets the temporary directory to /tmp on the floppy in the +# case where it's been changed during a previous 'setup' run. This +# should be done before $TMP is cleared. +# + +TMPLINK="`LC_ALL=C /bin/ls -l /var/log/setup/tmp | tr -s ' ' | cut -f 11 -d ' '`" +if [ -L /var/log/setup/tmp -a ! "$TMPLINK" = "/tmp" ]; then + ( cd /var/log/setup + rm tmp + ln -sf /tmp tmp ) +fi |