-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathinitialize_after_os_update.sh
More file actions
executable file
·42 lines (32 loc) · 1.02 KB
/
initialize_after_os_update.sh
File metadata and controls
executable file
·42 lines (32 loc) · 1.02 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
#!/bin/bash
set -euo pipefail
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
cd "$DIR"
# Disable SteamOS Readonly mode
sudo steamos-readonly disable
# If the '--skip-refresh-keys' flag is passed, skip refreshing keys
if [[ "$*" != *--skip-refresh-keys* ]]; then
# Refresh Keys
sudo pacman-key --init
sudo pacman-key --populate archlinux
sudo pacman-key --populate holo # Thx: https://www.reddit.com/r/SteamDeck/comments/17i7gdk/comment/k6smppj
sudo pacman-key --refresh-keys
fi
# Tell user to press enter to continue
echo ""
echo ""
echo "------------------------------"
echo "| Press Enter to continue... |"
echo "------------------------------"
read
echo ""
# Update archlinux-keyring
# See: https://wiki.archlinux.org/title/Pacman/Package_signing#Upgrade_system_regularly
sudo pacman -Sy archlinux-keyring --noconfirm
sudo pacman -Su --noconfirm
# Upgrade all packages
sudo pacman -Syu --noconfirm
# Install custom packages
./install_pacman_packages.sh
echo "Done!"
cd - >/dev/null