pkg: fedora: Use the file creation time to determine the newest kernel

This commit is contained in:
Dorian Stoll 2023-06-14 17:36:24 +02:00
parent 130f855120
commit 39d0d5ec60
No known key found for this signature in database
GPG key ID: F1DACD02C619442A

View file

@ -2,7 +2,7 @@
set -euo pipefail
# get list of surface kernels with timestamp
kernels=$(find /boot -maxdepth 1 -name "vmlinuz-*.surface.*" -printf '%T@\t%p\n')
kernels=$(find /boot -maxdepth 1 -name "vmlinuz-*.surface.*" -printf '%B@\t%p\n')
# sort by timestamp
kernels=$(echo "${kernels}" | sort -n)