diff -Naur event.d.orig/bootclean event.d/bootclean --- event.d.orig/bootclean 2007-04-14 11:53:18.000000000 +0200 +++ event.d/bootclean 2007-04-29 14:44:53.000000000 +0200 @@ -6,7 +6,7 @@ console output script - echo "Cleaning /tmp, /var/lock, /var/run" + initmsg msg "Cleaning /tmp, /var/lock, /var/run" EXCEPT='! -name . ! ( -path ./lost+found -uid 0 ) ! ( -path ./quota.user -uid 0 ) @@ -44,4 +44,5 @@ chmod 755 / 2> /dev/null || true chmod 1777 /tmp /var/tmp || true + initmsg ret $? "Removal of /tmp, /var/lock, /var/run" end script diff -Naur event.d.orig/fsck event.d/fsck --- event.d.orig/fsck 2007-04-14 11:53:18.000000000 +0200 +++ event.d/fsck 2007-04-28 23:51:24.000000000 +0200 @@ -87,13 +87,8 @@ # Fix /etc/mtab to list sys and proc if they were not yet entered in # /etc/mtab because / was still mounted read-only: - if [ -d /proc/sys ]; then - mount -f proc /proc -t proc - fi - - if [ -d /sys/bus ]; then - mount -f sysfs /sys -t sysfs - fi + mountpoint -q /proc || mount -f proc /proc -t proc + mountpoint -q /sys || mount -f sysfs /sys -t sysfs mount -f -t tmpfs tmpfs /dev/shm mount -f -t devpts -omode=0620,gid=5 devpts /dev/pts diff -Naur event.d.orig/hostname event.d/hostname --- event.d.orig/hostname 2007-04-14 11:53:18.000000000 +0200 +++ event.d/hostname 2007-04-29 14:54:36.000000000 +0200 @@ -12,6 +12,7 @@ fi hostname=`cat /etc/HOSTNAME | cut -f1 -d .` - echo "Setting hostname to '$hostname'" + initmsg msg "Setting hostname to '$hostname'" /bin/hostname "$hostname" + initmsg ret $? "Update of hostname to '$hostname'" end script diff -Naur event.d.orig/hwclock event.d/hwclock --- event.d.orig/hwclock 2007-04-14 11:53:18.000000000 +0200 +++ event.d/hwclock 2007-04-29 14:38:21.000000000 +0200 @@ -10,20 +10,22 @@ pre-start script if [ -e /etc/hardwareclock ]; then - echo "Setting system time from the hardware clock" + initmsg msg "Setting system time from the hardware clock" if grep -q "^UTC" /etc/hardwareclock ; then /sbin/hwclock --utc --hctosys else /sbin/hwclock --localtime --hctosys fi + initmsg ret $? "Update of system time based on the hardware clock" fi end script post-stop script - echo "Saving system time to the hardware clock" + initmsg msg "Saving system time to the hardware clock" if grep -q "^UTC" /etc/hardwareclock ; then /sbin/hwclock --utc --systohc else /sbin/hwclock --localtime --systohc fi + initmsg ret $? "Update of the hardware clock based on the system time" end script diff -Naur event.d.orig/keymap event.d/keymap --- event.d.orig/keymap 2007-04-14 11:53:18.000000000 +0200 +++ event.d/keymap 2007-04-28 23:44:27.000000000 +0200 @@ -11,7 +11,7 @@ if [ ! -z ${keymap} ] ; then loadkeys ${keymap} 2> /dev/null else - echo ">> You haven't set a keymap in /etc/sysconfig/keymap" + hint "You haven't set a keymap in /etc/sysconfig/keymap" fi fi end script diff -Naur event.d.orig/load-modules event.d/load-modules --- event.d.orig/load-modules 2007-04-14 11:53:18.000000000 +0200 +++ event.d/load-modules 2007-04-29 14:43:44.000000000 +0200 @@ -13,12 +13,13 @@ # Read configuration file and load modules if [ -r /etc/sysconfig/modules ]; then - echo "Loading modules..." + initmsg msg "Loading modules..." grep '^[^#]' /etc/sysconfig/modules | \ while read module args; do [ -n "$module" ] || continue modprobe "$module" "$args" || true done + initmsg ret $? "Module loading" fi end script diff -Naur event.d.orig/mount event.d/mount --- event.d.orig/mount 2007-04-14 11:53:19.000000000 +0200 +++ event.d/mount 2007-04-29 14:45:36.000000000 +0200 @@ -13,14 +13,16 @@ # Check all the non-root filesystems. if ! [ -r /etc/fastboot ]; then - echo "Checking non-root filesystems" + initmsg msg "Checking non-root filesystems" /sbin/fsck $ffsck -T -C -R -A -a || true + initmsg ret $? "Check of non-root filesystems" fi # Mount non-root file systems in fstab (but not NFS or SMB # because TCP/IP is not yet configured). - echo "Mounting local filesystems" + initmsg msg "Mounting local filesystems" mount -a -t nonfs,nosmbfs,noproc,nosysfs,nofuse,nontfs-3g || true + initmsg ret $? "Mount of local filesystems" # Clean up some temporary files. /bin/rm -f /var/run/utmp /var/run/*pid /etc/nologin /var/run/lpd* \ diff -Naur event.d.orig/random event.d/random --- event.d.orig/random 2007-04-14 11:53:19.000000000 +0200 +++ event.d/random 2007-04-29 14:56:05.000000000 +0200 @@ -9,13 +9,14 @@ service pre-start script - echo "Initializing /dev/urandom" + initmsg msg "Initializing /dev/urandom" if [ -f /etc/random-seed ]; then cat /etc/random-seed >/dev/urandom || true fi dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2> /dev/null || true + initmsg ret $? "Initialization of /dev/urandom" end script post-stop script diff -Naur event.d.orig/shutdown event.d/shutdown --- event.d.orig/shutdown 2007-04-14 11:53:19.000000000 +0200 +++ event.d/shutdown 2007-04-29 14:56:58.000000000 +0200 @@ -27,18 +27,22 @@ # Exterminate any lil' process that managed to evade my merciless # terminating. - echo "Sending all processes the SIGTERM signal" + initmsg msg "Sending all processes the SIGTERM signal" killall5 -15 || true + initmsg ret $? "Sending all processes the SIGTERM signal" - echo "Sending all processes the SIGKILL signal" + initmsg msg "Sending all processes the SIGKILL signal" sleep 5 killall5 -9 || true + initmsg ret $? "Sending all processes the SIGKILL signal" - echo "Unmounting local filesystems..." + initmsg msg "Unmounting local filesystems..." umount -a -r -t nonfs,noumsdos,nosmbfs,noproc,nofuse,nofuseblk || true + initmsg ret $? "Unmount of the local filesystems" - echo "Remounting root filesystem read-only" + initmsg msg "Remounting root filesystem read-only" mount -n -o remount,ro / || true + initmsg ret $? "Remount of the root filesystem read-only" # It's unlikely that this isn't set, but you never know what crazy # stuff some people manage to do... Reboot if it's not set diff -Naur event.d.orig/udevtrigger event.d/udevtrigger --- event.d.orig/udevtrigger 2007-04-14 11:53:19.000000000 +0200 +++ event.d/udevtrigger 2007-04-29 14:47:32.000000000 +0200 @@ -8,13 +8,15 @@ script # Traverse /sys in order to coldplug devices that have # already been discovered - echo "Detecting hardware..." + initmsg msg "Detecting hardware..." mkdir -p /dev/.udev/queue /sbin/udevtrigger || true + initmsg ret $? "Hardware detection" # Now wait for udevd to process the uevents we triggered - echo "Processing detected hardware..." + initmsg msg "Processing detected hardware..." /sbin/udevsettle || true + initmsg ret $? "Processing detected hardware" - mount -n -t usbfs -o devgid=23,devmode=664 usbfs /proc/bus/usb || true + mountpoint -q /proc/bus/usb || mount -n -t usbfs -o devgid=23,devmode=664 usbfs /proc/bus/usb end script diff -Naur event.d.orig/welcome event.d/welcome --- event.d.orig/welcome 2007-04-28 22:52:58.000000000 +0200 +++ event.d/welcome 2007-04-29 00:11:24.000000000 +0200 @@ -6,11 +6,12 @@ console output script - if [ -r /etc/frugalware-release ]; then - echo -e "\033[1;34m>> \033[1;37mWelcome to $(cat /etc/frugalware-release)!\033[1;0m " - else - echo -e "\033[1;34m>> \033[1;37mWelcome to Frugalware Linux!\033[1;0m " - fi - echo -e "\033[1;34m>> \033[1;37mCopyright (C) 2004-2007 Frugalware Developer Team\033[1;0m " - echo + fwgreet="\e[01mWelcome to \e[01;36mFrugalware\e[0m\e[01m Linux!\e[0m" + ((spaces=(($(tput cols) - $(echo -n ${fwgreet} | wc -m) + 24)) / 2)) + echo -e "\n" + for i in $(seq 1 ${spaces}) + do + echo -n ' ' + done + echo -e "${fwgreet}\n" end script