This repository has no description
0

Configure Feed

Select the types of activity you want to include in your feed.

superconfig / 2configs / desktops / lib / wayland.nix
2.9 kB 124 lines
1{ 2 self, 3 pkgs, 4 lib, 5 ... 6}: 7{ 8 imports = [ 9 ../../alacritty.nix 10 ../../mpv.nix 11 ../../power-action.nix 12 ../../urxvt.nix 13 ../../xdg-open.nix 14 ../../yubikey.nix 15 ../../tmux.nix 16 ../../themes.nix 17 ../../fonts.nix 18 # ../pipewire.nix 19 # ./tty-share.nix 20 { 21 users.users.mainUser.packages = [ 22 pkgs.sshuttle 23 ]; 24 security.sudo.extraConfig = '' 25 lass ALL= (root) NOPASSWD:SETENV: ${pkgs.sshuttle}/bin/.sshuttle-wrapped 26 ''; 27 } 28 ]; 29 30 services.earlyoom = { 31 enable = true; 32 freeMemThreshold = 5; 33 }; 34 35 users.users.mainUser.extraGroups = [ 36 "audio" 37 "pipewire" 38 "video" 39 "input" 40 ]; 41 42 xdg.portal.enable = true; 43 xdg.portal.extraPortals = [ pkgs.xdg-desktop-portal-gtk ]; 44 xdg.portal.wlr.enable = true; 45 xdg.portal.config.common.default = "*"; # get old behavior back 46 fonts.enableDefaultPackages = true; 47 48 security.polkit.enable = true; 49 security.pam.services.swaylock = { }; 50 51 programs.dconf.enable = lib.mkDefault true; 52 services.gnome.gnome-keyring.enable = lib.mkDefault true; 53 programs.xwayland.enable = lib.mkDefault true; 54 55 environment.sessionVariables = { 56 MOZ_ENABLE_WAYLAND = "1"; 57 XDG_SESSION_TYPE = "wayland"; 58 SDL_VIDEODRIVER = "wayland"; 59 QT_QPA_PLATFORM = "wayland"; 60 QT_WAYLAND_DISABLE_WINDOWDECORATION = "1"; 61 _JAVA_AWT_WM_NONREPARENTING = "1"; 62 NIXOS_OZONE_WL = "1"; # Hint for electron apps to use wayland 63 }; 64 65 programs.wshowkeys.enable = true; 66 67 environment.systemPackages = with pkgs; [ 68 swaylock-effects # lockscreen 69 pavucontrol 70 swayidle 71 rofi-wayland 72 rofi-rbw 73 eog 74 libnotify 75 mako # notifications 76 kanshi # auto-configure display outputs 77 wdisplays # buggy with qtile? 78 wlr-randr 79 wl-clipboard 80 wev 81 blueberry 82 grim # screenshots 83 wtype 84 zathura 85 nsxiv 86 87 pavucontrol 88 evince 89 libnotify 90 pamixer 91 file-roller 92 xdg-utils 93 # polkit agent 94 polkit_gnome 95 96 # gtk3 themes 97 gsettings-desktop-schemas 98 self.packages.${pkgs.system}.otpmenu 99 (pkgs.writers.writeDashBin "pass_menu" '' 100 set -efux 101 password=$( 102 (cd $HOME/.password-store; find -type f -name '*.gpg') | 103 sed -e 's/\.gpg$//' | 104 rofi -dmenu -p 'Password: ' | 105 xargs -I{} pass show {} | 106 tr -d '\n' 107 ) 108 echo -n "$password" | ${pkgs.wtype}/bin/wtype -d 10 -s 400 - 109 '') 110 (pkgs.writers.writeDashBin "screenshot" '' 111 ${pkgs.grim}/bin/grim -g "$(${pkgs.slurp}/bin/slurp)" - | ${pkgs.wl-clipboard}/bin/wl-copy 112 '') 113 (pkgs.writers.writeDashBin "type_paste" '' 114 ${pkgs.wl-clipboard}/bin/wl-paste | ${pkgs.wtype}/bin/wtype -d 10 -s 400 - 115 '') 116 ]; 117 118 environment.pathsToLink = [ 119 "/libexec" # for polkit 120 "/share/gsettings-schemas" # for XDG_DATA_DIRS 121 ]; 122 123 qt.platformTheme = "qt5ct"; 124}