refactor: cleanup configs, unify session handling
- flake.nix:
- Close braces formatting for `allowUnfree`
- Remove per-user `custom.sessionType` modules
- home-manager:
- home.nix: remove unused apps (bambu-studio, hydralauncher, keymapp, etc.)
- drop librespot service
- add waydroid
- fix kitty font_family spacing
- gnome: add gnome-tweaks and appindicator extension
- vim: update nixvim module import path
- zsh: drop sessionType option and conditional aliases
- hardcode wl-copy/wl-paste as pbcopy/pbpaste
- hyprland: style fixes in braces, spacing, keybind comments
- hosts/Nixstation:
- remove gnome-session and redundant tweaks
- remove env vars NIXOS_HOST / NIXOS_DE
- enable virtualization (libvirtd, spiceUSBRedirection, vmware.host=false)
- hardware-configuration: reformat fileSystems definitions
- common/nvidia:
- remove explicit kernelPackages override
- ensure xserver.enable=true and GNOME/GDM config intact
- users/thiago: reorder and regroup extraGroups list
This commit is contained in:
parent
ea25b5b515
commit
95e94196b2
11 changed files with 70 additions and 133 deletions
|
|
@ -37,7 +37,8 @@
|
||||||
Nixstation = nixpkgs.lib.nixosSystem {
|
Nixstation = nixpkgs.lib.nixosSystem {
|
||||||
specialArgs = {
|
specialArgs = {
|
||||||
inherit inputs outputs;
|
inherit inputs outputs;
|
||||||
allowUnfree = true;};
|
allowUnfree = true;
|
||||||
|
};
|
||||||
modules = [
|
modules = [
|
||||||
./hosts/Nixstation
|
./hosts/Nixstation
|
||||||
];
|
];
|
||||||
|
|
@ -52,7 +53,6 @@
|
||||||
};
|
};
|
||||||
modules = [
|
modules = [
|
||||||
./home-manager/home.nix
|
./home-manager/home.nix
|
||||||
{ custom.sessionType = "wayland"; }
|
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
"thiago@Nixstation" = home-manager.lib.homeManagerConfiguration {
|
"thiago@Nixstation" = home-manager.lib.homeManagerConfiguration {
|
||||||
|
|
@ -63,7 +63,6 @@
|
||||||
|
|
||||||
modules = [
|
modules = [
|
||||||
./home-manager/home.nix
|
./home-manager/home.nix
|
||||||
{ custom.sessionType = "wayland"; }
|
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
||||||
|
|
@ -27,6 +27,8 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
|
gnome-tweaks
|
||||||
|
gnomeExtensions.appindicator
|
||||||
gnomeExtensions.pop-shell
|
gnomeExtensions.pop-shell
|
||||||
gnomeExtensions.forge
|
gnomeExtensions.forge
|
||||||
gnomeExtensions.tray-icons-reloaded
|
gnomeExtensions.tray-icons-reloaded
|
||||||
|
|
@ -34,6 +36,5 @@
|
||||||
gnomeExtensions.sound-output-device-chooser
|
gnomeExtensions.sound-output-device-chooser
|
||||||
gnomeExtensions.space-bar
|
gnomeExtensions.space-bar
|
||||||
nordzy-icon-theme
|
nordzy-icon-theme
|
||||||
|
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
@ -26,40 +26,26 @@
|
||||||
home = {
|
home = {
|
||||||
homeDirectory = "/home/thiago";
|
homeDirectory = "/home/thiago";
|
||||||
packages = with pkgs; [
|
packages = with pkgs; [
|
||||||
bambu-studio
|
|
||||||
direnv
|
direnv
|
||||||
fira-code
|
fira-code
|
||||||
firefox
|
firefox
|
||||||
heroic
|
heroic
|
||||||
hwinfo
|
hwinfo
|
||||||
hydralauncher
|
|
||||||
inkscape
|
inkscape
|
||||||
wl-clipboard
|
|
||||||
kanshi
|
|
||||||
keymapp
|
|
||||||
lazygit
|
lazygit
|
||||||
libinput
|
libinput
|
||||||
librespot
|
|
||||||
luarocks
|
|
||||||
nerd-fonts.gohufont
|
|
||||||
nerd-fonts.fira-code
|
nerd-fonts.fira-code
|
||||||
nil
|
nil
|
||||||
nixpkgs-fmt
|
nixpkgs-fmt
|
||||||
nordic
|
nordic
|
||||||
obsidian
|
obsidian
|
||||||
python3
|
python3
|
||||||
python3Packages.pip
|
|
||||||
ripgrep
|
ripgrep
|
||||||
shfmt
|
|
||||||
statix
|
statix
|
||||||
stylua
|
|
||||||
sysbench
|
|
||||||
swaybg
|
|
||||||
transmission_4
|
|
||||||
uget
|
uget
|
||||||
unzip
|
unzip
|
||||||
|
waydroid
|
||||||
wl-clipboard
|
wl-clipboard
|
||||||
zed-editor
|
|
||||||
];
|
];
|
||||||
username = "thiago";
|
username = "thiago";
|
||||||
};
|
};
|
||||||
|
|
@ -113,12 +99,11 @@
|
||||||
settings = {
|
settings = {
|
||||||
hide_window_decorations = "titlebar-only";
|
hide_window_decorations = "titlebar-only";
|
||||||
font_size = 18;
|
font_size = 18;
|
||||||
font_family="GohuFont 14 Nerd Font Mono";
|
font_family = "GohuFont 14 Nerd Font Mono";
|
||||||
inactive_text_alpha = "0.6";
|
inactive_text_alpha = "0.6";
|
||||||
# background_blur = 32;
|
# background_blur = 32;
|
||||||
background_opacity = 1.0;
|
background_opacity = 1.0;
|
||||||
};
|
};
|
||||||
themeFile = "Nord";
|
|
||||||
};
|
};
|
||||||
|
|
||||||
vscode = {
|
vscode = {
|
||||||
|
|
@ -126,29 +111,6 @@
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
systemd.user.services.librespot-connect = {
|
|
||||||
Unit = {
|
|
||||||
Description = "Librespot (Spotify Connect) bound to LAN interface";
|
|
||||||
After = [ "network.target" ];
|
|
||||||
};
|
|
||||||
Service = {
|
|
||||||
ExecStart = "${pkgs.librespot}/bin/librespot \
|
|
||||||
--name LS-TEST \
|
|
||||||
--backend pulseaudio \
|
|
||||||
--device default \
|
|
||||||
--bitrate 320 \
|
|
||||||
--disable-audio-cache \
|
|
||||||
--enable-volume-normalisation \
|
|
||||||
--initial-volume 75 \
|
|
||||||
--zeroconf-port 17005";
|
|
||||||
Restart = "on-failure";
|
|
||||||
BindToDevice = "wlp7s0"; # Force binding to LAN interface
|
|
||||||
};
|
|
||||||
Install = {
|
|
||||||
WantedBy = [ "default.target" ];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
systemd.user.startServices = "sd-switch";
|
systemd.user.startServices = "sd-switch";
|
||||||
home.stateVersion = "25.11";
|
home.stateVersion = "25.11";
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
{lib, ...}: {
|
{ lib, ... }:
|
||||||
|
{
|
||||||
home.sessionVariables = {
|
home.sessionVariables = {
|
||||||
fileManager = "thunar";
|
fileManager = "thunar";
|
||||||
menu = "fuzzel --show drun";
|
menu = "fuzzel --show drun";
|
||||||
|
|
@ -34,7 +35,7 @@
|
||||||
enable = true;
|
enable = true;
|
||||||
settings = {
|
settings = {
|
||||||
"$mod" = "SUPER";
|
"$mod" = "SUPER";
|
||||||
layerrule =[
|
layerrule = [
|
||||||
"ignorezero, waybar"
|
"ignorezero, waybar"
|
||||||
"blur, waybar"
|
"blur, waybar"
|
||||||
];
|
];
|
||||||
|
|
@ -80,7 +81,6 @@
|
||||||
"$mod, mouse_up, workspace, e-1"
|
"$mod, mouse_up, workspace, e-1"
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
||||||
bindm = [
|
bindm = [
|
||||||
"$mod, mouse:272, movewindow" # Hold $mod and left mouse button to move window
|
"$mod, mouse:272, movewindow" # Hold $mod and left mouse button to move window
|
||||||
"$mod, mouse:273, resizewindow" # Hold $mod and right mouse button to resize window
|
"$mod, mouse:273, resizewindow" # Hold $mod and right mouse button to resize window
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
inputs.nixvim.homeManagerModules.nixvim
|
inputs.nixvim.homeModules.nixvim
|
||||||
];
|
];
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
ripgrep
|
ripgrep
|
||||||
|
|
@ -96,4 +96,3 @@
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3,16 +3,7 @@
|
||||||
, pkgs
|
, pkgs
|
||||||
, ...
|
, ...
|
||||||
}:
|
}:
|
||||||
let
|
|
||||||
isWayland = config.custom.sessionType == "wayland";
|
|
||||||
in
|
|
||||||
{
|
{
|
||||||
options.custom.sessionType = lib.mkOption {
|
|
||||||
type = lib.types.str;
|
|
||||||
default = "x11";
|
|
||||||
description = "The X session type: 'wayland' or 'x11'";
|
|
||||||
};
|
|
||||||
|
|
||||||
config = {
|
config = {
|
||||||
home.file."scripts/lsgpu.sh" = {
|
home.file."scripts/lsgpu.sh" = {
|
||||||
source = ./scripts/lsgpu.sh;
|
source = ./scripts/lsgpu.sh;
|
||||||
|
|
@ -28,25 +19,15 @@ in
|
||||||
export GPG_TTY=$(tty)
|
export GPG_TTY=$(tty)
|
||||||
'';
|
'';
|
||||||
|
|
||||||
shellAliases = lib.mkMerge [
|
shellAliases = {
|
||||||
{
|
|
||||||
"vi" = "nvim";
|
"vi" = "nvim";
|
||||||
"vim" = "nvim";
|
"vim" = "nvim";
|
||||||
"ll" = "ls -l";
|
"ll" = "ls -l";
|
||||||
"lsgpu" = "$HOME/scripts/lsgpu.sh";
|
"lsgpu" = "$HOME/scripts/lsgpu.sh";
|
||||||
"gedit" = "gnome-text-editor";
|
"gedit" = "gnome-text-editor";
|
||||||
}
|
|
||||||
|
|
||||||
(lib.mkIf isWayland {
|
|
||||||
"pbcopy" = "wl-copy";
|
"pbcopy" = "wl-copy";
|
||||||
"pbpaste" = "wl-paste";
|
"pbpaste" = "wl-paste";
|
||||||
})
|
};
|
||||||
|
|
||||||
(lib.mkIf (!isWayland) {
|
|
||||||
"pbcopy" = "xclip -selection clipboard -i";
|
|
||||||
"pbpaste" = "xclip -selection clipboard -o";
|
|
||||||
})
|
|
||||||
];
|
|
||||||
|
|
||||||
oh-my-zsh = {
|
oh-my-zsh = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|
@ -57,7 +38,5 @@ in
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
home.packages = with pkgs; [ xclip ];
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -12,7 +12,9 @@
|
||||||
boot = {
|
boot = {
|
||||||
loader.systemd-boot.enable = true;
|
loader.systemd-boot.enable = true;
|
||||||
loader.efi.canTouchEfiVariables = true;
|
loader.efi.canTouchEfiVariables = true;
|
||||||
|
# kernelPackages = pkgs.linuxPackages_6_16;
|
||||||
};
|
};
|
||||||
|
|
||||||
environment = {
|
environment = {
|
||||||
systemPackages = with pkgs; [
|
systemPackages = with pkgs; [
|
||||||
act
|
act
|
||||||
|
|
@ -21,14 +23,7 @@
|
||||||
networkmanagerapplet
|
networkmanagerapplet
|
||||||
libwacom
|
libwacom
|
||||||
wacomtablet
|
wacomtablet
|
||||||
gnome-tweaks
|
|
||||||
gnome-session
|
|
||||||
];
|
];
|
||||||
|
|
||||||
variables = {
|
|
||||||
NIXOS_HOST = "nixstation";
|
|
||||||
NIXOS_DE = "wayland";
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
|
|
||||||
hardware = {
|
hardware = {
|
||||||
|
|
@ -144,15 +139,15 @@
|
||||||
};
|
};
|
||||||
system.stateVersion = "25.11"; # keep it!
|
system.stateVersion = "25.11"; # keep it!
|
||||||
time.timeZone = "America/Sao_Paulo";
|
time.timeZone = "America/Sao_Paulo";
|
||||||
# virtualisation = {
|
virtualisation = {
|
||||||
# vmware.host.enable = false;
|
vmware.host.enable = false;
|
||||||
# spiceUSBRedirection.enable = true;
|
spiceUSBRedirection.enable = true;
|
||||||
# libvirtd = {
|
libvirtd = {
|
||||||
# enable = true;
|
enable = true;
|
||||||
# qemu.ovmf.enable = true;
|
qemu.ovmf.enable = true;
|
||||||
# # qemu.package = pkgs.qemu_full;
|
# qemu.package = pkgs.qemu_full;
|
||||||
# };
|
};
|
||||||
# };
|
};
|
||||||
|
|
||||||
zramSwap = {
|
zramSwap = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|
|
||||||
|
|
@ -26,22 +26,25 @@
|
||||||
extraModulePackages = [ ];
|
extraModulePackages = [ ];
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/" =
|
fileSystems."/" = {
|
||||||
{ device = "/dev/disk/by-uuid/07c4d31f-e1cd-4a02-8b3f-8c2bd2e0ce8d";
|
device = "/dev/disk/by-uuid/07c4d31f-e1cd-4a02-8b3f-8c2bd2e0ce8d";
|
||||||
fsType = "btrfs";
|
fsType = "btrfs";
|
||||||
options = [ "subvol=@" ];
|
options = [ "subvol=@" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/home" =
|
fileSystems."/home" = {
|
||||||
{ device = "/dev/disk/by-uuid/07c4d31f-e1cd-4a02-8b3f-8c2bd2e0ce8d";
|
device = "/dev/disk/by-uuid/07c4d31f-e1cd-4a02-8b3f-8c2bd2e0ce8d";
|
||||||
fsType = "btrfs";
|
fsType = "btrfs";
|
||||||
options = [ "subvol=@home" ];
|
options = [ "subvol=@home" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/boot" =
|
fileSystems."/boot" = {
|
||||||
{ device = "/dev/disk/by-uuid/D2EA-469F";
|
device = "/dev/disk/by-uuid/D2EA-469F";
|
||||||
fsType = "vfat";
|
fsType = "vfat";
|
||||||
options = [ "fmask=0077" "dmask=0077" ];
|
options = [
|
||||||
|
"fmask=0077"
|
||||||
|
"dmask=0077"
|
||||||
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
swapDevices = [ ];
|
swapDevices = [ ];
|
||||||
|
|
|
||||||
|
|
@ -6,9 +6,8 @@
|
||||||
# ./passthrough.nix
|
# ./passthrough.nix
|
||||||
];
|
];
|
||||||
boot.kernelModules = [ "nvidia" ];
|
boot.kernelModules = [ "nvidia" ];
|
||||||
boot.kernelParams = ["nvidia-drm.modset=1"];
|
boot.kernelParams = [ "nvidia-drm.modset=1" ];
|
||||||
boot.blacklistedKernelModules = ["nouveau"];
|
boot.blacklistedKernelModules = [ "nouveau" ];
|
||||||
boot.kernelPackages = pkgs.linuxPackages_6_12;
|
|
||||||
hardware = {
|
hardware = {
|
||||||
graphics = {
|
graphics = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|
@ -29,6 +28,7 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
services = {
|
services = {
|
||||||
|
services.xserver.enable = true;
|
||||||
desktopManager.gnome.enable = true;
|
desktopManager.gnome.enable = true;
|
||||||
displayManager = {
|
displayManager = {
|
||||||
gdm.enable = true;
|
gdm.enable = true;
|
||||||
|
|
|
||||||
|
|
@ -7,24 +7,23 @@ in
|
||||||
|
|
||||||
isNormalUser = true;
|
isNormalUser = true;
|
||||||
initialPassword = "changeme";
|
initialPassword = "changeme";
|
||||||
extraGroups =
|
extraGroups = [
|
||||||
[
|
|
||||||
"fuse"
|
"fuse"
|
||||||
"networkmanager"
|
"networkmanager"
|
||||||
"wheel"
|
|
||||||
"scard"
|
"scard"
|
||||||
|
"wheel"
|
||||||
]
|
]
|
||||||
++ ifTheyExist [
|
++ ifTheyExist [
|
||||||
"wireshark"
|
|
||||||
"i2c"
|
|
||||||
"docker"
|
"docker"
|
||||||
"git"
|
"git"
|
||||||
"libvirtd"
|
"i2c"
|
||||||
"libvirt"
|
|
||||||
"video"
|
|
||||||
"kvm"
|
"kvm"
|
||||||
"scanner"
|
"libvirt"
|
||||||
|
"libvirtd"
|
||||||
"photos"
|
"photos"
|
||||||
|
"scanner"
|
||||||
|
"video"
|
||||||
|
"wireshark"
|
||||||
];
|
];
|
||||||
openssh.authorizedKeys.keyFiles = [
|
openssh.authorizedKeys.keyFiles = [
|
||||||
(builtins.fetchurl {
|
(builtins.fetchurl {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue