/usr/share/initramfs-tools/modules looks like it could be a live
configuration file, but it is not. Add a short comment to the file,
then strip it when copying to /etc/initramfs-tools.
Closes: #752789
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
---
conf/modules | 3 +++
debian/initramfs-tools.postinst | 3 ++-
2 files changed, 5 insertions(+), 1 deletion(-)
diff --git a/conf/modules b/conf/modules
index dd9dc54..a229e4d 100644
--- a/conf/modules
+++ b/conf/modules
@@ -1,3 +1,6 @@
+### This file is the template for /etc/initramfs-tools/modules.
+### It is not a configuration file itself.
+###
# List of modules that you want to include in your initramfs.
# They will be loaded at boot time in the order below.
#
diff --git a/debian/initramfs-tools.postinst b/debian/initramfs-tools.postinst
index 160e68a..9526cf7 100644
--- a/debian/initramfs-tools.postinst
+++ b/debian/initramfs-tools.postinst
@@ -3,7 +3,8 @@
set -e
if [ ! -e /etc/initramfs-tools/modules ]; then
- cp /usr/share/initramfs-tools/modules /etc/initramfs-tools/
+ sed '/^###/d' /usr/share/initramfs-tools/modules \
+ > /etc/initramfs-tools/modules
fi
# Regenerate initramfs whenever we go to dpkg state `installed'
--
Ben Hutchings
Life is what happens to you while you're busy making other plans.
- John Lennon
Attachment:
signature.asc
Description: This is a digitally signed message part