1

fix flatpak module

This commit is contained in:
2022-08-07 23:56:35 +02:00
parent 8d6cfa9583
commit 9de7939cd4
2 changed files with 7 additions and 10 deletions

View File

@ -27,7 +27,7 @@ in {
};
packages = mkOption {
type = types.listOf types.string;
type = types.listOf types.str;
default = [ ];
description = "List of enabled flatpaks";
};
@ -47,8 +47,6 @@ in {
config = mkIf cfg.enable {
services.flatpak.enable = true;
# NOTE: Is already set by flatpak.enable in configuration.nix
# xdg.systemDirs.data = [
# "/var/lib/flatpak/exports/share"
@ -60,8 +58,8 @@ in {
# We link like this to be able to address the absolute location, also the fonts won't get copied to store
# NOTE: This path contains all the fonts because fonts.fontDir.enable is true
linkFontDir = lib.hm.dag.entryAfter [ "writeBoundary" ] ''
if [ ! -L "${home.homeDirectory}/.local/share/fonts" ]; then
ln -sf /run/current-system/sw/share/X11/fonts ${home.homeDirectory}/.local/share/fonts
if [ ! -L "${config.home.homeDirectory}/.local/share/fonts" ]; then
ln -sf /run/current-system/sw/share/X11/fonts ${config.home.homeDirectory}/.local/share/fonts
fi
'';
})
@ -69,8 +67,8 @@ in {
(mkIf cfg.iconFix {
# NOTE: This path works because we have homeManager.useUserPackages = true (everything is stored in /etc/profiles/)
linkIconDir = lib.hm.dag.entryAfter [ "writeBoundary" ] ''
if [ ! -L "${home.homeDirectory}/.local/share/icons" ]; then
ln -sf /etc/profiles/per-user/christoph/share/icons ${home.homeDirectory}/.local/share/icons
if [ ! -L "${config.home.homeDirectory}/.local/share/icons" ]; then
ln -sf /etc/profiles/per-user/christoph/share/icons ${config.home.homeDirectory}/.local/share/icons
fi
'';
})

View File

@ -259,7 +259,7 @@
# List services that you want to enable:
services = {
# Enable CUPS to print documents.
# TODO: Printer driver
# TODO: Printer driver, Gnome printing
printing.enable = true;
avahi.enable = true; # Network printers
avahi.nssmdns = true;
@ -276,7 +276,7 @@
acpid.enable = true;
dbus.enable = true;
# flatpak.enable = true; # Not quite the nix style but useful for bottles/proprietary stuff
flatpak.enable = true; # Not quite the nix style but useful for bottles/proprietary stuff
fstrim.enable = true;
fwupd.enable = true;
locate.enable = true; # Periodically update index
@ -299,5 +299,4 @@
# Before changing this value read the documentation for this option
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
system.stateVersion = "22.05"; # Did you read the comment?
}