Skip to content

Install script should put rust path in ~/.zprofile on macOS #4772

@JonasEngstrom

Description

@JonasEngstrom

Verification

Problem

Running the installation script from the rust-lang.org install page on macOS adds . "$HOME/.cargo/env" to ~/.profile rather than ~/.zprofile where it needs to be to work.

Steps

  1. Run curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
  2. Restart Terminal, without manually sourcing the ~/.profile file.
  3. Rust will not run until ~/.profile is manually sourced or . "$HOME/.cargo/env" is moved to ~/.zprofile.

Possible Solution(s)

Have the setup script add . "$HOME/.cargo/env" to ~/.zprofile instead of ~/.profile on macOS specifically.

Notes

No response

Rustup version

rustup 1.29.0 (28d1352db 2026-03-05)

Installed toolchains

stable-aarch64-apple-darwin

OS version

macOS Tahoe version 26.3.1 (a)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions