Skip to content

Commit 01fcf88

Browse files
committed
Merge remote-tracking branch 'origin/pull/294'
* origin/pull/294: only remove entries if they are there
2 parents cdedae4 + 5106d1e commit 01fcf88

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

contrib/kernel-install/91-sbctl.install

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,10 @@ add)
3939
sbctl sign -s "$IMAGE_FILE" 1>/dev/null
4040
;;
4141
remove)
42-
[ "$KERNEL_INSTALL_VERBOSE" -gt 0 ] &&
42+
if [[ -e "$IMAGE_FILE" ]]; then
43+
[ "$KERNEL_INSTALL_VERBOSE" -gt 0 ] &&
4344
printf 'sbctl: Removing kernel %s from signing database\n' "$IMAGE_FILE"
44-
sbctl remove-file "$IMAGE_FILE" 1>/dev/null
45+
sbctl remove-file "$IMAGE_FILE" 1>/dev/null
46+
fi
4547
;;
4648
esac

0 commit comments

Comments
 (0)