diff --git a/src/action/common/configure_shell_profile.rs b/src/action/common/configure_shell_profile.rs index f552b0d..d99c605 100644 --- a/src/action/common/configure_shell_profile.rs +++ b/src/action/common/configure_shell_profile.rs @@ -154,7 +154,11 @@ impl ConfigureShellProfile { let mut buf = "/nix/var/nix/profiles/default/bin\n".to_string(); // Actions runners operate as `runner` user by default if let Ok(Some(runner)) = User::from_name("runner") { - buf += &format!("/home/{}/.nix-profile/bin\n", runner.name); + #[cfg(target_os = "linux")] + let path = format!("/home/{}/.nix-profile/bin\n", runner.name); + #[cfg(target_os = "macos")] + let path = format!("/Users/{}/.nix-profile/bin\n", runner.name); + buf += &path; } create_or_insert_files.push( CreateOrInsertIntoFile::plan(