archachatina: use sway

This commit is contained in:
Gabriel Ebner 2020-07-14 15:09:49 +02:00
parent e1b97efdb2
commit 05c4373f1b
2 changed files with 45 additions and 15 deletions

@ -3,8 +3,8 @@
{
imports =
[
./common.nix
# ./common-headless.nix ./sway.nix
# ./common.nix
./common-headless.nix ./sway.nix
./large-sw.nix
./uefi.nix
./fstrim.nix
@ -43,7 +43,6 @@
flac
clementine
recoll
uvccapture
piper
@ -114,8 +113,4 @@
system.stateVersion = "18.03";
programs.x2goserver = {
enable = true;
};
}

@ -33,12 +33,23 @@
gnome_settings_daemon
gnome_themes_standard defaultIconTheme
hicolor_icon_theme
gnome-terminal
# for QT_QPA_PLATFORM=wayland
qt5.qtwayland
wdisplays
(pkgs.writeScriptBin "gsd-xsettings"
''
#!/bin/sh
exec ${pkgs.gnome3.gnome-settings-daemon}/libexec/gsd-xsettings "$@"
'')
];
nixpkgs.config.packageOverrides = pkgs: with pkgs; {
firefox = firefox-wayland;
};
fonts = {
enableDefaultFonts = false;
fonts = with pkgs; [
@ -68,6 +79,9 @@
];
};
# prevent satanic torture
programs.qt5ct.enable = true;
programs.sway = {
enable = true;
@ -85,15 +99,22 @@
# use this if they aren't displayed properly:
export _JAVA_AWT_WM_NONREPARENTING=1
# rust winit's wayland support is broken for input methods
export WINIT_UNIX_BACKEND=x11
export XDG_DATA_DIRS=/run/current-system/sw/share/''${XDG_DATA_DIRS:+:}$XDG_DATA_DIRS
export $(${pkgs.gnome3.gnome_keyring}/bin/gnome-keyring-daemon --start --components=pkcs11,secrets,ssh,gpg)
export XDG_CURRENT_DESKTOP=X-Generic
for m in xsettings; do
${pkgs.gnome3.gnome_settings_daemon}/libexec/gsd-$m &
done
'';
};
services.xserver = {
enable = true;
libinput.enable = true;
displayManager.lightdm.enable = true;
displayManager.defaultSession = "sway";
};
users.extraUsers.gebner.extraGroups = [ "input" "tty" "audio" "video" ];
# layout = "us";
@ -101,7 +122,7 @@
# xkbOptions = "caps:ctrl_modifier";
services.dbus.packages = with pkgs; [ mako gnome3.gcr ];
services.udev.packages = [ pkgs.gnome3.gnome_settings_daemon ];
services.udev.packages = [ pkgs.gnome3.gnome-settings-daemon ];
# copied from gnome3 module
security.polkit.enable = true;
@ -110,15 +131,19 @@
services.geoclue2.enable = true;
services.gnome3.at-spi2-core.enable = true;
services.gnome3.gnome-keyring.enable = true;
services.gnome3.gvfs.enable = true;
services.gnome3.seahorse.enable = true;
services.gvfs.enable = true;
programs.seahorse.enable = true;
services.gnome3.sushi.enable = true;
services.gnome3.gnome-settings-daemon.enable = true;
services.telepathy.enable = true;
networking.networkmanager.enable = true;
services.upower.enable = config.powerManagement.enable;
programs.dconf.enable = true;
services.flatpak.enable = true;
services.flatpak.extraPortals = [ pkgs.xdg-desktop-portal-gtk ];
xdg.portal = {
enable = true;
extraPortals = [ pkgs.xdg-desktop-portal-gtk ];
};
# Needed for themes and backgrounds
environment.pathsToLink = [ "/share" ];
environment.variables.GIO_EXTRA_MODULES = with pkgs.gnome3; [
@ -130,15 +155,25 @@
enable = true;
package = pkgs.bluezFull;
};
services.blueman.enable = true;
hardware.pulseaudio = {
enable = true;
zeroconf.discovery.enable = true;
daemon.config = {
flat-volumes = "no";
avoid-resampling = "yes";
resample-method = "speex-float-10";
default-sample-format = "s32le";
default-sample-rate = "96000";
};
package = pkgs.pulseaudioFull;
extraModules = [ pkgs.pulseaudio-modules-bt ];
};
programs.gnupg = {
agent.enable = true;
agent.pinentryFlavor = "gnome3";
};
}