diff --git a/flake.nix b/flake.nix index ab92327..6ad7553 100644 --- a/flake.nix +++ b/flake.nix @@ -76,7 +76,7 @@ users.users.${user} = { hashedPassword = builtins.readFile ./password/${user}; isNormalUser = true; - extraGroups = ["wheel" "input" "docker" "audio" "mlocate"]; + extraGroups = ["wheel" "input" "docker" "audio" "mlocate" "libvirtd"]; shell = pkgs.zsh; }; }) diff --git a/modules/dwl/default.nix b/modules/dwl/default.nix index cd48640..25c8dba 100644 --- a/modules/dwl/default.nix +++ b/modules/dwl/default.nix @@ -71,4 +71,7 @@ # i18n.inputMethod.enabled = "ibus"; # i18n.inputMethod.ibus.engines = with pkgs.ibus-engines; [mozc]; + + virtualisation.libvirtd.enable = true; + programs.virt-manager.enable = true; } diff --git a/modules/dwl/home.nix b/modules/dwl/home.nix index 7688832..adc18a5 100644 --- a/modules/dwl/home.nix +++ b/modules/dwl/home.nix @@ -46,17 +46,6 @@ in { shikane ]; - dconf.settings = { - "org/gnome/shell/weather" = { - automatic-location = true; - }; - }; - - xdg.systemDirs.data = [ - "${pkgs.gtk3}/share/gsettings-schemas/${pkgs.gtk3.name}" - "${pkgs.gsettings-desktop-schemas}/share/gsettings-schemas/${pkgs.gsettings-desktop-schemas.name}" - ]; - xdg.configFile."ags" = { source = ./ags; recursive = true; @@ -64,50 +53,50 @@ in { # Keycodes here: https://github.com/torvalds/linux/blob/master/include/uapi/linux/input-event-codes.h#L202 # :1 is for keydown, :0 for keyup - xdg.configFile."fusuma/config.yaml".text = " -swipe: - 3: - right: - command: 'ydotool key 125:1 105:1 105:0 125:0' - left: - command: 'ydotool key 125:1 106:1 106:0 125:0' - up: - command: 'ydotool key 125:1 4:1 4:0 125:0' - down: - command: 'ydotool key 125:1 4:1 4:0 125:0' -hold: - 4: - command: 'ydotool key 125:1 52:1 52:0 125:0' -"; + xdg.configFile."fusuma/config.yaml".text = '' + swipe: + 3: + right: + command: 'ydotool key 125:1 105:1 105:0 125:0' + left: + command: 'ydotool key 125:1 106:1 106:0 125:0' + up: + command: 'ydotool key 125:1 4:1 4:0 125:0' + down: + command: 'ydotool key 125:1 4:1 4:0 125:0' + hold: + 4: + command: 'ydotool key 125:1 52:1 52:0 125:0' + ''; xdg.configFile."shikane/config.toml".text = '' -[[profile]] -name = "laptop" - [[profile.output]] - match = "eDP-1" - enable = true + [[profile]] + name = "laptop" + [[profile.output]] + match = "eDP-1" + enable = true -[[profile]] -name = "docked" -exec = ["bash -c 'ags -q; cat /proc/$(pidof dwl)/fd/1 | ags & disown'"] - [[profile.output]] - match = "eDP-1" - enable = false + [[profile]] + name = "docked" + exec = ["bash -c 'ags -q; cat /proc/$(pidof dwl)/fd/1 | ags & disown'"] + [[profile.output]] + match = "eDP-1" + enable = false - [[profile.output]] - match = "/DP-2|.*|EB243Y A/" - enable = true - mode = { width = 1920, height = 1080, refresh = 60 } - position = { x = 0, y = 0 } - scale = 1 + [[profile.output]] + match = "/DP-2|.*|EB243Y A/" + enable = true + mode = { width = 1920, height = 1080, refresh = 60 } + position = { x = 0, y = 0 } + scale = 1 - [[profile.output]] - match = "/DP-1|.*|EB243Y A/" - enable = true - mode = { width = 1920, height = 1080, refresh = 60 } - position = { x = 0, y = 1180 } - scale = 1 + [[profile.output]] + match = "/DP-1|.*|EB243Y A/" + enable = true + mode = { width = 1920, height = 1080, refresh = 60 } + position = { x = 0, y = 1180 } + scale = 1 -''; + ''; } diff --git a/modules/misc/home.nix b/modules/misc/home.nix index e720a3a..f5d9669 100644 --- a/modules/misc/home.nix +++ b/modules/misc/home.nix @@ -118,5 +118,26 @@ allowUnfree = true; }''; + # Allow gsettings to work + xdg.systemDirs.data = [ + "${pkgs.gtk3}/share/gsettings-schemas/${pkgs.gtk3.name}" + "${pkgs.gsettings-desktop-schemas}/share/gsettings-schemas/${pkgs.gsettings-desktop-schemas.name}" + ]; + + # For virt-manager to detect hypervisor + dconf.settings = { + "org/virt-manager/virt-manager/connections" = { + autoconnect = ["qemu:///system"]; + uris = ["qemu:///system"]; + }; + }; + + # Use geoclue2 for weather location + dconf.settings = { + "org/gnome/shell/weather" = { + automatic-location = true; + }; + }; + home.stateVersion = "22.11"; }