Refactor sway stuff
This commit is contained in:
parent
c6efec9bb7
commit
1f76671a71
5 changed files with 80 additions and 34 deletions
|
|
@ -12,6 +12,7 @@
|
|||
../modules/desktop.nix
|
||||
../modules/brother-printer.nix
|
||||
../modules/home.nix
|
||||
../modules/sway.nix
|
||||
];
|
||||
|
||||
# Bootloader.
|
||||
|
|
|
|||
|
|
@ -7,40 +7,15 @@
|
|||
layout = "us";
|
||||
variant = "dvorak";
|
||||
};
|
||||
|
||||
displayManager.gdm = {
|
||||
enable = true;
|
||||
wayland = true;
|
||||
};
|
||||
};
|
||||
|
||||
# enable sway
|
||||
programs.sway = {
|
||||
services.displayManager.gdm = {
|
||||
enable = true;
|
||||
wrapperFeatures.gtk = true;
|
||||
wayland = true;
|
||||
};
|
||||
|
||||
# 2. Inject the Dvorak config into /etc/sway/config.d/
|
||||
# The default Sway config automatically includes files in this folder.
|
||||
environment.etc."sway/config.d/99-dvorak.conf".text = ''
|
||||
input * {
|
||||
xkb_layout "us"
|
||||
xkb_variant "dvorak"
|
||||
}
|
||||
'';
|
||||
|
||||
|
||||
# Essential System Services for Sway
|
||||
# (Sway doesn't autostart these like GNOME does, so you need them enabled
|
||||
# system-wide)
|
||||
security.polkit.enable = true; # For permission popups
|
||||
services.gnome.gnome-keyring.enable = true; # For saving wifi/login passwords
|
||||
|
||||
services.desktopManager.gnome.enable = true;
|
||||
|
||||
# Enable the GNOME Desktop Environment.
|
||||
services.displayManager.gdm.enable = true;
|
||||
|
||||
# enable japanese input
|
||||
i18n.inputMethod = {
|
||||
enable = true;
|
||||
|
|
@ -68,13 +43,6 @@
|
|||
bitwarden-desktop
|
||||
libreoffice-fresh
|
||||
|
||||
# sway stuff
|
||||
grim # screenshot functionality
|
||||
slurp # screenshot functionality
|
||||
wl-clipboard # wl-copy and wl-paste for copy/paste from stdin / stdout
|
||||
mako # notification system developed by swaywm maintainer
|
||||
];
|
||||
|
||||
# Enable networking
|
||||
networking.networkmanager.enable = true;
|
||||
|
||||
|
|
|
|||
19
hosts/modules/sway.nix
Normal file
19
hosts/modules/sway.nix
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
{ config, pkgs, ... }:
|
||||
{
|
||||
# Enable the Sway binary and hardware wrappers
|
||||
programs.sway = {
|
||||
enable = true;
|
||||
wrapperFeatures.gtk = true;
|
||||
};
|
||||
|
||||
# Hardware and security services that must be system-wide
|
||||
services.gnome.gnome-keyring.enable = true;
|
||||
security.polkit.enable = true;
|
||||
programs.light.enable = true; # Allow brightness control
|
||||
|
||||
# Move system-wide packages here
|
||||
environment.systemPackages = with pkgs; [
|
||||
pavucontrol
|
||||
light
|
||||
];
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue