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

Update the out-of-date opam warning after the release of opam 2.2.1 #26393

Merged
merged 2 commits into from
Aug 27, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions repo
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ upstream: "https://github.com/ocaml/opam-repository/tree/master/"
announce: [
"""
[WARNING] opam is out-of-date. Please consider updating it (https://opam.ocaml.org/doc/Install.html)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Apropos this Discuss thread, I think it would be sensible to include the “offending” opam version in the message:

Suggested change
[WARNING] opam is out-of-date. Please consider updating it (https://opam.ocaml.org/doc/Install.html)
[WARNING] opam %{opam-version}% is out-of-date. Please consider updating it (https://opam.ocaml.org/doc/Install.html)

""" {(opam-version >= "2.1.0~~" & opam-version < "2.1.6") | opam-version < "2.0.10" | (opam-version >= "2.2.0~~" & opam-version < "2.2.0")}
""" {(opam-version >= "2.1.0~~" & opam-version < "2.1.6") | opam-version < "2.0.10" | (opam-version >= "2.2.0~~" & opam-version < "2.2.1")}
"""
[INFO] opam 2.1 and 2.2 include many performance improvements over 2.0; please consider upgrading (https://opam.ocaml.org/doc/Install.html)
[INFO] opam 2.1 and 2.2 include many performance and security improvements over 2.0; please consider upgrading (https://opam.ocaml.org/doc/Install.html)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
[INFO] opam 2.1 and 2.2 include many performance and security improvements over 2.0; please consider upgrading (https://opam.ocaml.org/doc/Install.html)
[INFO] opam 2.1 and 2.2 include many performance and security improvements over %{opam-version}%; please consider upgrading (https://opam.ocaml.org/doc/Install.html)

(similarly; I double-checked that opam 2.0.0 expands variables in post-messages!)

""" {opam-version >= "2.0.10" & opam-version < "2.1.0~~"}
"""
[WARNING] please ensure to have GNU patch installed as `patch`. Otherwise update may fail silently (since it can't remove files).
Expand Down