Last active
October 22, 2021 19:18
-
-
Save konstruktoid/b487ccfe1f957e86a09d0a5b5856df80 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
RELEASE_DATE= | |
for p in $(curl -sSL 'https://kernel.ubuntu.com/~kernel-ppa/mainline/daily/current/HEADER.html' | grep -E '.*all\.deb|.*generic.*amd64\.deb' | sed -e 's/.*ref="//g' -e 's/">.*//g'| sort | uniq); do | |
wget -nc "https://kernel.ubuntu.com/~kernel-ppa/mainline/daily/current/$p" | |
RELEASE_DATE="$(echo "$p" | awk -F '.' '{print $6}' | sed 's/_.*//g')" | |
done | |
if ! dpkg -l | grep -qE "linux.*$RELEASE_DATE.*"; then | |
find . -name "*modules*$RELEASE_DATE*.deb" -type f | while read -r m; do | |
sudo dpkg -i "$m" | |
done | |
find . -name "*$RELEASE_DATE*.deb" -type f | while read -r f; do | |
sudo dpkg -i "$f" | |
done | |
sudo update-grub2 | |
else | |
echo "Daily Current kernel seems to be installed already." | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment