Skip to content

Instantly share code, notes, and snippets.

@diegolealco
Created December 14, 2025 11:35
Show Gist options
  • Select an option

  • Save diegolealco/5162e1ecbb11c823893a0db52097494a to your computer and use it in GitHub Desktop.

Select an option

Save diegolealco/5162e1ecbb11c823893a0db52097494a to your computer and use it in GitHub Desktop.
#!/bin/bash
# Fedora 43 Workstation Post-Installation Automation Script (RPM Fusion Manual Version)
# Run as your regular user (it will prompt for sudo password when needed)
# Assumes you have enabled RPM Fusion (free + nonfree) manually BEFORE running this script
# Tested on fresh Fedora 43 Workstation (December 2025)
set -e # Exit on any error
echo "=================================================="
echo "Fedora 43 Post-Installation Automation Script"
echo "(RPM Fusion step removed — enable it manually first!)"
echo "=================================================="
echo
# 1. Install NVIDIA drivers (only if NVIDIA hardware is detected and RPM Fusion is enabled)
echo "1. Checking for NVIDIA GPU..."
if lspci | grep -Ei "vga|3d" | grep -Ei "nvidia" > /dev/null; then
echo " NVIDIA GPU detected — installing proprietary drivers..."
sudo dnf install -y akmod-nvidia xorg-x11-drv-nvidia-cuda # Remove cuda package if not needed
echo " NVIDIA drivers installed. Reboot required later for module build."
else
echo " No NVIDIA GPU detected — skipping driver installation."
fi
# 2. Install full multimedia codecs (requires RPM Fusion)
echo "2. Installing full multimedia codecs and FFmpeg..."
sudo dnf install -y \
gstreamer1-plugins-bad-free gstreamer1-plugins-bad-free-extras \
gstreamer1-plugins-bad-freeworld gstreamer1-plugins-ugly gstreamer1-libav \
--allowerasing
sudo dnf swap -y ffmpeg-free ffmpeg --allowerasing
# 3. Speed up DNF
echo "3. Optimizing DNF performance..."
sudo tee -a /etc/dnf/dnf.conf > /dev/null <<EOL
# Added by post-install script
max_parallel_downloads=10
fastestmirror=True
EOL
# 4. Full system update
echo "4. Performing full system update..."
sudo dnf upgrade -y --refresh
# 5. Add full (unfiltered) Flathub
echo "5. Adding full Flathub repository..."
flatpak remote-add --if-not-exists --user flathub https://dl.flathub.org/repo/flathub.flatpakrepo
# 6. Lower priority of Fedora's built-in Flatpak remote
echo "6. Making Flathub the preferred source..."
sudo flatpak remote-modify fedora --prio=0
# 7. Install common tools & GNOME tweaks
echo "7. Installing common utilities and GNOME tweaks..."
sudo dnf install -y \
gnome-tweaks gnome-extensions-app \
vim git curl wget htop fuse
# 8. Update firmware
echo "8. Updating firmware (if supported)..."
sudo fwupdmgr refresh --force -y
sudo fwupdmgr get-updates -y || true
sudo fwupdmgr update -y || true
echo
echo "=================================================="
echo "Automation complete!"
echo "=================================================="
echo
echo "Next steps:"
echo " • Reboot your system (highly recommended, especially if NVIDIA drivers were installed)."
echo " • After reboot, open the Extensions app to install your favorite GNOME extensions."
echo " • Install apps from Flathub via GNOME Software or CLI (e.g., flatpak install flathub com.obsproject.Studio)"
echo
echo "Enjoy your optimized Fedora 43 Workstation!"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment