diff --git a/flake.lock b/flake.lock index e205af3..4d5b13b 100644 --- a/flake.lock +++ b/flake.lock @@ -463,22 +463,6 @@ "type": "github" } }, - "nomachine": { - "locked": { - "lastModified": 1682367457, - "narHash": "sha256-Hec3l+TYmE9ICUz7NxmRtfljUl6ludm8QKSdiW21WRg=", - "owner": "rytec-nl", - "repo": "nixpkgs", - "rev": "63686e66b7441ef5d5e7a6277d1c36c413548b05", - "type": "github" - }, - "original": { - "owner": "rytec-nl", - "ref": "submit/add-nomachine-server", - "repo": "nixpkgs", - "type": "github" - } - }, "pamedia": { "inputs": { "flake-utils": [ @@ -549,7 +533,6 @@ "nixinate": "nixinate", "nixos-hardware": "nixos-hardware", "nixpkgs": "nixpkgs", - "nomachine": "nomachine", "pamedia": "pamedia", "pre-commit-hooks": "pre-commit-hooks", "rust-overlay": "rust-overlay_2", diff --git a/flake.nix b/flake.nix index 2c8fb12..24ced1d 100644 --- a/flake.nix +++ b/flake.nix @@ -78,10 +78,6 @@ inputs.nixpkgs.follows = "nixpkgs"; }; - nomachine = { - url = "github:rytec-nl/nixpkgs/submit/add-nomachine-server"; - }; - eww = { url = "github:elkowar/eww"; inputs = { @@ -151,12 +147,6 @@ { nix.nixPath = [ "nixpkgs=${nixpkgs}" ]; nixpkgs = - let - nomachine-pkgs = import nomachine { - inherit system; - config.allowUnfree = true; - }; - in { overlays = [ self.overlays.default @@ -166,9 +156,6 @@ nil.overlays.default inputs.eww.overlays.default inputs.rust-overlay.overlays.default - (_final: _prev: { - nomachine = nomachine-pkgs.nomachine; - }) ] ++ nixpkgs.lib.optional (system == "aarch64-linux") (_final: super: { makeModulesClosure = x: diff --git a/home-manager/modules/sway/default.nix b/home-manager/modules/sway/default.nix index 8d1111f..6fce419 100644 --- a/home-manager/modules/sway/default.nix +++ b/home-manager/modules/sway/default.nix @@ -14,19 +14,38 @@ with lib; let # swaylockcmd = "${pkgs.swaylock-effects}/bin/swaylock --ignore-empty-password --daemonize --show-failed-attempts --indicator-caps-lock --clock --image ${wallpapers.qhd} --fade-in 0.5 --scaling fill"; swaylockcmd = "${pkgs.swaylock}/bin/swaylock --ignore-empty-password --daemonize --show-failed-attempts --indicator-caps-lock --image ${wallpapers.qhd} --scaling fill"; rofiPower = pkgs.writeShellScriptBin "rofi-power" (builtins.readFile ./powermenu.sh); - ewwDaemon = - let - path = lib.makeBinPath (with pkgs; [ ha-now-playing jaq pamedia bash helvum pavucontrol ]); - in - pkgs.writeShellScript "eww-daemon" '' - export PATH=${path}:''${PATH} - - ${config.eboskma.programs.eww.package}/bin/eww kill - ${config.eboskma.programs.eww.package}/bin/eww daemon - ''; in { - options.eboskma.programs.sway.enable = mkEnableOption "Enable sway"; + options.eboskma.programs.sway = { + enable = mkEnableOption "Enable sway"; + output = mkOption { + description = "An attribute set that defines output modules. See the sway-output(5) manpage for options"; + type = types.attrsOf (types.attrsOf types.str); + default = { }; + }; + input = mkOption { + description = "An attribute set that defines input modules. See the sway-input(5) manpage for options"; + type = types.attrsOf (types.attrsOf types.str); + default = { }; + }; + startup = mkOption { + description = "Commands that should be executed at startup."; + type = types.listOf (types.submodule { + options = { + command = mkOption { + type = types.str; + description = "Command that will be executed on startup."; + }; + + always = mkOption { + type = types.bool; + default = false; + description = "Whether to run command on each ${moduleName} restart."; + }; + }; + }); + }; + }; config = mkIf cfg.enable { wayland.windowManager.sway = { @@ -36,9 +55,8 @@ in assigns = { "1" = [{ app_id = "firefox"; }]; - "2" = [{ app_id = "Alacritty"; } { app_id = "foot"; }]; + "2" = [{ app_id = "foot"; }]; "3" = [{ class = "Code"; } { app_id = "emacs"; }]; - "9" = [{ class = "Steam"; }]; }; bars = [ ]; @@ -106,28 +124,8 @@ in smartBorders = "on"; }; - input = { - "36125:40349:splitKB_Kyria" = { - xkb_layout = "us"; - xkb_options = "lv3:ralt_switch,eurosign:5"; - }; - "1133:49291:Logitech_G502_HERO_SE" = { - natural_scroll = "enabled"; - }; - }; - - output = { - "Virtual-1" = { - bg = "${wallpapers.hd} fill"; - mode = "1920x1080@60Hz"; - }; - "DP-2" = { - bg = "${./wallpapers/jwst-saturn-nircam-2560.png} fill"; - mode = "2560x1440@165Hz"; - adaptive_sync = "on"; - max_render_time = "2"; - }; - }; + input = cfg.input; + output = cfg.output; menu = "${pkgs.rofi}/bin/rofi -show drun -no-lazy-grab"; @@ -225,7 +223,6 @@ in }; }; - # terminal = "${pkgs.alacritty}/bin/alacritty"; terminal = "${pkgs.foot}/bin/foot"; window = { @@ -241,10 +238,7 @@ in }; }; - startup = [ - { command = toString ewwDaemon; always = true; } - { command = "${config.eboskma.programs.eww.package}/bin/eww open bar-home"; always = true; } - ]; + startup = cfg.startup; }; extraConfig = '' for_window [app_id="^.*"] inhibit_idle fullscreen @@ -307,8 +301,8 @@ in } { timeout = 1200; - command = "${pkgs.sway}/bin/swaymsg 'output * dpms off'"; - resumeCommand = "${pkgs.sway}/bin/swaymsg 'output * dpms on'"; + command = "${pkgs.sway}/bin/swaymsg 'output * power off'"; + resumeCommand = "${pkgs.sway}/bin/swaymsg 'output * power on'"; } ]; }; diff --git a/home-manager/modules/sway/wallpapers/black-panther-2560.jpg b/home-manager/modules/sway/wallpapers/black-panther-2560.jpg new file mode 100644 index 0000000..2b3299d Binary files /dev/null and b/home-manager/modules/sway/wallpapers/black-panther-2560.jpg differ diff --git a/home-manager/modules/sway/wallpapers/black-panther-3840.jpg b/home-manager/modules/sway/wallpapers/black-panther-3840.jpg new file mode 100644 index 0000000..f154d6b Binary files /dev/null and b/home-manager/modules/sway/wallpapers/black-panther-3840.jpg differ diff --git a/home-manager/modules/sway/wallpapers/jwst-carina-cosmic-cliffs-nircam-2560.png b/home-manager/modules/sway/wallpapers/jwst-carina-cosmic-cliffs-nircam-2560.png new file mode 100644 index 0000000..391990d Binary files /dev/null and b/home-manager/modules/sway/wallpapers/jwst-carina-cosmic-cliffs-nircam-2560.png differ diff --git a/home-manager/modules/sway/wallpapers/jwst-carina-cosmic-cliffs-nircam-3840.png b/home-manager/modules/sway/wallpapers/jwst-carina-cosmic-cliffs-nircam-3840.png new file mode 100644 index 0000000..ae05dff Binary files /dev/null and b/home-manager/modules/sway/wallpapers/jwst-carina-cosmic-cliffs-nircam-3840.png differ diff --git a/home-manager/modules/sway/wallpapers/jwst-pillars-of-creation-1920.jpg b/home-manager/modules/sway/wallpapers/jwst-pillars-of-creation-1920.jpg new file mode 100644 index 0000000..f8974b9 Binary files /dev/null and b/home-manager/modules/sway/wallpapers/jwst-pillars-of-creation-1920.jpg differ diff --git a/home-manager/modules/sway/wallpapers/jwst-pillars-of-creation-2560.jpg b/home-manager/modules/sway/wallpapers/jwst-pillars-of-creation-2560.jpg new file mode 100644 index 0000000..31eccb8 Binary files /dev/null and b/home-manager/modules/sway/wallpapers/jwst-pillars-of-creation-2560.jpg differ diff --git a/home-manager/modules/sway/wallpapers/jwst-pillars-of-creation-3840.jpg b/home-manager/modules/sway/wallpapers/jwst-pillars-of-creation-3840.jpg new file mode 100644 index 0000000..72ee840 Binary files /dev/null and b/home-manager/modules/sway/wallpapers/jwst-pillars-of-creation-3840.jpg differ diff --git a/home-manager/modules/sway/wallpapers/river-3840.png b/home-manager/modules/sway/wallpapers/river-3840.png index d6d27ed..acf5af4 100644 Binary files a/home-manager/modules/sway/wallpapers/river-3840.png and b/home-manager/modules/sway/wallpapers/river-3840.png differ diff --git a/home-manager/modules/wallpapers/default.nix b/home-manager/modules/wallpapers/default.nix index fdb1b6d..846e0b6 100644 --- a/home-manager/modules/wallpapers/default.nix +++ b/home-manager/modules/wallpapers/default.nix @@ -14,6 +14,25 @@ let in ''${pkgs.nitrogen}/bin/nitrogen --head=${monitor} --set-color=${cfg.backgroundColor} --set-tiled ${image}'') (zipLists cfg.images (builtins.genList (x: x) (builtins.length cfg.images))))); + + wallpaperConfig = { + options = { + name = mkOption { + description = "The base filename of the image, without size and extension."; + type = types.str; + }; + + sizes = mkOption { + description = "The sizes this wallpaper comes in, as specified in the filename."; + type = with types; listOf int; + }; + + extension = mkOption { + description = "The extension of the wallpaper"; + type = types.enum [ "jpg" "png" "gif" ]; + }; + }; + }; in { options.eboskma.wallpapers = { @@ -25,8 +44,8 @@ in example = "#ff0000"; }; images = mkOption { - description = "Image(s) to use as wallpapers. For multiple monitors, either set a single image to use on all monitors, or set a list with as many images as monitors you have"; - type = with types; oneOf [ path (nonEmptyListOf path) ]; + description = "Images to make available as wallpaper. The files should be named as `-.` and be placed in the `wallpapers` subdirectory"; + type = with types; listOf (submodule wallpaperConfig); }; }; @@ -39,7 +58,5 @@ in notification = false; } ]; - - }; } diff --git a/machines/loki/configuration.nix b/machines/loki/configuration.nix index 494d838..0d46685 100644 --- a/machines/loki/configuration.nix +++ b/machines/loki/configuration.nix @@ -359,10 +359,15 @@ statdPort = 4100; }; - environment.systemPackages = with pkgs; [ - appimage-run - tailscale - ]; + environment = { + sessionVariables = { + AMD_VULKAN_ICD = "RADV"; + }; + systemPackages = with pkgs; [ + appimage-run + tailscale + ]; + }; sops.defaultSopsFile = ./secrets.yaml; sops.secrets = { diff --git a/machines/mimir/configuration.nix b/machines/mimir/configuration.nix index bda2701..bee0efe 100644 --- a/machines/mimir/configuration.nix +++ b/machines/mimir/configuration.nix @@ -2,7 +2,7 @@ # your system. Help is available in the configuration.nix(5) man page # and in the NixOS manual (accessible by running ‘nixos-help’). -{ nixos-hardware, nomachine, microvm, ... }: +{ nixos-hardware, microvm, ... }: { pkgs, config, ... }: { imports = @@ -11,7 +11,7 @@ nixos-hardware.nixosModules.common-cpu-amd nixos-hardware.nixosModules.common-cpu-amd-pstate nixos-hardware.nixosModules.common-pc-ssd - "${nomachine}/nixos/modules/services/admin/nomachine.nix" + # "${nomachine}/nixos/modules/services/admin/nomachine.nix" microvm.nixosModules.host @@ -38,6 +38,7 @@ desktop = { enable = true; + wayland = true; }; docker = { enable = true; @@ -46,13 +47,18 @@ }; fonts.enable = true; gnome.enable = true; + greetd = { + enable = true; + sway = true; + wayvnc = true; + }; kanata = { enable = true; devices = [ "/dev/input/by-id/usb-04d9_USB-HID_Keyboard-event-kbd" ]; }; - lightdm.enable = true; + lightdm.enable = false; networking.enable = true; nix-common = { enable = true; @@ -93,7 +99,7 @@ nvidia = { modesetting.enable = true; powerManagement.enable = true; - forceFullCompositionPipeline = true; + # forceFullCompositionPipeline = true; }; opengl = { @@ -122,11 +128,16 @@ }; efi.canTouchEfiVariables = true; }; + # This triggers a warning on stateVersions < 23.11 if set to true + swraid.enable = false; }; time.timeZone = "Europe/Amsterdam"; - console.useXkbConfig = true; + console = { + font = "${pkgs.terminus_font}/share/consolefonts/ter-u28n.psf.gz"; + useXkbConfig = true; + }; networking = { hostName = "mimir"; @@ -239,6 +250,9 @@ }; # programs.ssh.startAgent = true; + programs = { + gnome-disks.enable = true; + }; services = { openssh.enable = true; @@ -249,6 +263,16 @@ tailscale.enable = true; + udisks2 = { + enable = true; + }; + + udev = { + extraRules = '' + ACTION=="add", ATTRS{idVendor}=="0781", ATTRS{idProduct}=="55b1", ATTRS{serial}=="A20033BEAC21B773", NAME="vault" + ''; + }; + xserver = { videoDrivers = [ "nvidia" ]; @@ -270,11 +294,6 @@ }; }; - nxserver = { - enable = true; - openFirewall = true; - }; - icecream.daemon = { enable = true; @@ -285,9 +304,15 @@ }; }; - environment.systemPackages = with pkgs; [ - appimage-run - ]; + environment = { + systemPackages = with pkgs; [ + appimage-run + ]; + + sessionVariables = { + WLR_NO_HARDWARE_CURSORS = "1"; + }; + }; # sops = { # defaultSopsFile = ./secrets.yaml; diff --git a/modules/desktop/default.nix b/modules/desktop/default.nix index cc28e63..d23ec13 100644 --- a/modules/desktop/default.nix +++ b/modules/desktop/default.nix @@ -88,7 +88,6 @@ in QT_WAYLAND_DISABLE_WINDOWDECORATION = "1"; QT_QPA_PLATFORMTHEME = "qt5ct"; SDL_VIDEODRIVER = "wayland"; - AMD_VULKAN_ICD = "RADV"; NIXOS_OZONE_WL = "1"; }) ]; diff --git a/modules/greetd/default.nix b/modules/greetd/default.nix index 9062a74..eb31bec 100644 --- a/modules/greetd/default.nix +++ b/modules/greetd/default.nix @@ -8,11 +8,15 @@ with lib; let style = builtins.replaceStrings [ "{WALLPAPER}" ] [ (builtins.toString ../../home-manager/modules/sway/wallpapers/river-2560.png) ] (builtins.readFile ./greetd.css); + swaySession = pkgs.writeShellScript "sway-session" '' + ${pkgs.sway}/bin/sway --unsupported-gpu + ''; in { options.eboskma.greetd = { enable = mkEnableOption "enable greetd"; sway = mkEnableOption "sway"; + wayvnc = mkEnableOption "wayvnc"; }; config = @@ -53,59 +57,61 @@ in security.pam.services.greetd.u2fAuth = false; - environment.systemPackages = with pkgs; [ pantheon.elementary-gtk-theme pantheon.elementary-icon-theme ]; # exec "${pkgs.greetd.gtkgreet}/bin/gtkgreet -l -s /etc/greetd/gtkgreet.css; swaymsg exit" - environment.etc = { - "greetd/sway-config" = { - text = '' - # `-l` activates layer-shell mode. Notice that `swaymsg exit` will run after gtkgreet. - exec "${pkgs.greetd.regreet}/bin/regreet; swaymsg exit" - # bindsym Mod4+shift+f exec swaynag \ - # -t warning \ - # -m 'What do you want to do?' \ - # -b 'Poweroff' 'systemctl poweroff' \ - # -b 'Reboot' 'systemctl reboot' - include /etc/sway/config.d/* - ''; - user = "greeter"; - group = "greeter"; - }; - "greetd/environments" = { - text = concatStringsSep "\n" ((optional cfg.sway "${pkgs.sway}/bin/sway") - ++ [ "${pkgs.bash}/bin/bash" ]); - user = "greeter"; - group = "greeter"; - }; - "greetd/gtkgreet.css" = { - text = style; - user = "greeter"; - group = "greeter"; - }; - "sway/config.d/systemd-env.conf" = { - text = '' - exec_always --no-startup-id systemctl --user import-environment _JAVA_AWT_WM_NONREPARENTING MOZ_ENABLE_WAYLAND MOZ_DBUS_REMOTE QT_QPA_PLATFORM QT_WAYLAND_DISABLE_WINDOWDECORATION QT_QPA_PLATFORMTHEME SDL_VIDEODRIVER SSH_AUTH_SOCK - exec_always --no-startup-id dbus-update-activation-environment --systemd _JAVA_AWT_WM_NONREPARENTING MOZ_ENABLE_WAYLAND MOZ_DBUS_REMOTE QT_QPA_PLATFORM QT_WAYLAND_DISABLE_WINDOWDECORATION QT_QPA_PLATFORMTHEME SDL_VIDEODRIVER SSH_AUTH_SOCK - ''; - }; - "xdg/gtk-3.0/settings.ini" = { - text = generators.toINI { } { - Settings = { - gtk-theme-name = "elementary"; - gtk-icon-theme-name = "elementary"; - gtk-cursor-theme-name = "elementary"; - gtk-application-prefer-dark-theme = "true"; + networking.firewall.allowedTCPPorts = lib.mkIf cfg.wayvnc [ 5900 ]; + + environment = { + systemPackages = with pkgs; [ pantheon.elementary-gtk-theme pantheon.elementary-icon-theme ]; + etc = { + "greetd/sway-config" = { + text = lib.concatStringsSep "\n" + ((lib.optional cfg.wayvnc "exec ${pkgs.wayvnc}/bin/wayvnc -g 0.0.0.0") ++ + [ + '' + exec "${pkgs.greetd.regreet}/bin/regreet; swaymsg exit" + include /etc/sway/config.d/* + '' + ]); + user = "greeter"; + group = "greeter"; + }; + "greetd/environments" = { + text = concatStringsSep "\n" ((optional cfg.sway "${swaySession}") + ++ [ "${pkgs.bash}/bin/bash" ]); + user = "greeter"; + group = "greeter"; + }; + "greetd/gtkgreet.css" = { + text = style; + user = "greeter"; + group = "greeter"; + }; + "sway/config.d/systemd-env.conf" = { + text = '' + exec_always --no-startup-id systemctl --user import-environment _JAVA_AWT_WM_NONREPARENTING MOZ_ENABLE_WAYLAND MOZ_DBUS_REMOTE QT_QPA_PLATFORM QT_WAYLAND_DISABLE_WINDOWDECORATION QT_QPA_PLATFORMTHEME SDL_VIDEODRIVER SSH_AUTH_SOCK + exec_always --no-startup-id dbus-update-activation-environment --systemd _JAVA_AWT_WM_NONREPARENTING MOZ_ENABLE_WAYLAND MOZ_DBUS_REMOTE QT_QPA_PLATFORM QT_WAYLAND_DISABLE_WINDOWDECORATION QT_QPA_PLATFORMTHEME SDL_VIDEODRIVER SSH_AUTH_SOCK + ''; + }; + "xdg/gtk-3.0/settings.ini" = { + text = generators.toINI { } { + Settings = { + gtk-theme-name = "elementary"; + gtk-icon-theme-name = "elementary"; + gtk-cursor-theme-name = "elementary"; + gtk-application-prefer-dark-theme = "true"; + }; }; }; - }; - "xdg/gtk-4.0/settings.ini" = { - text = generators.toINI { } { - Settings = { - gtk-theme-name = "elementary"; - gtk-icon-theme-name = "elementary"; - gtk-cursor-theme-name = "elementary"; - gtk-application-prefer-dark-theme = "true"; + "xdg/gtk-4.0/settings.ini" = { + text = generators.toINI { } { + Settings = { + gtk-theme-name = "elementary"; + gtk-icon-theme-name = "elementary"; + gtk-cursor-theme-name = "elementary"; + gtk-application-prefer-dark-theme = "true"; + }; }; }; }; diff --git a/pkgs/rofi-wayland/default.nix b/pkgs/rofi-wayland/default.nix index 7c99b3e..bcb447b 100644 --- a/pkgs/rofi-wayland/default.nix +++ b/pkgs/rofi-wayland/default.nix @@ -2,12 +2,12 @@ with pkgs; stdenv.mkDerivation rec { pname = "rofi-wayland-unwrapped"; - version = "1.7.5"; + version = "1.7.5+wayland2"; src = fetchFromGitHub { owner = "lbonn"; repo = "rofi"; - rev = "${version}+wayland1"; + rev = version; fetchSubmodules = true; sha256 = "ddKLV7NvqgTQl5YlAEyBK0oalcJsLASK4z3qArQPUDQ="; }; diff --git a/users/erwin/home.nix b/users/erwin/home.nix index 49273f6..842f55b 100644 --- a/users/erwin/home.nix +++ b/users/erwin/home.nix @@ -2,6 +2,16 @@ with lib; let cfg = config.eboskma.users.erwin; bt = config.eboskma.bluetooth; + + ewwDaemon = + let + path = lib.makeBinPath (with pkgs; [ ha-now-playing jaq pamedia bash helvum pavucontrol ]); + in + pkgs.writeShellScript "eww-daemon" '' + export PATH=${path}:''${PATH} + + ${config.home-manager.users.erwin.eboskma.programs.eww.package}/bin/eww $@ + ''; in { config = @@ -89,7 +99,29 @@ in solvespace.enable = true; ssh.enable = true; starship.enable = true; - sway.enable = true; + sway = { + enable = true; + output = { + "DP-2" = { + # bg = "${./wallpapers/jwst-saturn-nircam-2560.png} fill"; + mode = "2560x1440@165Hz"; + adaptive_sync = "on"; + max_render_time = "2"; + }; + }; + input = { + "36125:40349:splitKB_Kyria" = { + xkb_layout = "us"; + xkb_options = "lv3:ralt_switch,eurosign:5"; + }; + "1133:49291:Logitech_G502_HERO_SE" = { + natural_scroll = "enabled"; + }; + }; + startup = [ + { command = "${ewwDaemon} --restart open bar-home"; always = true; } + ]; + }; swaynotificationcenter.enable = true; tea = { enable = true; diff --git a/users/erwin/work.nix b/users/erwin/work.nix index 367abfa..48ecee2 100644 --- a/users/erwin/work.nix +++ b/users/erwin/work.nix @@ -3,21 +3,30 @@ with lib; let cfg = config.eboskma.users.erwin; - remoteSessionScript = pkgs.writeShellScriptBin "remote-session" '' - ${pkgs.xorg.xrandr}/bin/xrandr --output DP-0 --mode 2560x1440 - ${pkgs.xorg.xrandr}/bin/xrandr --output DP-4 --mode 2560x1440 --right-of DP-0 - ${pkgs.nitrogen}/bin/nitrogen --head=0 --set-auto ${toString ./wallpapers/jwst-carina-cosmic-cliffs-nircam-2560.png} - ${pkgs.nitrogen}/bin/nitrogen --head=1 --set-auto ${toString ./wallpapers/jwst-southern-ring-nircam-miri-side-by-side-2560.png} - systemctl --user restart polybar - ''; - localSessionScript = pkgs.writeShellScriptBin "local-session" '' - ${pkgs.xorg.xrandr}/bin/xrandr --output DP-0 --mode 3840x2160 - ${pkgs.xorg.xrandr}/bin/xrandr --output DP-4 --mode 3840x2160 --right-of DP-0 - ${pkgs.nitrogen}/bin/nitrogen --head=0 --set-auto ${toString ./wallpapers/jwst-carina-cosmic-cliffs-nircam-3840.png} - ${pkgs.nitrogen}/bin/nitrogen --head=1 --set-auto ${toString ./wallpapers/jwst-southern-ring-nircam-miri-side-by-side-3840.png} - systemctl --user restart polybar - ''; + # remoteSessionScript = pkgs.writeShellScriptBin "remote-session" '' + # ${pkgs.xorg.xrandr}/bin/xrandr --output DP-0 --mode 2560x1440 + # ${pkgs.xorg.xrandr}/bin/xrandr --output DP-4 --mode 2560x1440 --right-of DP-0 + # ${pkgs.nitrogen}/bin/nitrogen --head=0 --set-auto ${toString ./wallpapers/jwst-carina-cosmic-cliffs-nircam-2560.png} + # ${pkgs.nitrogen}/bin/nitrogen --head=1 --set-auto ${toString ./wallpapers/jwst-southern-ring-nircam-miri-side-by-side-2560.png} + # systemctl --user restart polybar + # ''; + # localSessionScript = pkgs.writeShellScriptBin "local-session" '' + # ${pkgs.xorg.xrandr}/bin/xrandr --output DP-0 --mode 3840x2160 + # ${pkgs.xorg.xrandr}/bin/xrandr --output DP-4 --mode 3840x2160 --right-of DP-0 + # ${pkgs.nitrogen}/bin/nitrogen --head=0 --set-auto ${toString ./wallpapers/jwst-carina-cosmic-cliffs-nircam-3840.png} + # ${pkgs.nitrogen}/bin/nitrogen --head=1 --set-auto ${toString ./wallpapers/jwst-southern-ring-nircam-miri-side-by-side-3840.png} + # systemctl --user restart polybar + # ''; + ewwDaemon = + let + path = lib.makeBinPath (with pkgs; [ jaq pamedia bash helvum pavucontrol ]); + in + pkgs.writeShellScript "eww-daemon" '' + export PATH=${path}:''${PATH} + + ${config.home-manager.users.erwin.eboskma.programs.eww.package}/bin/eww $@ + ''; in { config = mkIf cfg.work { @@ -27,7 +36,7 @@ in eboskma = { var.workSystem = true; programs = { - alacritty.enable = true; + alacritty.enable = false; atuin.enable = true; bat.enable = true; cargo = { @@ -39,10 +48,10 @@ in }; }; dropbox.enable = true; - dunst.enable = true; + dunst.enable = false; emacs = { enable = true; - package = pkgs.emacs-unstable; + package = pkgs.emacs-unstable-pgtk; # .override { # treeSitterPlugins = builtins.attrValues (filterAttrs (_: isDerivation) pkgs.tree-sitter-grammars); # }; @@ -50,12 +59,17 @@ in }; eww = { enable = true; + package = pkgs.eww-wayland; }; firefox = { enable = true; work = true; }; fish.enable = true; + foot = { + enable = true; + server = false; + }; git = { enable = true; name = "Erwin Boskma"; @@ -65,7 +79,7 @@ in }; gpg.enable = true; i3 = { - enable = true; + enable = false; startupCommands = [ { command = "${pkgs.xorg.xrandr}/bin/xrandr --output DP-0 --primary --left-of DP-4"; @@ -82,10 +96,10 @@ in ]; }; mpd.enable = true; - nushell.enable = true; - picom.enable = true; - polybar.enable = true; neovim.enable = true; + nushell.enable = true; + picom.enable = false; + polybar.enable = false; rclone = { enable = true; mounts = [ @@ -103,25 +117,76 @@ in }; rofi = { enable = true; - terminal = config.home-manager.users.erwin.xsession.windowManager.i3.config.terminal; + package = pkgs.rofi-wayland; + terminal = config.home-manager.users.erwin.wayland.windowManager.sway.config.terminal; }; ssh.enable = true; starship.enable = true; - zellij = { + sway = { enable = true; - copyCommand = "${pkgs.xsel}/bin/xsel --clipboard"; + output = { + "DP-0" = { + # bg = "${./wallpapers/jwst-saturn-nircam-2560.png} fill"; + mode = "3840x2160@60Hz"; + position = "0 0"; + }; + "DP-4" = { + mode = "3840x2160@60Hz"; + position = "3840 0"; + }; + }; + input = { + "1241:662:USB-HID_Keyboard" = { + xkb_layout = "us"; + xkb_options = "lv3:ralt_switch,eurosign:5"; + }; + "1133:49257:Logitech_USB_Laser_Mouse" = { + natural_scroll = "enabled"; + pointer_accel = "1"; + }; + }; + startup = [ + { command = "${ewwDaemon} --restart open bar-work"; always = true; } + { command = "${pkgs.wayvnc}/bin/wayvnc -g 0.0.0.0"; } + ]; + }; + swaynotificationcenter.enable = true; + zellij = { + enable = false; + copyCommand = "${pkgs.wl-clipboard}/bin/wl-copy"; }; }; services = { - xbanish.enable = true; + xbanish.enable = false; }; }; - programs.home-manager.enable = true; - programs.command-not-found.enable = true; + programs = { + home-manager.enable = true; + command-not-found.enable = true; + }; + + services = { + gnome-keyring = { + enable = true; + components = [ "pkcs11" "ssh" "secrets" ]; + }; + udiskie = { + enable = true; + tray = "auto"; + notify = true; + settings = { + program_options = { + menu = "nested"; + }; + device_config = [ + { + device_file = "/dev/loop*"; + ignore = true; + } + ]; + }; + }; - services.gnome-keyring = { - enable = true; - components = [ "pkcs11" "ssh" "secrets" ]; }; home = { @@ -172,8 +237,8 @@ in zathura zeal - localSessionScript - remoteSessionScript + # localSessionScript + # remoteSessionScript ] ++ (with gst_all_1; [ gstreamer gstreamer.dev gst-plugins-base gst-plugins-good gst-plugins-bad gst-plugins-ugly gst-libav gst-vaapi ]); @@ -255,6 +320,11 @@ in }; }; + i18n.inputMethod = { + enabled = "fcitx5"; + fcitx5.addons = with pkgs; [ fcitx5-m17n fcitx5-gtk fcitx5-configtool ]; + }; + imports = [ ../../modules/options ] ++ (map (mod: (../../home-manager/modules + "/${mod}")) (builtins.attrNames (builtins.readDir ../../home-manager/modules))); @@ -277,7 +347,7 @@ in exportConfiguration = true; windowManager.i3 = { - enable = true; + enable = false; package = pkgs.i3-gaps; extraPackages = with pkgs; [ i3lock-color ]; };