refactor(darwin): install GUI apps via homebrew

This commit is contained in:
2026-03-23 09:25:05 +00:00
parent 4adc8329a1
commit 4defd577d3
3 changed files with 20 additions and 10 deletions

View File

@@ -3,15 +3,12 @@
lib,
pkgs,
...
}: {
home.packages = with pkgs;
lib.optionals stdenv.isDarwin [
_1password-gui
raycast
];
}: let
aerospaceApp = "/Applications/AeroSpace.app/Contents/MacOS/AeroSpace";
in {
programs.aerospace = {
enable = true;
package = pkgs.emptyDirectory;
launchd.enable = true;
settings = {
start-at-login = true;
@@ -150,5 +147,15 @@
};
};
};
home.file.".aerospace.toml".onChange =
lib.mkForce ''
if [ -x "${aerospaceApp}" ]; then
echo "AeroSpace config changed, reloading..."
"${aerospaceApp}" reload-config || true
fi
'';
launchd.agents.aerospace.config.Program = lib.mkForce aerospaceApp;
};
}