Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Version aware sorting of kernels in post kernel install hook #15

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions guides/new_uki.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ You can write a boot entry into your bios nVRAM directly, to boot the UKI.

I use my nvme0n1 drive and its first partition, which is mounted on ```/boot/efi```.

## The post kernel intsall hook
## The post kernel install hook

All you need to get this process automatically done every time is to place a hook in ```/etc/kernel/postinst.d```.

Expand All @@ -62,7 +62,7 @@ I use [gdamjan's script from here](https://gist.github.com/gdamjan/ccdcda2c91119

# Our kernels.
KERNELS=()
FIND="find /boot/efi -maxdepth 3 -name 'linux*' -type f -print0 | sort -rz"
FIND="find /boot/efi -maxdepth 3 -name 'linux*' -type f -print0 | sort -Vrz"
while IFS= read -r -u3 -d $'\0' LINE; do
KERNEL=$(dirname "${LINE}")
KERNELS+=("${KERNEL}")
Expand Down