-
Notifications
You must be signed in to change notification settings - Fork 368
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
opam var fixes #4192
opam var fixes #4192
Conversation
rjbou
commented
May 11, 2020
- No scope needed for variable display (as 2.0 opam var) fix opam var changes #4183
- Fix package variable display fix opam var package var not found #4182
- Not found message include scope
OpamConsole.error_and_exit `Not_found "Variable %s not found in %s" v | ||
(match switch with | ||
| None -> "global config" | ||
| Some switch -> "in switch " ^ (OpamSwitch.to_string switch)) | ||
|
||
let is_switch_defined_var switch_config v = |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we move this function into OpamPackageVar
?
This PR doesn't seem to fix an issue that arise for packages that uses
the configure script uses |
@kit-ty-kate are you in the case of #4188? |
That seems to be the case ( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All good!
`Ok () | ||
| `empty -> assert false (* can't happen *) | ||
| `value_eq _ -> | ||
`Error (true, "variable setting needs a scope, \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This restriction is only for opam var
affectations, should we set switch scope by default ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
After some discussions, no for variables