mirror of
https://salsa.debian.org/kernel-team/initramfs-tools.git
synced 2026-01-26 07:37:54 +00:00
update-initramfs: use "set -u"
Support `set -u` in update-initramfs and use it.
This commit is contained in:
parent
27544d4a9c
commit
afb3ba3ac6
@ -1,5 +1,5 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
set -e
|
set -eu
|
||||||
|
|
||||||
BOOTDIR=/boot
|
BOOTDIR=/boot
|
||||||
CONF=/etc/initramfs-tools/update-initramfs.conf
|
CONF=/etc/initramfs-tools/update-initramfs.conf
|
||||||
@ -10,7 +10,7 @@ backup_initramfs=no
|
|||||||
|
|
||||||
[ -r ${CONF} ] && . ${CONF}
|
[ -r ${CONF} ] && . ${CONF}
|
||||||
|
|
||||||
if [ -n "$DPKG_MAINTSCRIPT_PACKAGE" ] && [ $# = 1 ] && [ "$1" = -u ]; then
|
if [ -n "${DPKG_MAINTSCRIPT_PACKAGE-}" ] && [ $# = 1 ] && [ "$1" = -u ]; then
|
||||||
if dpkg-trigger --no-await update-initramfs; then
|
if dpkg-trigger --no-await update-initramfs; then
|
||||||
echo "update-initramfs: deferring update (trigger activated)"
|
echo "update-initramfs: deferring update (trigger activated)"
|
||||||
# The /run/update-initramfs.dpkg-trigger file is just a workaround.
|
# The /run/update-initramfs.dpkg-trigger file is just a workaround.
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user