I've written a small bash script to help with updating various packages/dependencies on my machine (Pop!_OS) but it doesn't seem to be working correctly for flatpak. If I run flatpak update
in the terminal it will show that I have updates, but when running the script there aren't any updates.
The Script:
#!/bin/bash
# Update package list
sudo apt update -y
# Upgrade the packages and dependencies
sudo apt upgrade -y
# Remove unnecessary packages and dependencies
sudo apt autoremove -y
# Clean package cache
sudo apt clean -y
# Update Flatpak
sudo flatpak update -y
# Update firmware
sudo fwupdmgr update -y
echo "All updates and upgrades have completed sucessfully!"
EDIT:
Running flatpak update -y
without sudo
fixes the issue.
You must log in or register to comment.
Do you run flatpak update with or without sudo in your terminal?
Without.
EDIT: Just tested
sudo flatpak update
and it returned the same results as the script (duh!). Thanks for the help!Then you should do the same in the script. Remove the sudo in front of
flatpak update -y
.