Skip to content

Commit

Permalink
Merge pull request #6299 from acasta-yhliu/master
Browse files Browse the repository at this point in the history
Fix the detection of ZDOTDIR when using zsh
  • Loading branch information
kit-ty-kate authored Nov 15, 2024
2 parents a19d003 + 27c7639 commit e687af0
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
1 change: 1 addition & 0 deletions master_changes.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ users)
## Plugins

## Init
* [BUG] Fix the detection of `ZDOTDIR` when using `zsh` [#6299 @acasta-yhliu - fix #6281]

## Config report

Expand Down
6 changes: 5 additions & 1 deletion src/core/opamStd.ml
Original file line number Diff line number Diff line change
Expand Up @@ -1162,7 +1162,11 @@ module OpamSys = struct
match shell with
| SH_fish ->
Some (List.fold_left Filename.concat (home ".config") ["fish"; "config.fish"])
| SH_zsh -> Some (home ".zshrc")
| SH_zsh ->
let zsh_home f =
try Filename.concat (Env.get "ZDOTDIR") f
with Not_found -> home f in
Some (zsh_home ".zshrc")
| SH_bash ->
let shell =
(try
Expand Down

0 comments on commit e687af0

Please sign in to comment.