sway: Fully move to home-manager (where possible)
This commit is contained in:
parent
f02590d824
commit
fa231a7196
|
@ -5,9 +5,4 @@
|
||||||
console.keyMap = "de";
|
console.keyMap = "de";
|
||||||
|
|
||||||
time.timeZone = "Europe/Berlin";
|
time.timeZone = "Europe/Berlin";
|
||||||
|
|
||||||
location = {
|
|
||||||
latitude = 49.52;
|
|
||||||
longitude = 10.17;
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,44 +1,7 @@
|
||||||
{ config, pkgs, ... }:
|
{ config, pkgs, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
programs.sway = {
|
programs.sway.enable = true; # actual configuration happens in home-manager
|
||||||
enable = true;
|
|
||||||
extraPackages = with pkgs; [
|
|
||||||
swaylock # lockscreen
|
|
||||||
swayidle # autolock
|
|
||||||
xwayland # for legacy apps
|
|
||||||
unstable.waybar # better status bar FIXME: 0.9.3 is broken, 0.9.4 from unstable works
|
|
||||||
mako # notification daemon
|
|
||||||
#kanshi # autorandr
|
|
||||||
alacritty # temrinal
|
|
||||||
dmenu-wayland # launcher
|
|
||||||
brightnessctl # control screen brightness
|
|
||||||
#redshift-wlr # natural color temperature
|
|
||||||
sway-contrib.grimshot # screenshots
|
|
||||||
];
|
|
||||||
extraSessionCommands = ''
|
|
||||||
export CLUTTER_BACKEND=wayland
|
|
||||||
export GDK_BACKEND=wayland
|
|
||||||
export MOZ_ENABLE_WAYLAND=1
|
|
||||||
export QT_QPA_PLATFORM=wayland-egl
|
|
||||||
export QT_WAYLAND_DISABLE_WINDOWDECORATION=1
|
|
||||||
export SDL_VIDEODRIVER=wayland
|
|
||||||
export WLR_NO_HARDWARE_CURSORS=1
|
|
||||||
export _JAVA_AWT_WM_NONREPARENTING=1
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
services.redshift = {
|
|
||||||
enable = true;
|
|
||||||
package = pkgs.redshift-wlr;
|
|
||||||
extraOptions = [ "-v" "-m" "wayland" ];
|
|
||||||
temperature = {
|
|
||||||
day = 6500;
|
|
||||||
night = 3500;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
systemd.user.targets.graphical-session.wantedBy = [ "multi-user.target" ];
|
|
||||||
|
|
||||||
services.logind.lidSwitchDocked = config.services.logind.lidSwitch;
|
services.logind.lidSwitchDocked = config.services.logind.lidSwitch;
|
||||||
}
|
}
|
||||||
|
|
|
@ -215,6 +215,25 @@ in
|
||||||
export _JAVA_AWT_WM_NONREPARENTING=1
|
export _JAVA_AWT_WM_NONREPARENTING=1
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# Start on tty1
|
||||||
|
home.file = {
|
||||||
|
".zprofile".text = ''
|
||||||
|
if [[ -z $WAYLAND_DISPLAY ]] && [[ $(tty) = /dev/tty1 ]] && command -v sway >/dev/null ; then
|
||||||
|
systemctl --user start graphical-session.target
|
||||||
|
export XDG_SESSION_TYPE="wayland"
|
||||||
|
exec sway
|
||||||
|
fi
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
alacritty # terminal
|
||||||
|
brightnessctl # control screen brightness
|
||||||
|
sway-contrib.grimshot # screenshots
|
||||||
|
unstable.waybar # better status bar FIXME: 0.9.3 is broken, 0.9.4 from unstable works
|
||||||
|
];
|
||||||
|
|
||||||
xdg.configFile = {
|
xdg.configFile = {
|
||||||
# home-manager’s waybar module performs additional checks that are overly strict
|
# home-manager’s waybar module performs additional checks that are overly strict
|
||||||
"waybar/config".text = builtins.toJSON {
|
"waybar/config".text = builtins.toJSON {
|
||||||
|
@ -379,15 +398,6 @@ in
|
||||||
src = ../files/waybar/style.css;
|
src = ../files/waybar/style.css;
|
||||||
} // solarized);
|
} // solarized);
|
||||||
};
|
};
|
||||||
home.file = {
|
|
||||||
".zprofile".text = ''
|
|
||||||
if [[ -z $WAYLAND_DISPLAY ]] && [[ $(tty) = /dev/tty1 ]] && command -v sway >/dev/null ; then
|
|
||||||
systemctl --user start graphical-session.target
|
|
||||||
export XDG_SESSION_TYPE="wayland"
|
|
||||||
exec sway
|
|
||||||
fi
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
programs.mako = {
|
programs.mako = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
@ -401,4 +411,16 @@ in
|
||||||
|
|
||||||
defaultTimeout = 5000;
|
defaultTimeout = 5000;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
services.redshift = {
|
||||||
|
enable = true;
|
||||||
|
package = pkgs.redshift-wlr;
|
||||||
|
extraOptions = [ "-v" "-m" "wayland" ];
|
||||||
|
latitude = "49.52";
|
||||||
|
longitude = "10.17";
|
||||||
|
temperature = {
|
||||||
|
day = 6500;
|
||||||
|
night = 3500;
|
||||||
|
};
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue