From d7e029263a689171846ecf289bafae2282619ccb Mon Sep 17 00:00:00 2001 From: Henry Schreiner Date: Tue, 2 Jul 2024 11:18:05 -0400 Subject: [PATCH] docs: hide deprecated options in README Signed-off-by: Henry Schreiner --- README.md | 6 ------ src/scikit_build_core/settings/skbuild_docs.py | 4 +++- 2 files changed, 3 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index afb84e93..d83b0f60 100644 --- a/README.md +++ b/README.md @@ -152,9 +152,6 @@ print("```\n") ```toml [tool.scikit-build] -# DEPRECATED in 0.8; use version instead. -cmake.minimum-version = "" - # The versions of CMake to allow. If CMake is not present on the system or does # not pass this specifier, it will be downloaded via PyPI if possible. An empty # string will disable this check. @@ -182,9 +179,6 @@ cmake.source-dir = "." # target. cmake.targets = [] -# DEPRECATED in 0.8; use version instead. -ninja.minimum-version = "" - # The versions of Ninja to allow. If Ninja is not present on the system or does # not pass this specifier, it will be downloaded via PyPI if possible. An empty # string will disable this check. diff --git a/src/scikit_build_core/settings/skbuild_docs.py b/src/scikit_build_core/settings/skbuild_docs.py index a8e0f81e..65a03c34 100644 --- a/src/scikit_build_core/settings/skbuild_docs.py +++ b/src/scikit_build_core/settings/skbuild_docs.py @@ -13,12 +13,14 @@ def __dir__() -> list[str]: version = ".".join(__version__.split(".")[:2]) +INV = {"cmake.minimum-version", "ninja.minimum-version"} + def mk_skbuild_docs() -> str: """ Makes documentation for the skbuild model. """ - items = list(mk_docs(ScikitBuildSettings)) + items = [x for x in mk_docs(ScikitBuildSettings) if x.name not in INV] for item in items: if item.name == "minimum-version": item.default = f'"{version}" # current version'