Some more nix configuration

This commit is contained in:
Tobias Ostner 2023-09-18 20:06:13 +02:00
parent b2157e5f99
commit 662d1f3c0d
3 changed files with 108 additions and 96 deletions

View file

@ -0,0 +1,72 @@
({ pkgs, ... }: {
programs.zsh.enable = true;
environment.shells = [ pkgs.bash pkgs.zsh pkgs.fish ];
environment.loginShell = pkgs.zsh;
environment.systemPath = [ "/opt/homebrew/bin" ];
fonts.fonts = [
(pkgs.nerdfonts.override {
fonts = [
"FiraCode"
"Iosevka"
"IosevkaTerm"
"JetBrainsMono"
"SourceCodePro"
];
})
];
nix.extraOptions = ''
experimental-features = nix-command flakes
'';
services.nix-daemon.enable = true;
services.yabai = {
enable = true;
package = pkgs.yabai;
enableScriptingAddition = true;
config = {
layout = "bsp";
window_placement = "second_child";
top_padding = 8;
bottom_padding = 8;
left_padding = 8;
right_padding = 8;
window_gap = 8;
mouse_follows_focus = "on";
mouse_modifier = "alt";
mouse_action1 = "move";
mouse_action2 = "resize";
mouse_drop_action = "swap";
};
extraConfig = ''
yabai -m rule --add app="^System Settings$" manage=off
'';
};
services.skhd = {
enable = true;
skhdConfig = ''
alt - h : yabai -m window --focus west
alt - l : yabai -m window --focus east
alt - j : yabai -m window --focus south
alt - k : yabai -m window --focus north
alt - p : yabei -m display --focus west
alt - n : yabei -m display --focus east
alt - y : yabai -m space --mirror x-axis
alt - m : yabai -m window --toggle zoom-fullscreen
'';
};
system.defaults.dock.autohide = true;
system.defaults.dock.mru-spaces = false;
system.defaults.dock.orientation = "right";
system.defaults.NSGlobalDomain.InitialKeyRepeat = 14;
system.defaults.NSGlobalDomain.KeyRepeat = 1;
system.defaults.finder.AppleShowAllExtensions = true;
system.defaults.finder.AppleShowAllFiles = true;
system.defaults.finder.CreateDesktop = false;
users.users.tobi.home = "/Users/tobi";
homebrew = {
enable = true;
brews = [
"imagemagick"
"trippy"
];
};
})