diff options
author | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2022-05-30 10:27:14 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-05-30 10:27:14 +0200 |
commit | 02ece2fcb139b92b2974a31bd353505f2dedb44d (patch) | |
tree | 237927d79b8dc571e65e677202753ef4a0b7da32 | |
parent | 5476cb988c111e91befe5cc6ff5106ce9a003645 (diff) | |
parent | 2f9f8b96d41bc0787f53dcc01c1488fcdc735e9b (diff) | |
download | systemd-02ece2fcb139b92b2974a31bd353505f2dedb44d.tar.gz |
Merge pull request #23529 from nabijaczleweli/dollar-asterisk
Don't linebreak after each initrd in kernel-install verbose mode
-rwxr-xr-x | src/kernel-install/kernel-install.in | 21 |
1 files changed, 7 insertions, 14 deletions
diff --git a/src/kernel-install/kernel-install.in b/src/kernel-install/kernel-install.in index 9296bfcd8e..2e1965852e 100755 --- a/src/kernel-install/kernel-install.in +++ b/src/kernel-install/kernel-install.in @@ -80,12 +80,13 @@ fi if [ "${0##*/}" = "installkernel" ]; then COMMAND=add - # make install doesn't pass any initrds - no_initrds=1 + # kernel's install.sh invokes us as + # /sbin/installkernel <version> <vmlinuz> <map> <installation-dir> + # We ignore the last two arguments. + set -- "$1" else COMMAND="$1" [ $# -ge 1 ] && shift - no_initrds=0 fi if [ "$COMMAND" = "inspect" ]; then @@ -323,16 +324,8 @@ case "$COMMAND" in fi for f in $PLUGINS; do - if [ "$no_initrds" = 1 ]; then - # kernel's install.sh invokes us as - # /sbin/installkernel <version> <vmlinuz> <map> <installation-dir> - # We ignore the last two arguments. - [ "$KERNEL_INSTALL_VERBOSE" -gt 0 ] && echo "+$f add $KERNEL_VERSION $ENTRY_DIR_ABS $1" - "$f" add "$KERNEL_VERSION" "$ENTRY_DIR_ABS" "$1" - else - [ "$KERNEL_INSTALL_VERBOSE" -gt 0 ] && echo "+$f add $KERNEL_VERSION $ENTRY_DIR_ABS $*" - "$f" add "$KERNEL_VERSION" "$ENTRY_DIR_ABS" "$@" - fi + [ "$KERNEL_INSTALL_VERBOSE" -gt 0 ] && echo "+$f add $KERNEL_VERSION $ENTRY_DIR_ABS" "$@" + "$f" add "$KERNEL_VERSION" "$ENTRY_DIR_ABS" "$@" err=$? [ $err -eq $skip_remaining ] && break @@ -365,8 +358,8 @@ case "$COMMAND" in # Assert that ENTRY_DIR_ABS actually matches what we are printing here [ "${ENTRY_DIR_ABS%/*}" = "$KERNEL_INSTALL_BOOT_ROOT/$ENTRY_TOKEN" ] || { echo "Assertion didn't pass." >&2; exit 1; } - ;; + *) echo "Error: unknown command '$COMMAND'" >&2 exit 1 |