All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 01/31] Some dracut cleanups and bashification.
@ 2009-02-09  0:34 Victor Lowther
       [not found] ` <5a1ca330d81aeebf879bb7f0950b7ae448f7be22.1234137267.git.victor.lowther-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
  0 siblings, 1 reply; 39+ messages in thread
From: Victor Lowther @ 2009-02-09  0:34 UTC (permalink / raw)
  To: initramfs-u79uwXL29TY76Z2rM5mHXA

Hi, I enjoy hacking on system infrastructure and am a bash programming 
aficionado. With that in mind, I present this patch series against current
master -- it simplifies several bits of code and shaves about 200 lines out
of the codebase.  The final result has been tested on a Fedora 10 box that
uses lvm on top of dm-crypt, and it works fine.  I have not tested all
intermediate steps -- life is too short.

Comments, flames, commit access to the repo welcome.

These patches are also availble at http://git.fnordovax.org/dracut/ 

We have a path.  Do not specify full paths to commands that are in it.

---
 init |   16 ++++++++--------
 1 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/init b/init
index 706127f..eb8998d 100755
--- a/init
+++ b/init
@@ -7,18 +7,18 @@
 
 emergency_shell()
 {
-    [ -x /bin/plymouth ] && /bin/plymouth --hide-splash
+    [ -x /bin/plymouth ] && plymouth --hide-splash
     echo ; echo
     echo "Bug in initramfs /init detected. Dropping to a shell. Good luck!"
     echo
     bash < /dev/console
 }
-trap "emergency_shell" 0 2
 
 echo "Starting initrd..."
 export PATH=/sbin:/bin:/usr/sbin:/usr/bin
 export TERM=linux
 
+trap "emergency_shell" 0 2
 # /dev/console comes from the built-in initramfs crud in the kernel
 # someday, we may need to mkdir /dev first here
 exec > /dev/console 2>&1 < /dev/console
@@ -38,13 +38,13 @@ mknod /dev/tty1 c 4 1
 
 # start plymouth if it's available
 # arguably we need some of udev run first for fbmods and above devnodes :/
-[ -x /bin/plymouthd ] && /bin/plymouthd --attach-to-session
-[ -x /bin/plymouth ] && /bin/plymouth --show-splash
+[ -x /bin/plymouthd ] && plymouthd --attach-to-session
+[ -x /bin/plymouth ] && plymouth --show-splash
 
 
 # start up udev and trigger cold plugs
-/sbin/udevd --daemon
-/sbin/udevadm trigger
+udevd --daemon
+udevadm trigger
 
 # mount the rootfs
 NEWROOT="/sysroot"
@@ -108,10 +108,10 @@ fi
 # kill off udev
 kill `pidof udevd`
 
-[ -x /bin/plymouth ] && /bin/plymouth --newroot=$NEWROOT
+[ -x /bin/plymouth ] && plymouth --newroot=$NEWROOT
 
 # FIXME: nash die die die
-exec /sbin/switch_root
+exec switch_root
 # davej doesn't like initrd bugs
 echo "Something went very badly wrong in the initrd.  Please "
 echo "file a bug against mkinitrd."
-- 
1.6.0.6

--
To unsubscribe from this list: send the line "unsubscribe initramfs" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply related	[flat|nested] 39+ messages in thread

end of thread, other threads:[~2009-02-10 16:56 UTC | newest]

Thread overview: 39+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-02-09  0:34 [PATCH 01/31] Some dracut cleanups and bashification Victor Lowther
     [not found] ` <5a1ca330d81aeebf879bb7f0950b7ae448f7be22.1234137267.git.victor.lowther-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2009-02-09  0:34   ` [PATCH 02/31] " Victor Lowther
2009-02-09  0:34   ` [PATCH 03/31] " Victor Lowther
2009-02-09  0:34   ` [PATCH 04/31] " Victor Lowther
2009-02-09  0:35   ` [PATCH 05/31] " Victor Lowther
2009-02-09  0:35   ` [PATCH 06/31] " Victor Lowther
2009-02-09  0:35   ` [PATCH 07/31] " Victor Lowther
2009-02-09  0:35   ` [PATCH 08/31] " Victor Lowther
2009-02-09  0:35   ` [PATCH 09/31] " Victor Lowther
2009-02-09  0:35   ` [PATCH 10/31] " Victor Lowther
2009-02-09  0:35   ` [PATCH 11/31] " Victor Lowther
2009-02-09  0:35   ` [PATCH 12/31] " Victor Lowther
2009-02-09  0:35   ` [PATCH 13/31] " Victor Lowther
2009-02-09  0:35   ` [PATCH 14/31] " Victor Lowther
2009-02-09  0:35   ` [PATCH 15/31] " Victor Lowther
2009-02-09  0:35   ` [PATCH 16/31] " Victor Lowther
2009-02-09  0:35   ` [PATCH 17/31] " Victor Lowther
2009-02-09  0:36   ` [PATCH 18/31] " Victor Lowther
2009-02-09  0:36   ` [PATCH 19/31] " Victor Lowther
2009-02-09  0:36   ` [PATCH 20/31] " Victor Lowther
2009-02-09  0:36   ` [PATCH 21/31] " Victor Lowther
     [not found]     ` <f81e4c7fec7010a32da9bd6e98c19eec70874af0.1234137268.git.victor.lowther-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2009-02-09  9:15       ` Karel Zak
2009-02-09  0:36   ` [PATCH 22/31] " Victor Lowther
2009-02-09  0:36   ` [PATCH 23/31] " Victor Lowther
     [not found]     ` <f393f138baf78d7bf99d31a4912b6ae313f1842f.1234137268.git.victor.lowther-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2009-02-09  9:24       ` Karel Zak
2009-02-09  0:36   ` [PATCH 24/31] " Victor Lowther
2009-02-09  0:36   ` [PATCH 25/31] " Victor Lowther
2009-02-09  0:36   ` [PATCH 26/31] " Victor Lowther
2009-02-09  0:36   ` [PATCH 27/31] " Victor Lowther
2009-02-09  0:36   ` [PATCH 28/31] " Victor Lowther
2009-02-09  0:36   ` [PATCH 29/31] " Victor Lowther
2009-02-09  0:36   ` [PATCH 30/31] " Victor Lowther
2009-02-09  0:37   ` [PATCH 31/31] " Victor Lowther
2009-02-09 17:15   ` [PATCH 01/31] " Dave Jones
     [not found]     ` <20090209171521.GA3646-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2009-02-09 18:57       ` Victor Lowther
     [not found]         ` <7FE9B1BD-31DA-4605-9881-3C42A05075E3-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2009-02-09 19:13           ` Dave Jones
     [not found]             ` <20090209191333.GA8665-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2009-02-09 21:32               ` Victor Lowther
2009-02-10 12:17           ` maximilian attems
     [not found]             ` <20090210121745.GC15532-U9r9yeDMy7A@public.gmane.org>
2009-02-10 16:56               ` Victor Lowther

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.