Created
March 26, 2017 07:20
-
-
Save ziozzang/fe432759044cceead13835e8fd67df01 to your computer and use it in GitHub Desktop.
Purge / Install new kernel for Ubuntu
This file contains 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/bash | |
sudo add-apt-repository ppa:kernel-ppa/ppa | |
sudo apt-get update | |
sudo apt-get upgrade | |
#Purge old Kernel | |
sudo apt-get purge $(dpkg -l linux-{image,headers}-"[0-9]*" | awk '/ii/{print $2}' | grep -ve "$(uname -r | sed -r 's/-[a-z]+//')") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment