mirror of
https://github.com/LCTT/TranslateProject.git
synced 2025-01-13 22:30:37 +08:00
[手动选题][tech]: 20221210.2 ⭐️ How to Update Flatpak Packages in Linux.md
This commit is contained in:
parent
7ebec9e5ea
commit
db3cc6fb0d
@ -0,0 +1,127 @@
|
||||
[#]: subject: "How to Update Flatpak Packages in Linux"
|
||||
[#]: via: "https://itsfoss.com/update-flatpak/"
|
||||
[#]: author: "Sagar Sharma https://itsfoss.com/author/sagar/"
|
||||
[#]: collector: "lkxed"
|
||||
[#]: translator: " "
|
||||
[#]: reviewer: " "
|
||||
[#]: publisher: " "
|
||||
[#]: url: " "
|
||||
|
||||
How to Update Flatpak Packages in Linux
|
||||
======
|
||||
|
||||
I believe almost all Linux users keep their systems updated.
|
||||
|
||||
But that update is usually for the default [package manager][1]. For example, [updating Ubuntu][2] often means updating all the APT packages.
|
||||
|
||||
However, there are other packaging formats like Snap and Flatpak. The Snap applications get updated automatically but not the Flatpak ones.
|
||||
|
||||
How do you update the Flatpak packages then? Well, you can update all the installed and updatable Flatpak packages using this command:
|
||||
|
||||
```
|
||||
flatpak update
|
||||
```
|
||||
|
||||
That’s quite simple. But let me discuss a few more things about updating Flatpak, such as:
|
||||
|
||||
- Updating all or specific Flatpak packages
|
||||
- Updating Flatpak packages via Software Center
|
||||
|
||||
Let’s start with the terminal method first.
|
||||
|
||||
### Method 1: Using the terminal for updating Flatpak packages
|
||||
|
||||
Let me first start with the most practical approach that you should also begin with.
|
||||
|
||||
#### Update every outdated Flatpak package
|
||||
|
||||
Updating the whole catalog of existing flatpak packages is quite easy.
|
||||
|
||||
Enter the given command, and it will get you the list of outdated packages:
|
||||
|
||||
```
|
||||
flatpak update
|
||||
```
|
||||
|
||||
![3. update flatpak packages in linux][3]
|
||||
|
||||
You just have to enter “Y” and press the Enter key, which will take care of every update.
|
||||
|
||||
#### Updating specific Flatpak package
|
||||
|
||||
To update specific packages, you’d need the list of the packages that can be updated. You used the same command you saw earlier.
|
||||
|
||||
```
|
||||
flatpak update
|
||||
```
|
||||
|
||||
![3. update flatpak packages in linux][4]
|
||||
|
||||
Copy the name of the package you want to update from the output. Use the package name in the following fashion:
|
||||
|
||||
```
|
||||
flatpak update package_name
|
||||
```
|
||||
|
||||
For example, if you want to update Telegram, the following command will get the job done:
|
||||
|
||||
```
|
||||
flatpak update org.telegram.desktop
|
||||
```
|
||||
|
||||
![4. update specific package in flatpak][5]
|
||||
|
||||
That’s it!
|
||||
|
||||
### Method 2: Update Flatpak applications from the software center
|
||||
|
||||
Distributions that come up with Flatpak buil-in support provide updates to Flatpak applications in the software center. Fedora and Linux Mint are such distributions.
|
||||
|
||||
But if you are using Ubuntu, you’d need to add flatpak support to the GNOME software center:
|
||||
|
||||
```
|
||||
sudo apt install gnome-software-plugin-flatpak
|
||||
```
|
||||
|
||||
Once done, you will have two software centers in Ubuntu. That’s because the default software center is not GNOME’s but Snap Store.
|
||||
|
||||
Open this new software center from the system menu:
|
||||
|
||||
![1. open software center in ubuntu][6]
|
||||
|
||||
Go to the `Updates` section and you will find the list of outdated packages. This includes both APT and Flatpak packages.
|
||||
|
||||
![2. update flatpak from software center][7]
|
||||
|
||||
From here, you can update all the packages at once, or you can be selective with what to update.
|
||||
|
||||
### Wrapping Up
|
||||
|
||||
Many Linux desktop users tend to forget to update the Flatpak packages as they are not included in the regular system updates.
|
||||
|
||||
As Flatpak is a sandboxed packaging solution, you may not face any issues related to outdated packages, but you will miss out on new features and fixes for sure.
|
||||
|
||||
This is why I recommend running the Flatpak update command once ever few weeks.
|
||||
|
||||
I hope you like this quick little Flatpak tip helpful.
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: https://itsfoss.com/update-flatpak/
|
||||
|
||||
作者:[Sagar Sharma][a]
|
||||
选题:[lkxed][b]
|
||||
译者:[译者ID](https://github.com/译者ID)
|
||||
校对:[校对者ID](https://github.com/校对者ID)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
|
||||
|
||||
[a]: https://itsfoss.com/author/sagar/
|
||||
[b]: https://github.com/lkxed
|
||||
[1]: https://itsfoss.com/package-manager/
|
||||
[2]: https://itsfoss.com/update-ubuntu/
|
||||
[3]: https://itsfoss.com/wp-content/uploads/2022/12/3.-update-flatpak-packages-in-linux.png
|
||||
[4]: https://itsfoss.com/wp-content/uploads/2022/12/3.-update-flatpak-packages-in-linux.png
|
||||
[5]: https://itsfoss.com/wp-content/uploads/2022/12/4.-update-specific-package-in-flatpak.png
|
||||
[6]: https://itsfoss.com/wp-content/uploads/2022/12/1.-open-software-center-in-ubuntu.png
|
||||
[7]: https://itsfoss.com/wp-content/uploads/2022/12/2.-update-flatpak-from-software-center.png
|
Loading…
Reference in New Issue
Block a user