Skip to content

zsh: Move $PATH update export to zshrc#8

Merged
Unique-Divine merged 1 commit into
mainfrom
ud/zsh
Jun 27, 2026
Merged

zsh: Move $PATH update export to zshrc#8
Unique-Divine merged 1 commit into
mainfrom
ud/zsh

Conversation

@Unique-Divine

@Unique-Divine Unique-Divine commented Jun 27, 2026

Copy link
Copy Markdown
Owner

Problem

export PATH="$PATH:/home/realu/.foundry/bin" in zshenv was re-appending Foundry on every source. main_bash_setup sources zshenv and runs twice during normal zshrc startup (lines 9 and 321), so each new shell accumulated duplicate Foundry entries. Running myrc stacked more copies.

Fix

  • Removed the Foundry PATH line from zshenv
  • Added it to zshrc next to the other toolchain PATH exports (after linuxbrew)

zshrc runs once per shell, so Foundry is added exactly once. Re-sourcing zshenv via main_bash_setup or myrc no longer duplicates the entry.


Note

Low Risk
Shell startup PATH ordering only; no auth, data, or application logic changes.

Overview
Fixes duplicate Foundry entries in PATH by moving export PATH="$PATH:$HOME/.foundry/bin" out of zshenv and into zshrc beside the linuxbrew toolchain line.

main_bash_setup re-sources zshenv during normal startup (early and again near the end of zshrc) and when reloading config via myrc, so a PATH append in zshenv ran multiple times per shell. zshrc is evaluated once per interactive shell, so Foundry is prepended exactly once.

Reviewed by Cursor Bugbot for commit 76d6e9f. Configure here.

@Unique-Divine
Unique-Divine merged commit 4cc00be into main Jun 27, 2026
2 checks passed
@Unique-Divine
Unique-Divine deleted the ud/zsh branch June 27, 2026 23:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant