Skip to content

Instantly share code, notes, and snippets.

@heiwa4126
Created October 21, 2021 08:05
Show Gist options
  • Save heiwa4126/a918452d0a95ceb49ecf29c3fbc34cac to your computer and use it in GitHub Desktop.
Save heiwa4126/a918452d0a95ceb49ecf29c3fbc34cac to your computer and use it in GitHub Desktop.
RHEL8で、手動アップデートの際に使ってるスクリプト。~/bin/update.shに置いてる。
#!/bin/sh -ue
# for RHEL8
sudo dnf -y update
sudo dnf -y autoremove
sudo dnf -y remove $(dnf repoquery --installonly --latest-limit=-2 -q)
sudo needs-restarting -r
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment