Implement -D option to set configuration directory; fai.conf: don't set variables...
[grml-live-grml.git] / etc / grml / fai / config / scripts / GRMLBASE / 10-build-initramfs
index ea21a6a..b85fc80 100755 (executable)
@@ -1,11 +1,12 @@
 #!/bin/bash
-# Filename:      /etc/grml/fai/config/scripts/GRMLBASE/10-build-initramfs
+# Filename:      ${GRML_FAI_CONFIG}/config/scripts/GRMLBASE/10-build-initramfs
 # Purpose:       configure live-initramfs and build initramfs for booting
 # Authors:       grml-team (grml.org), (c) Michael Prokop <mika@grml.org>
 # Bug-Reports:   see http://grml.org/bugs/
 # License:       This file is licensed under the GPL v2 or any later version.
 ################################################################################
 
+set -u
 set -e
 
 fcopy /usr/share/initramfs-tools/scripts/init-top/grml
@@ -13,11 +14,11 @@ fcopy /etc/initramfs-tools/hooks/000-udev-shutup
 fcopy /etc/initramfs-tools/conf.d/xz-compress
 
 if ! [ -f $target/usr/share/initramfs-tools/scripts/live ] ; then
-   echo "Error: live-boot/-initramfs does not seem to be present, can not create initramfs. Exiting.">&2
-   exit 1
+  echo "Error: live-boot/-initramfs does not seem to be present, can not create initramfs. Exiting.">&2
+  exit 1
 fi
 
 # The initramfs itself will be created through grml-live script itself.
 
 ## END OF FILE #################################################################
-# vim:ft=sh expandtab ai tw=80 tabstop=4 shiftwidth=3
+# vim:ft=sh expandtab ai tw=80 tabstop=4 shiftwidth=2