手机版
你好,游客 登录 注册
背景:
阅读新闻

如何去Flathub安装Flatpak应用及安装方法

[日期:2019-07-22] 来源:Linux公社  作者:Linux [字体: ]

Flathub使用Flatpak格式打包,它是一个第三方的应用程序库。如果你的Linux系统安装Flatpak后就可以启用Flathub了,它是托管Flatpak应用的集中地。目前GNOME 3.30桌面环境已作为Flatpak runtimes上架到Flathub中,从该网站可以下载安装GNOME 3.30到GNU/Linux发行版中。

在各大Linux发行版中安装Flatpak请参考:如何在Linux系统中安装Flatpak。如果你使用的是Fedora Workstation等版本已经默认安装了,启用Flathub就行了。支持的Linux发行版本相当多,比如深度操作系统、Ubuntu、Fedora、Linux Mint、OpenSUSERed Hat Enterprise Linux、CentOS、Arch Linux、Debian GNU/Linux、Gentoo Linux、Solus、Endless OS、Alpine Linux、Mageia、elementary、Raspbian和Pop!_OS等。

相关链接

Flathub网站

如何去Flathub安装Flatpak应用及安装方法

Flathub说明:Apps for Linux, right here

欢迎来到Flathub,它是数百个应用程序的家,可以轻松安装在任何Linux发行版上。 在线浏览应用程序,从应用程序中心或命令行。

安装示例:

1.GIMP

flatpak install flathub org.gimp.GIMP

运行:

flatpak run org.gimp.GIMP

2.Vim

flatpak install flathub org.vim.Vim

运行:

flatpak run org.vim.Vim

3.Steam

flatpak install flathub com.valvesoftware.Steam

运行:

flatpak run com.valvesoftware.Steam

4.Shotwell

flatpak install flathub org.gnome.Shotwell

运行:

flatpak run org.gnome.Shotwell

5.GNOME Fonts

flatpak install flathub org.gnome.font-viewer

运行:

flatpak run org.gnome.font-viewer

6.RetroArch

flatpak install flathub org.libretro.RetroArch

运行:

flatpak run org.libretro.RetroArch

附:Gentoo使用flatpak

1、创建/etc/portage/repos.conf/flatpak-overlay.conf:

[flatpak-overlay]

priority = 50

location = /usr/local/portage/flatpak-overlay

sync-type = git

sync-uri = https://github.com/fosero/flatpak-overlay.git

auto-sync = Yes

2、emerge --sync然后emerge flatpak

3、从网络安装:

flatpak install --from https://flathub.org/repo/appstream/org.kicad_pcb.KiCad.flatpakref

4、从文件安装:

从app应用站点:https://flathub.org/ 找到app,下载.flatpakref安装

5、从repository安装

flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo

flatpak install flathub com.visualstudio.code

6、运行

flatpak run com.visualstudio.code

附:flathub内应用安装的正确方法

1.在flathub上面搜索应用并用提供命令安装后,一直会出现timeout,如下:

$ flatpak install --from https://flathub.org/repo/appstream/com.obsproject.Studio.flatpakref

error: Can't load uri https://flathub.org/repo/appstream/com.obsproject.Studio.flatpakref: Timeout was reached

2.经过不断的探索,发现安装runtime和sdk是没有问题,安装命令如下:

$ flatpak install flathub  org.gnome.Platform//3.26

Installing: org.gnome.Platform/x86_64/3.26 from flathub

[####################] 10 delta parts, 11 loose fetched; 141642 KiB transferred in 65 seconds

Installing: org.gnome.Platform.Locale/x86_64/3.26 from flathub

[####################] 5 delta parts, 1 loose fetched; 20822 KiB transferred in 17 seconds

~$ flatpak install flathub org.gnome.Sdk//3.26

Installing: org.gnome.Sdk/x86_64/3.26 from flathub

[####################] 19 delta parts, 10 loose fetched; 144926 KiB transferred in 62 seconds

Installing: org.gnome.Sdk.Locale/x86_64/3.26 from flathub

[####################] 5 delta parts, 1 loose fetched; 4657 KiB transferred in 9 seconds

3.突发使用了下面这种方法安装应用,结果不出意外,完全可以成功:

~$ flatpak install flathub com.obsproject.Studio

Required runtime for com.obsproject.Studio/x86_64/stable (org.kde.Platform/x86_64/5.9) is not installed, searching...

Found in remote flathub, do you want to install it? [y/n]: y

Installing: org.kde.Platform/x86_64/5.9 from flathub

[####################] 12 delta parts, 40 loose fetched; 226536 KiB transferred in 189 seconds

Installing: org.kde.Platform.Locale/x86_64/5.9 from flathub

[####################] 5 delta parts, 9 loose fetched; 25758 KiB transferred in 69 seconds

Installing: com.obsproject.Studio/x86_64/stable from flathub

[####################] 1 delta parts, 7 loose fetched; 12324 KiB transferred in 21 seconds

Installing: com.obsproject.Studio.Locale/x86_64/stable from flathub

[####################] 1 delta parts, 1 loose fetched; 13 KiB transferred in 2 seconds

flatpak已更新到1.4.2

截止2019年7月22日,flatpak已经更新到了1.4.2,你也可以下载源码(flatpak-1.4.2.tar.xz)进行安装。下面是发布详情:

WARNING WARNING WARNING

There was an accidental ABI break in libflatpak in 1.4.0 compared to
the 1.2.x ABI which caused crashes in apps like gnome-software.

This has been fixed in this release so it is now ABI compatible with
1.2.x, but NOT compatible with 1.4.0. It is recommended that all
distributions that shipped 1.4.0 update to 1.4.1 and rebuild all
dependencies of libflatpak.

  • Make ABI compatible with 1.2.x
  • Update translations
  • Fix some potential crashes
  • Fix some corner case where it was impossible to remove a remote
  • Restore support for file: uris in the RuntimeRepo key in flatpakref files
$ sha256sum flatpak-1.4.1.tar.xz 
85ccf052e8131c629ab9934dca4c5019efd448b96d35596e56d5b531fb0b0078  flatpak-1.4.1.tar.xz

Linux公社的RSS地址https://www.linuxidc.com/rssFeed.aspx

本文永久更新链接地址https://www.linuxidc.com/Linux/2019-07/159496.htm

linux
本文评论   查看全部评论 (0)
表情: 表情 姓名: 字数

       

评论声明
  • 尊重网上道德,遵守中华人民共和国的各项有关法律法规
  • 承担一切因您的行为而直接或间接导致的民事或刑事法律责任
  • 本站管理人员有权保留或删除其管辖留言中的任意内容
  • 本站有权在网站内转载或引用您的评论
  • 参与本评论即表明您已经阅读并接受上述条款