nixos/hosts/little-lightning/configuration.nix

71 lines
1.9 KiB
Nix
Raw Normal View History

2024-11-09 06:20:22 +00:00
{ pkgs, lib, self, ... }: {
2024-11-05 08:55:25 +00:00
# List packages installed in system profile. To search by name, run:
# $ nix-env -qaP | grep wget
environment.systemPackages = [ ];
nix.settings = {
experimental-features = [ "nix-command" "flakes" ];
auto-optimise-store = true;
};
# Auto upgrade nix package and the daemon service.
services.nix-daemon.enable = true;
# Enable alternative shell support in nix-darwin.
# programs.fish.enable = true;
2024-11-09 06:20:22 +00:00
services.yabai =
let
gap = 10;
gapListParts = builtins.map
(x: lib.attrsets.nameValuePair (x + "_padding") gap)
[ "top" "bottom" "left" "right" ];
gapSettings = (builtins.listToAttrs gapListParts) // { window_gap = gap; };
in
{
enable = true;
enableScriptingAddition = true;
config = {
layout = "bsp";
window_shadow = "float";
mouse_modifier = "fn";
mouse_action1 = "move";
mouse_action2 = "resize";
focus_follows_mouse = "autoraise";
mouse_follows_focus = "off";
window_topmost = "off";
} // gapSettings;
extraConfig = ''
yabai -m rule --add app="^System Settings$" manage=off
yabai -m rule --add app="Python" manage=off
yabai -m rule --add app="macroquad_playground" manage=off
yabai -m rule --add app="^coreautha$" manage=off
'';
};
2024-11-09 07:10:21 +00:00
home-manager.sharedModules = [
{
home.file.".config/yabai/yabaiExe".source = lib.getExe pkgs.yabai;
home.packages = with pkgs; [ yabai ];
}
];
2024-11-05 08:55:25 +00:00
users.users.zynh = {
name = "zynh";
home = "/Users/zynh";
};
home-manager = {
users = { "zynh" = import ./home.nix; };
backupFileExtension = "backup";
};
# Set Git commit hash for darwin-version.
system.configurationRevision = self.rev or self.dirtyRev or null;
# $ darwin-rebuild changelog
system.stateVersion = 5;
}