From f4a07d0f65bafb976fefb4196dead6615736c4b2 Mon Sep 17 00:00:00 2001 From: Martin Holters Date: Wed, 18 May 2022 10:23:14 +0200 Subject: [PATCH 1/4] Expand usage section in REAMDE to mention backports --- README.md | 20 ++++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index b26a9f7e7..8d3d20bc5 100644 --- a/README.md +++ b/README.md @@ -22,11 +22,23 @@ To use Compat in your Julia package, add it as a dependency of your package usin ```julia pkg> add Compat ``` -and add a [version specifier line](https://julialang.github.io/Pkg.jl/v1/compatibility/#Version-specifier-format-1) such as `Compat = "2.2, 3"` in the `[compat]`section of the `Project.toml` file +and add a [version specifier line](https://julialang.github.io/Pkg.jl/v1/compatibility/#Version-specifier-format-1) +such as `Compat = "3.22, 4"` in the `[compat]`section of the `Project.toml` file in your package directory. The version in the latter should be the minimum -version that supports all needed fatures (see list below), and (if applicable) -any newer major versions verified to be compatible. Then, in your package, -shortly after the `module` statement a line like this: +version that supports all needed features (see list below). Note that Compat v4 +requires Julia v1.6, but some features may have been backported to Compat v3. +So if compatibility with older Julia is important to you, also check the +[feature list of the release-3 branch](https://github.com/JuliaLang/Compat.jl/tree/release-3#supported-features). +If you require any of those backported features, be sure to specify the correct +compatibility in your `Project.toml`. E.g. if the feature from Compat v4.x has +been backported to v3.y, use `Compat = 3.y, 4.x`. If you use a feature that had +originally been added in Compat v3 (e.g. in 3.x), don't forget to also declare +compatibility with v4 with `Compat = 3.x, 4` (unless you use one the very few +things that got removed between Compat v3 and v4, which you most probably +don't). + +Then, in your package, shortly after the `module` statement include a line like +this: ```julia using Compat From c9baec2cf4110070cb69b50d567549c94165e759 Mon Sep 17 00:00:00 2001 From: Martin Holters Date: Thu, 19 May 2022 08:25:35 +0200 Subject: [PATCH 2/4] README: More explicitly recommend wide compat MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Bogumił Kamiński --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index 8d3d20bc5..fa2d1bb0c 100644 --- a/README.md +++ b/README.md @@ -37,6 +37,8 @@ compatibility with v4 with `Compat = 3.x, 4` (unless you use one the very few things that got removed between Compat v3 and v4, which you most probably don't). +To minimize dependency conflicts between packages it is recommended that packages allow for both appropriate v4 and v3 versions of Compat.jl in their Project.toml (except for rare cases of packages that support only v4 or v3 version of Compat.jl). + Then, in your package, shortly after the `module` statement include a line like this: From fe06596869c0a3977b0fc2c1d2d850145f0849a4 Mon Sep 17 00:00:00 2001 From: Martin Holters Date: Fri, 20 May 2022 14:23:56 +0200 Subject: [PATCH 3/4] Apply suggestions from code review Co-authored-by: Milan Bouchet-Valat --- README.md | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index fa2d1bb0c..2c86fab5d 100644 --- a/README.md +++ b/README.md @@ -26,9 +26,9 @@ and add a [version specifier line](https://julialang.github.io/Pkg.jl/v1/compati such as `Compat = "3.22, 4"` in the `[compat]`section of the `Project.toml` file in your package directory. The version in the latter should be the minimum version that supports all needed features (see list below). Note that Compat v4 -requires Julia v1.6, but some features may have been backported to Compat v3. -So if compatibility with older Julia is important to you, also check the -[feature list of the release-3 branch](https://github.com/JuliaLang/Compat.jl/tree/release-3#supported-features). +requires Julia v1.6, but some features may have been backported to Compat v3 +(see the [feature list of the release-3 branch] +(https://github.com/JuliaLang/Compat.jl/tree/release-3#supported-features)). If you require any of those backported features, be sure to specify the correct compatibility in your `Project.toml`. E.g. if the feature from Compat v4.x has been backported to v3.y, use `Compat = 3.y, 4.x`. If you use a feature that had @@ -37,7 +37,9 @@ compatibility with v4 with `Compat = 3.x, 4` (unless you use one the very few things that got removed between Compat v3 and v4, which you most probably don't). -To minimize dependency conflicts between packages it is recommended that packages allow for both appropriate v4 and v3 versions of Compat.jl in their Project.toml (except for rare cases of packages that support only v4 or v3 version of Compat.jl). +To minimize dependency conflicts between packages it is recommended that packages +allow for both appropriate v4 and v3 versions of Compat.jl in their Project.toml +(except for rare cases of packages that support only v4 or v3 version of Compat.jl). Then, in your package, shortly after the `module` statement include a line like this: From 25a680f6c6c399009110cb5cb997177a6331dc7e Mon Sep 17 00:00:00 2001 From: Martin Holters Date: Fri, 20 May 2022 14:25:48 +0200 Subject: [PATCH 4/4] Update README.md --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 2c86fab5d..32123eb21 100644 --- a/README.md +++ b/README.md @@ -27,8 +27,8 @@ such as `Compat = "3.22, 4"` in the `[compat]`section of the `Project.toml` file in your package directory. The version in the latter should be the minimum version that supports all needed features (see list below). Note that Compat v4 requires Julia v1.6, but some features may have been backported to Compat v3 -(see the [feature list of the release-3 branch] -(https://github.com/JuliaLang/Compat.jl/tree/release-3#supported-features)). +(see the +[feature list of the release-3 branch](https://github.com/JuliaLang/Compat.jl/tree/release-3#supported-features)). If you require any of those backported features, be sure to specify the correct compatibility in your `Project.toml`. E.g. if the feature from Compat v4.x has been backported to v3.y, use `Compat = 3.y, 4.x`. If you use a feature that had