134
modules/shared/user/flatpak.nix
Normal file
134
modules/shared/user/flatpak.nix
Normal file
@ -0,0 +1,134 @@
|
||||
{
|
||||
inputs,
|
||||
pkgs,
|
||||
...
|
||||
}: {
|
||||
imports = with inputs; [
|
||||
nix-flatpak.homeManagerModules.nix-flatpak
|
||||
];
|
||||
home.packages = with pkgs; [flatpak];
|
||||
services.flatpak = {
|
||||
enable = true;
|
||||
uninstallUnmanaged = true;
|
||||
update.auto = {
|
||||
enable = true;
|
||||
onCalendar = "weekly";
|
||||
};
|
||||
remotes = [
|
||||
{
|
||||
name = "flathub";
|
||||
location = "https://dl.flathub.org/repo/flathub.flatpakrepo";
|
||||
}
|
||||
];
|
||||
packages =
|
||||
[
|
||||
# browsers
|
||||
"app.zen_browser.zen"
|
||||
# "com.vivaldi.Vivaldi"
|
||||
"net.mullvad.MullvadBrowser"
|
||||
"org.torproject.torbrowser-launcher"
|
||||
]
|
||||
++ [
|
||||
# editing
|
||||
"com.github.PintaProject.Pinta" # bootleg paint
|
||||
"org.gimp.GIMP" # the holy gimp
|
||||
"org.kde.kdenlive" # video editor
|
||||
]
|
||||
++ [
|
||||
# chatting
|
||||
"im.riot.Riot" # matrix client
|
||||
"io.github.kukuruzka165.materialgram" # telegram client
|
||||
"io.github.spacingbat3.webcord" # discord client
|
||||
# "org.mozilla.Thunderbird" # mail client
|
||||
"org.signal.Signal"
|
||||
# "org.telegram.desktop"
|
||||
]
|
||||
++ [
|
||||
# media
|
||||
# "ca.edestcroix.Recordbox" # music player
|
||||
"com.github.neithern.g4music" # music player
|
||||
# "io.bassi.Amberol" # music player
|
||||
"io.freetubeapp.FreeTube" # youtube client
|
||||
# "org.atheme.audacious" # music player
|
||||
]
|
||||
++ [
|
||||
# gaming
|
||||
"com.heroicgameslauncher.hgl" # gog/egs launcher
|
||||
"com.valvesoftware.Steam"
|
||||
"net.lutris.Lutris" # everything launcher
|
||||
"org.prismlauncher.PrismLauncher" # minecraft launcher
|
||||
"org.freedesktop.Platform.VulkanLayer.MangoHud//24.08"
|
||||
"org.freedesktop.Platform.VulkanLayer.gamescope//24.08"
|
||||
]
|
||||
++ [
|
||||
# misc
|
||||
"app.drey.Warp" # share files using magic wormhole
|
||||
"com.bitwarden.desktop"
|
||||
"com.github.tchx84.Flatseal" # control flatpak permissions
|
||||
"com.logseq.Logseq"
|
||||
"com.obsproject.Studio"
|
||||
"com.usebottles.bottles" # wine containers
|
||||
"de.capypara.FieldMonitor" # libvirt
|
||||
"de.haeckerfelix.Fragments" # torrents
|
||||
"io.github.amit9838.mousam" # weather
|
||||
"io.github.finefindus.Hieroglyphic" # find latex symbols (in rust)
|
||||
"io.github.lainsce.Khronos" # log time for tasks
|
||||
"io.gitlab.news_flash.NewsFlash" # rss reader
|
||||
"me.iepure.devtoolbox" # some cool utils
|
||||
"org.nicotine_plus.Nicotine" # soulseek
|
||||
];
|
||||
overrides = let
|
||||
homeNoNetwork = {
|
||||
Context.share = ["!network"];
|
||||
Context.filesystems = ["home"];
|
||||
};
|
||||
game.sockets = ["x11" "wayland"];
|
||||
game.folder = folder: ["/storage/games/${folder}" "~/games/${folder}"];
|
||||
in {
|
||||
"global" = {
|
||||
Context = {
|
||||
sockets = ["wayland" "!x11" "!fallback-x11"];
|
||||
filesystems = [
|
||||
"!home"
|
||||
"!host"
|
||||
"!~/.ssh"
|
||||
"/nix/store:ro"
|
||||
"xdg-config/gtk-3.0:ro"
|
||||
"xdg-config/gtk-4.0:ro"
|
||||
"xdg-run/pipewire-0"
|
||||
"~/.local/share/icons:ro"
|
||||
];
|
||||
};
|
||||
Environment = {
|
||||
ELECTRON_OZONE_PLATFORM_HINT = "wayland";
|
||||
};
|
||||
};
|
||||
"ca.edestcroix.Recordbox".Context.filesystems = ["xdg-music"];
|
||||
"com.valvesoftware.Steam" = {
|
||||
Context = {
|
||||
inherit (game) sockets;
|
||||
filesystems = game.folder "steam";
|
||||
};
|
||||
Environment.STEAM_FORCE_DESKTOPUI_SCALING = "1.3";
|
||||
};
|
||||
"net.lutris.Lutris".Context = {
|
||||
inherit (game) sockets;
|
||||
filesystems = game.folder "lutris";
|
||||
};
|
||||
"com.heroicgameslauncher.hgl".Context = {
|
||||
inherit (game) sockets;
|
||||
filesystems = game.folder "heroic";
|
||||
};
|
||||
"com.github.PintaProject.Pinta" = {inherit (homeNoNetwork) Context;};
|
||||
"com.logseq.Logseq" = {inherit (homeNoNetwork) Context;};
|
||||
"com.obsproject.Studio" = {inherit (homeNoNetwork) Context;};
|
||||
"com.usebottles.Bottles".Context = {inherit (game) sockets;};
|
||||
"io.bassi.Amberol" = {inherit (homeNoNetwork) Context;};
|
||||
"io.freetubeapp.FreeTube" = {inherit (homeNoNetwork) Context;};
|
||||
"org.atheme.audacious" = {inherit (homeNoNetwork) Context;};
|
||||
"org.gimp.GIMP" = {inherit (homeNoNetwork) Context;};
|
||||
"org.kde.kdenlive" = {inherit (homeNoNetwork) Context;};
|
||||
"org.signal.Signal".Environment.SIGNAL_PASSWORD_STORE = "gnome-libsecret";
|
||||
};
|
||||
};
|
||||
}
|
Reference in New Issue
Block a user