[feat] Add some stuff for nix

This commit is contained in:
Uttarayan Mondal
2024-02-15 06:46:02 +05:30
parent 6a009ef91c
commit 5ca9d2165c
9 changed files with 498 additions and 359 deletions

View File

@@ -1,11 +1,9 @@
.PHONY: run build genzai .PHONY: darwin build default
default: build default: build
darwin:
nix run nix-darwin -- switch --flake ~/.local/share/dotfiles/config/nix
switch: home:
nix run home-manager/master -- switch --flake ~/.local/share/dotfiles/config/nix nix run home-manager/master -- switch --flake ~/.local/share/dotfiles/config/nix
build:
nix run home-manager/master -- build --flake ~/.local/share/dotfiles/config/nix
genzai:
nix build .#homeConfigurations.genzai

View File

@@ -1,10 +1,38 @@
{pkgs, ...}: { {
pkgs,
device,
...
}: {
imports = [
./yabai.nix
./skhd.nix
];
environment.systemPackages = with pkgs; [
nix
neovim
];
nix = { nix = {
settings = { settings = {
experimental-features = "nix-command flakes repl-flake"; experimental-features = "nix-command flakes repl-flake";
max-jobs = 8; max-jobs = 8;
trusted-users = ["root" "fs0c131y"];
}; };
extraOptions = ''
build-users-group = nixbld
extra-nix-path = nixpkgs=flake:nixpkgs
'';
package = pkgs.nix;
}; };
programs.bash.enable = true;
programs.zsh.enable = true;
programs.fish.enable = true;
nixpkgs.hostPlatform = device.system;
services.nix-daemon.enable = true;
system.stateVersion = 4;
system.keyboard.enableKeyMapping = true; system.keyboard.enableKeyMapping = true;
system.keyboard.remapCapsLockToControl = true; system.keyboard.remapCapsLockToControl = true;
system.keyboard.swapLeftCommandAndLeftAlt = true; system.keyboard.swapLeftCommandAndLeftAlt = true;

View File

@@ -16,118 +16,89 @@
flake-utils.url = "github:numtide/flake-utils"; flake-utils.url = "github:numtide/flake-utils";
}; };
outputs = { outputs =
nixpkgs, { nixpkgs
home-manager, , home-manager
nix-darwin, , nix-darwin
flake-utils, , flake-utils
... , ...
} @ inputs: let } @ inputs:
devices = [ let
{ devices = [
name = "mirai"; {
system = "x86_64-linux"; name = "mirai";
user = "fs0c131y"; system = "x86_64-linux";
} user = "fs0c131y";
{ }
name = "genzai"; {
system = "x86_64-linux"; name = "genzai";
user = "fs0c131y"; system = "x86_64-linux";
} user = "fs0c131y";
{ }
name = "Uttarayans-MacBook-Pro"; {
system = "aarch64-darwin"; name = "Uttarayans-MacBook-Pro";
user = "fs0c131y"; system = "aarch64-darwin";
} user = "fs0c131y";
{ }
name = "SteamDeck"; {
system = "x86_64-linux"; name = "SteamDeck";
user = "deck"; system = "x86_64-linux";
} user = "deck";
]; }
linux = builtins.filter (x: x.system == "x86_64-linux") devices; ];
darwin = builtins.filter (x: x.system == "aarch64-darwin") devices; linux = builtins.filter (x: x.system == "x86_64-linux") devices;
in { darwin = builtins.filter (x: x.system == "aarch64-darwin") devices;
homeConfigurations = builtins.listToAttrs (builtins.map (device: { in
name = device.user; {
value = let homeConfigurations = builtins.listToAttrs (builtins.map
pkgs = nixpkgs.legacyPackages.${device.system}; (device: {
overlays = [inputs.neovim-nightly-overlay.overlay]; name = device.user;
in value =
home-manager.lib.homeManagerConfiguration { let
inherit pkgs; pkgs = nixpkgs.legacyPackages.${device.system};
modules = [ overlays = [ inputs.neovim-nightly-overlay.overlay ];
./home.nix in
{ home-manager.lib.homeManagerConfiguration {
nixpkgs.overlays = overlays; inherit pkgs;
} modules = [
]; ./home.nix
}; {
}) nixpkgs.overlays = overlays;
linux); }
];
};
})
linux);
darwinConfigurations = builtins.listToAttrs (builtins.map (device: { darwinConfigurations =
name = device.name; builtins.listToAttrs
value = let (builtins.map
pkgs = nixpkgs.legacyPackages.${device.system}; (device: {
in { name = device.name;
"Uttarayans-MacBook-Pro" = nix-darwin.lib.darwinSystem { value =
modules = [ let
home-manager.darwinModules.home-manager pkgs = nixpkgs.legacyPackages.${device.system};
./darwin.nix overlays = [ inputs.neovim-nightly-overlay.overlay ];
({config, ...}: { in
home-manager = { nix-darwin.lib.darwinSystem {
users = { inherit pkgs;
fs0c131y = { modules = [
home = "/Users/${device.user}"; ./darwin.nix
stateVersion = "21.05"; home-manager.darwinModules.home-manager
configuration = home-manager.configurations.fs0c131y; {
}; home-manager = {
}; useGlobalPkgs = true;
useUserPackages = true;
extraSpecialArgs = {
inherit device;
inherit overlays;
};
users.${device.user}.imports = [ ./home.nix ];
};
}
];
}; };
}) })
]; darwin);
}; };
};
})
darwin);
};
} }
# "fs0c131y" = let
# system = "x86_64-linux";
# overlays = [inputs.neovim-nightly-overlay.overlay];
# pkgs = nixpkgs.legacyPackages.${system};
# in
# home-manager.lib.homeManagerConfiguration
# {
# inherit pkgs;
# modules = [
# ./home.nix
# {
# nixpkgs.overlays = overlays;
# }
# ];
# };
# darwinConfigurations = let
# system = "aarch64-darwin";
# pkgs = nixpkgs.legacyPackages.${system};
# in {
# "Uttarayans-MacBook-Pro" = darwin.lib.darwinSystem {
# modules = [
# home-manager.darwinModules.home-manager
# ./darwin.nix
# ({config, ...}: {
# home-manager = {
# users = {
# fs0c131y = {
# home = "/Users/fs0c131y";
# stateVersion = "21.05";
# configuration = home-manager.configurations.fs0c131y;
# };
# };
# };
# })
# ];
# };
# };

View File

@@ -1,179 +1,193 @@
{ { config
config, , pkgs
pkgs, , lib
... , device
}: let , overlays
, ...
}:
let
start-tmux = (import ./scripts/start-tmux.nix) pkgs; start-tmux = (import ./scripts/start-tmux.nix) pkgs;
in in
# https://mipmip.github.io/home-manager-option-search/ # https://mipmip.github.io/home-manager-option-search/
{ {
imports = [ nixpkgs.overlays = [
# Include the results of the hardware scan. (self: super: {
./tmux.nix neovim-nightly = overlays.neovim-nightly;
./wezterm.nix })
./hyprland.nix ];
imports = [
# Include the results of the hardware scan.
./tmux.nix
./wezterm.nix
./hyprland.nix
];
programs = {
fish = {
enable = true;
shellAbbrs = {
vim = "nvim";
vi = "nvim";
nv = "nvim";
g = "git";
cd = "z";
ls = "exa";
t = "${start-tmux}";
};
interactiveShellInit = ''
set fish_greeting
${pkgs.macchina.outPath}/bin/macchina
'';
};
nushell = {
enable = true;
shellAliases = {
"cd" = "z";
};
package = pkgs.nushellFull;
configFile.text = ''
$env.config = {
show_banner: false,
}
'';
};
zoxide = {
enable = true;
enableFishIntegration = true;
enableNushellIntegration = true;
};
starship = {
enable = true;
enableFishIntegration = true;
enableNushellIntegration = true;
};
eza = {
enable = true;
enableAliases = true;
git = true;
icons = true;
};
carapace = {
enable = true;
enableFishIntegration = true;
enableNushellIntegration = true;
};
fzf = {
enable = true;
package = pkgs.fzf;
enableFishIntegration = true;
tmux.enableShellIntegration = true;
};
keychain = {
enable = true;
# keys = [ "id_ed25519" ];
enableFishIntegration = true;
enableNushellIntegration = true;
};
yazi = {
enable = true;
enableFishIntegration = true;
enableNushellIntegration = true;
};
foot = {
enable = pkgs.stdenv.isLinux;
server.enable = true;
settings = {
main = {
shell = "${pkgs.fish.outPath}/bin/fish";
font = "Hasklug Nerd Font Mono:size=13";
initial-window-size-pixels = "1440x800";
};
colors = {
foreground = "f8f8f2";
background = 000000;
alpha = 0.8;
"136" = "af8700";
regular0 = "21222c";
regular1 = "ff5555";
regular2 = "50fa7b";
regular3 = "f1fa8c";
regular4 = "bd93f9";
regular5 = "ff79c6";
regular6 = "8be9fd";
regular7 = "f8f8f2";
bright0 = "6272a4";
bright1 = "ff6e6e";
bright2 = "69ff94";
bright3 = "ffffa5";
bright4 = "d6acff";
bright5 = "ff92df";
bright6 = "a4ffff";
bright7 = "ffffff";
};
};
};
# Let Home Manager install and manage itself.
home-manager = {
enable = true;
};
};
home = {
# Home Manager needs a bit of information about you and the paths it should
# manage.
username = device.user;
homeDirectory =
if device.system == "x86-64-linux" then
lib.mkForce "/home/${device.user}"
else
lib.mkForce "/Users/${device.user}";
stateVersion = "23.11";
packages = [
pkgs.macchina
pkgs.alejandra
# pkgs.neovim-nightly
pkgs.cachix
# # Adds the 'hello' command to your environment. It prints a friendly
# # "Hello, world!" when run.
# pkgs.hello
# # It is sometimes useful to fine-tune packages, for example, by applying
# # overrides. You can do that directly here, just don't forget the
# # parentheses. Maybe you want to install Nerd Fonts with a limited number of
# # fonts?
# (pkgs.nerdfonts.override { fonts = [ "FantasqueSansMono" ]; })
# # You can also create simple shell scripts directly inside your
# # configuration. For example, this adds a command 'my-hello' to your
# # environment:
# (pkgs.writeShellScriptBin "my-hello" ''
# echo "Hello, ${config.home.username}!"
# '')
]; ];
programs = { file = {
fish = { ".config/tmux/sessions".source = ../tmux/sessions;
enable = true; ".config/nvim".source = ../nvim;
shellAbbrs = {
vim = "nvim";
vi = "nvim";
nv = "nvim";
g = "git";
cd = "z";
ls = "exa";
t = "${start-tmux}";
};
interactiveShellInit = ''
set fish_greeting
${pkgs.macchina.outPath}/bin/macchina
'';
};
nushell = { # # You can also set the file content immediately.
enable = true; # ".gradle/gradle.properties".text = ''
shellAliases = { # org.gradle.console=verbose
"cd" = "z"; # org.gradle.daemon.idletimeout=3600000
}; # '';
package = pkgs.nushellFull;
configFile.text = ''
$env.config = {
show_banner: false,
}
'';
};
zoxide = {
enable = true;
enableFishIntegration = true;
enableNushellIntegration = true;
};
starship = {
enable = true;
enableFishIntegration = true;
enableNushellIntegration = true;
};
eza = {
enable = true;
enableAliases = true;
git = true;
icons = true;
};
carapace = {
enable = true;
enableFishIntegration = true;
enableNushellIntegration = true;
};
fzf = {
enable = true;
package = pkgs.fzf;
enableFishIntegration = true;
tmux.enableShellIntegration = true;
};
keychain = {
enable = true;
keys = ["id_ed25519"];
enableFishIntegration = true;
enableNushellIntegration = true;
};
yazi = {
enable = true;
enableFishIntegration = true;
enableNushellIntegration = true;
};
foot = {
enable = pkgs.stdenv.isLinux;
server.enable = true;
settings = {
main = {
shell = "${pkgs.fish.outPath}/bin/fish";
font = "Hasklug Nerd Font Mono:size=13";
initial-window-size-pixels = "1440x800";
};
colors = {
foreground = "f8f8f2";
background = 000000;
alpha = 0.8;
"136" = "af8700";
regular0 = "21222c";
regular1 = "ff5555";
regular2 = "50fa7b";
regular3 = "f1fa8c";
regular4 = "bd93f9";
regular5 = "ff79c6";
regular6 = "8be9fd";
regular7 = "f8f8f2";
bright0 = "6272a4";
bright1 = "ff6e6e";
bright2 = "69ff94";
bright3 = "ffffa5";
bright4 = "d6acff";
bright5 = "ff92df";
bright6 = "a4ffff";
bright7 = "ffffff";
};
};
};
# Let Home Manager install and manage itself.
home-manager = {
enable = true;
};
}; };
home = { sessionVariables = {
# Home Manager needs a bit of information about you and the paths it should EDITOR = "nvim";
# manage. SHELL = "${pkgs.fish.outPath}/bin/fish";
username = "fs0c131y";
homeDirectory = "/home/fs0c131y";
stateVersion = "23.11";
packages = [
pkgs.macchina
pkgs.alejandra
pkgs.neovim-nightly
pkgs.cachix
# # Adds the 'hello' command to your environment. It prints a friendly
# # "Hello, world!" when run.
# pkgs.hello
# # It is sometimes useful to fine-tune packages, for example, by applying
# # overrides. You can do that directly here, just don't forget the
# # parentheses. Maybe you want to install Nerd Fonts with a limited number of
# # fonts?
# (pkgs.nerdfonts.override { fonts = [ "FantasqueSansMono" ]; })
# # You can also create simple shell scripts directly inside your
# # configuration. For example, this adds a command 'my-hello' to your
# # environment:
# (pkgs.writeShellScriptBin "my-hello" ''
# echo "Hello, ${config.home.username}!"
# '')
];
file = {
".config/tmux/sessions".source = ../tmux/sessions;
".config/nvim".source = ../nvim;
# # You can also set the file content immediately.
# ".gradle/gradle.properties".text = ''
# org.gradle.console=verbose
# org.gradle.daemon.idletimeout=3600000
# '';
};
sessionVariables = {
EDITOR = "nvim";
SHELL = "${pkgs.fish.outPath}/bin/fish";
};
sessionPath = [
"${config.home.homeDirectory}/.local/bin"
"${config.home.homeDirectory}/.nix-profile/bin"
];
}; };
} sessionPath = [
"${config.home.homeDirectory}/.local/bin"
"${config.home.homeDirectory}/.nix-profile/bin"
];
};
}

View File

@@ -1,2 +1,9 @@
substituters = https://cache.nixos.org https://nix-community.cachix.org # Generated by https://github.com/DeterminateSystems/nix-installer.
trusted-public-keys = cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY= nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs= # See `/nix/nix-installer --version` for the version details.
build-users-group = nixbld
experimental-features = nix-command flakes repl-flake
bash-prompt-prefix = (nix:$name)\040
max-jobs = auto
extra-nix-path = nixpkgs=flake:nixpkgs
upgrade-nix-store-path-url = https://install.determinate.systems/nix-upgrade/stable/universal

View File

@@ -1,48 +1,49 @@
{ { pkgs
pkgs, , ...
...
}: }:
pkgs.writeShellScript "start-tmux" '' pkgs.writeShellScript "start-tmux" ''
live_sessions=$(${pkgs.tmux}/bin/tmux list-sessions 2>/dev/null) live_sessions=$(${pkgs.tmux}/bin/tmux list-sessions 2>/dev/null)
all_sessions=$(${pkgs.findutils}/bin/find -L ~/.config/tmux/sessions -type f -executable -printf '%f\n'| sort) all_sessions=$(${pkgs.findutils}/bin/find -L ~/.config/tmux/sessions -type f -executable -printf '%f\n'| sort)
TMUX_SESSIONS="$HOME/.config/tmux/sessions" TMUX_SESSIONS="$HOME/.config/tmux/sessions"
# for some reason ~/.config/tmux/session doesn't work if made with quotes # for some reason ~/.config/tmux/session doesn't work if made with quotes
# TMUX_SESSIONS=$XDG_CONFIG_HOME/tmux/sessions # TMUX_SESSIONS=$XDG_CONFIG_HOME/tmux/sessions
if ! [ -z "$TMUX" ];then if ! [ -z "$TMUX" ];then
echo "Nested tmux sessions are a bad idea?" echo "Nested tmux sessions are a bad idea?"
echo "If you want to really do this unset TMUX environment variable" echo "If you want to really do this unset TMUX environment variable"
exit 1 exit 1
fi fi
IFS=$'\n' IFS=$'\n'
for live_session in $live_sessions;do for live_session in $live_sessions;
live_session_name=$(echo $live_session | ${pkgs.coreutils}/bin/cut -d: -f1) do
if [ -z "''\${all_sessions##*$live_session_name*}" ];then # see https://stackoverflow.com/questions/229551/how-to-check-if-a-string-contains-a-substring-in-bash live_session_name=$(echo $live_session | ${pkgs.coreutils}/bin/cut -d: -f1)
all_sessions="$(echo "$all_sessions" | sed "s/$live_session_name/$live_session/g")" if [ -z "''\${all_sessions##*$live_session_name*}" ];then # see https://stackoverflow.com/questions/229551/how-to-check-if-a-string-contains-a-substring-in-bash
else all_sessions="$(echo "$all_sessions" | sed "s/$live_session_name/$live_session/g")"
all_sessions=$(echo -e "$all_sessions\n$live_session") else
# Okay I know this is ugly it is 5:13 my brain is not working all_sessions="$(echo -e "$all_sessions\n$live_session")"
fi fi
session=$(echo "''\$all_sessions" | fzf) done
session_name=$(echo $session | cut -d: -f1) session=$(echo "''\$all_sessions" | ${pkgs.fzf}/bin/fzf)
if [ -z "$session" ];then session_name=$(echo $session | cut -d: -f1)
exit 0 if [ -z "$session" ];then
fi exit 0
if ! [ -z "''\${session##*created*}" ];then fi
if [ -x "$TMUX_SESSIONS/$session_name" ];then if ! [ -z "''\${session##*created*}" ];then
source $TMUX_SESSIONS/$session_name if [ -x "$TMUX_SESSIONS/$session_name" ];then
else source $TMUX_SESSIONS/$session_name
echo $TMUX_SESSIONS/$session_name not found or is not executable else
exit 1 echo $TMUX_SESSIONS/$session_name not found or is not executable
fi exit 1
fi fi
if [ -z "''\${session##*attached*}" ];then fi
read -r -p "The session is already attached somewhere else. Attach it here too ? (y/N): " choice if [ -z "''\${session##*attached*}" ];then
if [ "$choice" == "y" ] || [ "$choice" == "Y" ];then read -r -p "The session is already attached somewhere else. Attach it here too ? (y/N): " choice
tmux attach-session -t$session_name if [ "$choice" == "y" ] || [ "$choice" == "Y" ];then
fi ${pkgs.tmux}/bin/tmux attach-session -t$session_name
else fi
tmux attach-session -t$session_name else
fi ${pkgs.tmux}/bin/tmux attach-session -t$session_name
done fi
'' ''

77
config/nix/skhd.nix Normal file
View File

@@ -0,0 +1,77 @@
{...}: {
services = {
skhd = {
enable = true;
skhdConfig = ''
# open terminal, blazingly fast compared to iTerm/Hyper
# alt - return : /Applications/kitty.app/Contents/MacOS/kitty --single-instance -d ~
alt - return : /Applications/WezTerm.app/Contents/MacOS/wezterm
shift + alt - return: pkill mpv
# alt + \ : pkill mpv
# open qutebrowser
# alt + shift - return : ~/Scripts/qtb.sh
# open mpv
alt - m : open -na /Applications/mpv.app $(pbpaste)
# close focused window
# alt - w : yabai -m window --close
alt - d : open -na "$(ls /Applications /System/Applications/ /System/Applications/Utilities/ | choose)"
# focus window
alt - h : yabai -m window --focus west
alt - j : yabai -m window --focus south
alt - k : yabai -m window --focus north
alt - l : yabai -m window --focus east
# alt - j : yabai -m window --focus prev
# alt - k : yabai -m window --focus next
# Float
shift + alt - f: yabai -m window --toggle float
alt - f: yabai -m window --toggle native-fullscreen
# swap window
# shift + alt - h : yabai -m window --swap west
# shift + alt - j : yabai -m window --swap south
# shift + alt - k : yabai -m window --swap north
# shift + alt - l : yabai -m window --swap east
# move window
shift + alt - h : yabai -m window --warp west
shift + alt - j : yabai -m window --warp south
shift + alt - k : yabai -m window --warp north
shift + alt - l : yabai -m window --warp east
# restart skhd
shift + alt - r : pkill skhd
# fast focus desktop
alt - 1 : yabai -m space --focus 1
alt - 2 : yabai -m space --focus 2
alt - 3 : yabai -m space --focus 3
alt - 4 : yabai -m space --focus 4
alt - 5 : yabai -m space --focus 5
alt - 6 : yabai -m space --focus 6
alt - 7 : yabai -m space --focus 7
alt - 8 : yabai -m space --focus 8
alt - 9 : yabai -m space --focus 9
alt - 0 : yabai -m space --focus 10
# Move window to desktop
shift + alt - 1 : yabai -m window --space 1
shift + alt - 2 : yabai -m window --space 2
shift + alt - 3 : yabai -m window --space 3
shift + alt - 4 : yabai -m window --space 4
shift + alt - 5 : yabai -m window --space 5
shift + alt - 6 : yabai -m window --space 6
shift + alt - 7 : yabai -m window --space 7
shift + alt - 8 : yabai -m window --space 8
shift + alt - 9 : yabai -m window --space 9
shift + alt - 0 : yabai -m window --space 10
'';
};
};
}

View File

@@ -1,26 +1,28 @@
{pkgs, ...}: let { pkgs, ... }:
let
tmux-super-fingers = tmux-super-fingers =
pkgs.tmuxPlugins.mkTmuxPlugin pkgs.tmuxPlugins.mkTmuxPlugin
{ {
pluginName = "tmux-super-fingers"; pluginName = "tmux-super-fingers";
version = "v1-2024-02-14"; version = "v1-2024-02-14";
src = pkgs.fetchFromGitHub { src = pkgs.fetchFromGitHub {
owner = "artemave"; owner = "artemave";
repo = "tmux_super_fingers"; repo = "tmux_super_fingers";
rev = "518044ef78efa1cf3c64f2e693fef569ae570ddd"; rev = "518044ef78efa1cf3c64f2e693fef569ae570ddd";
sha256 = "sha256-iKfx9Ytk2vSuINvQTB6Kww8Vv7i51cFEnEBHLje+IJw="; sha256 = "sha256-iKfx9Ytk2vSuINvQTB6Kww8Vv7i51cFEnEBHLje+IJw=";
};
}; };
};
scratchpad = pkgs.writeShellScript "scratchpad" '' scratchpad = pkgs.writeShellScript "scratchpad" ''
width=''\${2:-95%} width=''\${2:-95%}
height=''\${2:-95%} height=''\${2:-95%}
if [ "$(tmux display-message -p -F "#{session_name}")" = "scratch" ];then if [ "$(tmux display-message -p -F "#{session_name}")" = "scratch" ];then
tmux detach-client tmux detach-client
else else
tmux popup -d '#{pane_current_path}' -xC -yC -w$width -h$height -E "tmux attach -t scratch || tmux new -s scratch" tmux popup -d '#{pane_current_path}' -xC -yC -w$width -h$height -E "tmux attach -t scratch || tmux new -s scratch"
fi fi
''; '';
in { in
{
programs.tmux = { programs.tmux = {
enable = true; enable = true;
shell = "${pkgs.nushellFull}/bin/nu"; shell = "${pkgs.nushellFull}/bin/nu";
@@ -38,15 +40,12 @@ in {
plugin = tmuxPlugins.catppuccin; plugin = tmuxPlugins.catppuccin;
extraConfig = '' extraConfig = ''
set -g @catppuccin_flavour 'mocha' set -g @catppuccin_flavour 'mocha'
set -g @catppuccin_window_tabs_enabled on
set -g @catppuccin_status_modules_right ""
set -g @catppuccin_status_modules_right "battery application session date_time"
''; '';
} }
{ {
plugin = tmuxPlugins.battery; plugin = tmuxPlugins.battery;
extraConfig = '' extraConfig = ''
set -g @catppuccin_status_modules_right "application session user host date_time" set -g @catppuccin_status_modules_right "battery application session date_time"
''; '';
} }
]; ];

44
config/nix/yabai.nix Normal file
View File

@@ -0,0 +1,44 @@
{...}: {
services = {
yabai = {
enable = true;
enableScriptingAddition = true;
config = {
mouse_follows_focus = "on";
focus_follows_mouse = "on";
window_origin_display = "default";
window_placement = "second_child";
window_topmost = "off";
window_shadow = "on";
window_opacity = "off";
window_opacity_duration = "0.0";
active_window_opacity = "1.0";
normal_window_opacity = "0.90";
window_border = "off";
window_border_width = "6";
active_window_border_color = "0xff775759";
normal_window_border_color = "0xff555555";
insert_feedback_color = "0xffd75f5f";
split_ratio = "0.50";
auto_balance = "off";
mouse_modifier = "fn";
mouse_action1 = "move";
mouse_action2 = "resize";
mouse_drop_action = "swap";
layout = "bsp";
top_padding = "5";
bottom_padding = "5";
left_padding = "5";
right_padding = "5";
window_gap = "06";
};
extraConfig = ''
yabai -m rule --add app='System Preferences' manage=off
yabai -m rule --add app="choose" manage=off
yabai -m rule --add app="barrier" manage=off
yabai -m rule --add app="steam" manage=off
'';
};
};
}