some initial work on hyprland

This commit is contained in:
Grisha Shipunov 2025-02-25 22:21:34 +01:00
parent ffd3541e93
commit 948d398c85
4 changed files with 86 additions and 49 deletions

View file

@ -47,6 +47,11 @@
inputs.flake-utils.follows = "flake-utils";
};
home-manager = {
url = "github:nix-community/home-manager";
inputs.nixpkgs.follows = "nixpkgs";
};
tmux-yank = {
url = "github:tmux-plugins/tmux-yank";
flake = false;
@ -56,6 +61,7 @@
outputs =
inputs@{
authentik-nix,
home-manager,
lanzaboote,
lix-module,
microvm,
@ -105,13 +111,19 @@
lanzaboote.nixosModules.lanzaboote
nixos-hardware.nixosModules.lenovo-thinkpad-t14-amd-gen3
lix-module.nixosModules.default
home-manager.nixosModules.home-manager
{
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.users."0xa" = import ./hosts/toster/0xa-home.nix;
}
./hosts/toaster
./modules/basic-tools
./modules/binary-caches.nix
./modules/devtools.nix
./modules/gnome.nix
./modules/hyprland.nix
./modules/gnupg.nix
./modules/radio.nix
./modules/science.nix

View file

@ -0,0 +1,4 @@
{ ... }:
{
}

View file

@ -1,4 +1,4 @@
{ lib, config, ... }:
{ lib, pkgs, ... }:
{
imports = [
./mullvad.nix
@ -6,26 +6,21 @@
./zw.nix
];
# Networkmanager shouldn't interfere with systemd managed interfaces
networking.networkmanager.unmanaged =
let
systemd_netdevs = lib.attrsets.attrValues (
lib.attrsets.mapAttrs (_name: value: value.netdevConfig.Name) config.systemd.network.netdevs
);
in
systemd_netdevs;
environment.systemPackages = with pkgs; [
iwgtk
impala
];
systemd.network = {
enable = true;
wait-online.enable = false; # uplink is managed by networkmanager
};
users.users."0xa".extraGroups = [ "networkmanager" ];
# kick out networkmanager
networking.networkmanager.enable = lib.mkForce false;
networking.useNetworkd = true;
systemd.network.enable = true;
networking = {
hostName = "toaster";
firewall.enable = true;
wireguard.enable = true;
wireless.iwd.enable = true;
};
services.resolved = {
@ -39,4 +34,38 @@
];
};
# we might have no interwebs at all
systemd.network.wait-online.enable = false;
# uplinks
systemd.network.networks = {
"10-ether-uplink" = {
matchConfig.Name = "enp1s0f0";
networkConfig = {
DHCP = "yes";
IPv6AcceptRA = true;
};
};
"10-dock-uplink" = {
matchConfig.Name = "enp5s0f4u1u1";
networkConfig = {
DHCP = "yes";
IPv6AcceptRA = true;
};
dhcpV4Config = {
RouteMetric = 666;
};
dhcpV6Config = {
RouteMetric = 666;
};
};
"wlan-uplink" = {
matchConfig.Name = "wlan0";
networkConfig = {
DHCP = "yes";
IPv6AcceptRA = true;
};
};
};
}

View file

@ -28,6 +28,27 @@ in
spotify-player
zathura
ncdu
adwaita-icon-theme
bluetui
foot
gammastep
graphicsmagick
grim
unstablepkgs.i3status-rust
impala
kanshi
swaynotificationcenter
pamixer
wofi
slurp
swayidle
swaylock
wl-clipboard
wl-mirror
xfce.thunar
nwg-look
banana-cursor
];
# Enable sound.
@ -52,38 +73,9 @@ in
programs.light.enable = true;
programs.xwayland.enable = true;
programs.sway = {
enable = true;
wrapperFeatures.gtk = true;
extraSessionCommands = ''
export SDL_VIDEODRIVER=wayland
export QT_QPA_PLATFORM=wayland-egl
export QT_WAYLAND_DISABLE_WINDOWDECORATION="1"
export QT_QPA_PLATFORMTHEME="gnome"
export QT_STYLE_OVERRIDE="adwaita-dark"
# export WLR_DRM_NO_ATOMIC=1
'';
extraPackages = with pkgs; [
adwaita-icon-theme
bluetui
foot
gammastep
graphicsmagick
grim
unstablepkgs.i3status-rust
impala
kanshi
swaynotificationcenter
pamixer
rofi-wayland
slurp
swayidle
swaylock
wl-clipboard
wl-mirror
xfce.thunar
];
};
programs.hyprland.enable = true;
environment.sessionVariables = {
GTK_THEME = "Adwaita:dark";
};
@ -118,7 +110,7 @@ in
enable = true;
settings = {
default_session = {
command = "${pkgs.greetd.tuigreet}/bin/tuigreet --time --greeting \"$(${pkgs.fortune}/bin/fortune -s)\" --cmd ${pkgs.sway}/bin/sway";
command = "${pkgs.greetd.tuigreet}/bin/tuigreet --time --greeting \"$(${pkgs.fortune}/bin/fortune -s)\" --cmd ${pkgs.hyprland}/bin/Hyprland";
};
};
};