Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

arg: fix loading git location from config file at init #5842

Merged
merged 1 commit into from
Feb 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
1 change: 1 addition & 0 deletions master_changes.md
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,7 @@ users)

## Internal: Windows
* Ensure that the system critical error dialog is disabled when opam starts [#5828 @dra27]
* Fix loading git location at init [#5843 @rjbou]

## Test

Expand Down
6 changes: 3 additions & 3 deletions src/client/opamArg.ml
Original file line number Diff line number Diff line change
Expand Up @@ -597,12 +597,12 @@ let apply_global_options cli o =
{ pelem = String cygcheck; _}::_ ->
let cygbin = Filename.dirname cygcheck in
OpamCoreConfig.update ~cygbin ()
| Some { pelem = String "git-location"; _},
{ pelem = String git_location; _}::_ ->
OpamCoreConfig.update ~git_location ()
| _, element::elements -> aux (Some element) elements
in
aux None elements
| { pelem = Variable ({ pelem = "git-location"; _},
{pelem = String git_location; _}); _} ->
OpamCoreConfig.update ~git_location ()
| _ -> ())
opamfile.file_contents
with
Expand Down