Skip to content

Commit

Permalink
upgrade: Check if /boot/initramfs-linux-lts.img exists
Browse files Browse the repository at this point in the history
This doesn't exist for, for example, WSL.
  • Loading branch information
cdown committed Aug 9, 2023
1 parent dd43c73 commit 6803e4b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion bin/upgrade
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ fi
# modules won't get built, so you can't even login.
#
# TODO: Fix this upstream...
if ! sudo zstd -d -c /boot/initramfs-linux-lts.img | grep -q kernel/drivers/hid/usbhid/; then
if [[ -e /boot/initramfs-linux-lts.img ]] && ! sudo zstd -d -c /boot/initramfs-linux-lts.img | grep -q kernel/drivers/hid/usbhid/; then
printf '%s%s%s%s\n' \
"$(tput setaf 1)" "$(tput blink)" "module build bug, please rebuild kernel initramfs" "$(tput sgr0)"
exit 1
Expand Down

0 comments on commit 6803e4b

Please sign in to comment.