From e72a8a05868f4e9d8adb5974a6216d7271380ebd Mon Sep 17 00:00:00 2001 From: Mohammad Rafiq Date: Mon, 14 Jul 2025 15:22:45 +0800 Subject: [PATCH] feat(darwin): add brew to path --- nix/homes/rafiq/desktop/darwin.nix | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/nix/homes/rafiq/desktop/darwin.nix b/nix/homes/rafiq/desktop/darwin.nix index 21a14f4..d86ea87 100644 --- a/nix/homes/rafiq/desktop/darwin.nix +++ b/nix/homes/rafiq/desktop/darwin.nix @@ -16,4 +16,17 @@ in "slack" ]; }; + flake.modules.homeManager.rafiq = { + # make sure brew is on the path for M1 + programs.zsh.initContent = '' + if [[ $(uname -m) == 'arm64' ]]; then + eval "$(/opt/homebrew/bin/brew shellenv)" + fi + ''; + programs.fish.shellInit = '' + if test (uname -m) = "arm64" + eval (/opt/homebrew/bin/brew shellenv) + end + ''; + }; }