diff --git a/dev-util/ruff/Manifest b/dev-util/ruff/Manifest index 19fe1444020cc..b0a3a17059299 100644 --- a/dev-util/ruff/Manifest +++ b/dev-util/ruff/Manifest @@ -11,4 +11,8 @@ DIST ruff-0.16.3-crates.tar.xz 28676112 BLAKE2B 39589abb617e446375d6005c4af0febc DIST ruff-0.16.3.gh.tar.gz 12914254 BLAKE2B f4c3c8eb0f4894dde899147e44fe4c017993c4c593f15599bd3f282f28b6830f8502f85d6a32a1dad5839349fd92519806a8152b248f61906d3a2a8d8affee79 SHA512 1e1bdb8265944685c2ea4faa97601236d994a24e19ae0f615952dd2c103e930b104b85a0d16d376efe22384b2a46a8486fb5f7dd025496cb9e858c3090fc86bb DIST ruff-0.16.5-crates.tar.xz 29012584 BLAKE2B ba060dbbcbeaa9ba63d1b71808326db157166f132618f21c3ad38db15d18475052549fd5e6b302ca220f8ce6490d234baa9d076e1bef3d478a74ba483eaa04b8 SHA512 0a1b4ac564c87535b243537a3047f6332869c79f7cacdf24c0c27355f660c8fd4e9ee8dc1027381404fb02db3eb3071b8a13cd815445954a4a274322cb5872b5 DIST ruff-0.16.5.gh.tar.gz 13274834 BLAKE2B 9b52f311a8e409f4ad781981684191e90b226fb4ab9acaaf0154694750c1e90d92cd3fa0daf9e1ab537d75ddc0656d2b21d24476900d2775f34cdd343b95a549 SHA512 b6f108000cdab01cb8cb0cce05f2ce20b4b5f521d2823c1d5f8dbde263bbb75d2d23cda58ca9ae69eaae2ddb2536c31df74b6e3cf4ea494bdf7dba11defebb15 +DIST ruff-0.16.6-crates.tar.xz 29012584 BLAKE2B ba060dbbcbeaa9ba63d1b71808326db157166f132618f21c3ad38db15d18475052549fd5e6b302ca220f8ce6490d234baa9d076e1bef3d478a74ba483eaa04b8 SHA512 0a1b4ac564c87535b243537a3047f6332869c79f7cacdf24c0c27355f660c8fd4e9ee8dc1027381404fb02db3eb3071b8a13cd815445954a4a274322cb5872b5 +DIST ruff-0.16.6.gh.tar.gz 13482468 BLAKE2B 7b563df5d39afe53448402d5c708da3fdd07a094f923f593234de2a7eefc7c37f95bfa80e36ce014f0278f8c31765b64a51fc8a657b9372a5c31f090a89fb7a9 SHA512 9516c23d1e2963a5db8ed808c2ae99145afe44f8b86d8b83867f7baa839001784a356718de7f7c636fa8f125d269e2cfc622c68908eef941a39564bdfc9f5bd6 +DIST ruff-0.16.7-crates.tar.xz 29020036 BLAKE2B 032e998658369c0c2dd15d4307b29a09c56015194d570439fcdf2eb51bfe81ff325fcc6b316b82be88f93f1fcb3c6a4b7685cf81a5e178d23eac1bfc87885ac0 SHA512 a5b9e9da3964fadaef3b16900ace802585f8b956976f2a8edfe8b039ed870b4ba10ac526ff18f44560284c9413a7ace548f5ee4a56fbb768728268d8996a1ef8 +DIST ruff-0.16.7.gh.tar.gz 13601619 BLAKE2B d4a80f813d79b63b1bc9130654ea170ec6496e4bfa13afbeb2b3dc674227e2a8b0e67ab1f46b76394b47129487d3ec31226389dda9335e43257c6f2d44cf3b16 SHA512 221deb759aa9db4d3fc189a66011d6f763bbec60166e62fb935778966ec6f35e88b8ac94a31ed22412f6398100517f4f4e119d1aad884beba2a60e57c1e9662c DIST salsa-55e5e7d32fa3fc189276f35bb04c9438f9aedbd1.gh.tar.gz 731425 BLAKE2B ce720abaa295b46c7e1fa06a73e2ad9a48a6b9da7f2b4a91edba38a28bb9a63a1661886fc7c5d6dbc915f589f2e055731a544cdf18afb4dd7b3f6815c59e543b SHA512 91942cfc6bbfb7f07366cdd3d42e5296bff877ee723b24868ff3c278defd0ef247f03e957332bc0696553f0f1977a41c18d08efe7887f5bda3a1cb98543bddbd diff --git a/dev-util/ruff/ruff-0.16.6.ebuild b/dev-util/ruff/ruff-0.16.6.ebuild new file mode 100644 index 0000000000000..00904e43056a5 --- /dev/null +++ b/dev-util/ruff/ruff-0.16.6.ebuild @@ -0,0 +1,111 @@ +# Copyright 2024-2026 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +# Autogenerated by pycargoebuild 0.15.1 + +EAPI=8 + +CRATES=" +" + +RUST_MIN_VER="1.96" + +inherit shell-completion cargo + +DESCRIPTION="An extremely fast Python linter, written in Rust" +HOMEPAGE=" + https://docs.astral.sh/ruff/ + https://github.com/astral-sh/ruff +" +SRC_URI=" + ${CARGO_CRATE_URIS} + https://github.com/astral-sh/ruff/archive/refs/tags/${PV}.tar.gz -> ${P}.gh.tar.gz + https://github.com/gentoo-crate-dist/${PN}/releases/download/${PV}/${P}-crates.tar.xz +" + +LICENSE="MIT" +# Dependent crate licenses +LICENSE+=" + Apache-2.0 Apache-2.0-with-LLVM-exceptions BSD CC0-1.0 ISC MIT + MPL-2.0 PSF-2 Unicode-3.0 Unicode-DFS-2016 WTFPL-2 ZLIB +" +SLOT="0" +KEYWORDS="~amd64 ~arm64 ~loong ~riscv" + +RDEPEND=" + !elibc_musl? ( !elibc_Darwin? ( !elibc_bionic? ( dev-libs/jemalloc:= ) ) ) + app-arch/zstd +" +DEPEND=" + ${RDEPEND} +" + +QA_FLAGS_IGNORED="usr/bin/.*" + +DOCS=( + BREAKING_CHANGES.md + CONTRIBUTING.md + README.md + assets + docs +) + +src_prepare() { + default + + # Experimental cruft cleaner. These crates are not used by the ruff binary, + # and when they are removed in the git repo, the lockfile is regenerated + # and gets quite a bit smaller. Hence pycargoebuild also produces much + # smaller CRATES= variables. Less for the user to download, fewer distfiles + # to mirror. + pushd crates >/dev/null || die + rm -r ruff_{benchmark,dev} ty{,_{server,completion_eval}} *_wasm || die + popd > /dev/null || die + + # tests that hang in the ebuild environment + rm crates/ruff_annotate_snippets/tests/examples.rs || die +} + +src_configure() { + export RUSTFLAGS="${RUSTFLAGS}" + cargo_src_configure +} + +src_compile() { + local -x ZSTD_SYS_USE_PKG_CONFIG=1 + # Gentoo bug #927338 + if use !elibc_musl && use !elibc_Darwin && use !elibc_bionic; then + local -x CARGO_FEATURE_UNPREFIXED_MALLOC_ON_SUPPORTED_PLATFORMS=1 + local -x JEMALLOC_OVERRIDE="${ESYSROOT}/usr/$(get_libdir)"/libjemalloc.so + fi + cargo_src_compile --bin ruff + + local releasedir + releasedir=$(cargo_target_dir) + + ${releasedir}/ruff generate-shell-completion bash > ruff-completion.bash || die + ${releasedir}/ruff generate-shell-completion fish > ruff-completion.fish || die + ${releasedir}/ruff generate-shell-completion zsh > ruff-completion.zsh || die +} + +src_test() { + local -x ZSTD_SYS_USE_PKG_CONFIG=1 + # Gentoo bug #927338 + if use !elibc_musl && use !elibc_Darwin && use !elibc_bionic; then + local -x CARGO_FEATURE_UNPREFIXED_MALLOC_ON_SUPPORTED_PLATFORMS=1 + local -x JEMALLOC_OVERRIDE="${ESYSROOT}/usr/$(get_libdir)"/libjemalloc.so + fi + cargo_src_test --target-dir "${PWD}"/tested-target/ +} + +src_install() { + local releasedir=$(cargo_target_dir) + + dobin ${releasedir}/ruff + + newbashcomp ruff-completion.bash ruff + newfishcomp ruff-completion.fish ruff.fish + newzshcomp ruff-completion.zsh _ruff + + dodoc -r "${DOCS[@]}" +} diff --git a/dev-util/ruff/ruff-0.16.7.ebuild b/dev-util/ruff/ruff-0.16.7.ebuild new file mode 100644 index 0000000000000..00904e43056a5 --- /dev/null +++ b/dev-util/ruff/ruff-0.16.7.ebuild @@ -0,0 +1,111 @@ +# Copyright 2024-2026 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +# Autogenerated by pycargoebuild 0.15.1 + +EAPI=8 + +CRATES=" +" + +RUST_MIN_VER="1.96" + +inherit shell-completion cargo + +DESCRIPTION="An extremely fast Python linter, written in Rust" +HOMEPAGE=" + https://docs.astral.sh/ruff/ + https://github.com/astral-sh/ruff +" +SRC_URI=" + ${CARGO_CRATE_URIS} + https://github.com/astral-sh/ruff/archive/refs/tags/${PV}.tar.gz -> ${P}.gh.tar.gz + https://github.com/gentoo-crate-dist/${PN}/releases/download/${PV}/${P}-crates.tar.xz +" + +LICENSE="MIT" +# Dependent crate licenses +LICENSE+=" + Apache-2.0 Apache-2.0-with-LLVM-exceptions BSD CC0-1.0 ISC MIT + MPL-2.0 PSF-2 Unicode-3.0 Unicode-DFS-2016 WTFPL-2 ZLIB +" +SLOT="0" +KEYWORDS="~amd64 ~arm64 ~loong ~riscv" + +RDEPEND=" + !elibc_musl? ( !elibc_Darwin? ( !elibc_bionic? ( dev-libs/jemalloc:= ) ) ) + app-arch/zstd +" +DEPEND=" + ${RDEPEND} +" + +QA_FLAGS_IGNORED="usr/bin/.*" + +DOCS=( + BREAKING_CHANGES.md + CONTRIBUTING.md + README.md + assets + docs +) + +src_prepare() { + default + + # Experimental cruft cleaner. These crates are not used by the ruff binary, + # and when they are removed in the git repo, the lockfile is regenerated + # and gets quite a bit smaller. Hence pycargoebuild also produces much + # smaller CRATES= variables. Less for the user to download, fewer distfiles + # to mirror. + pushd crates >/dev/null || die + rm -r ruff_{benchmark,dev} ty{,_{server,completion_eval}} *_wasm || die + popd > /dev/null || die + + # tests that hang in the ebuild environment + rm crates/ruff_annotate_snippets/tests/examples.rs || die +} + +src_configure() { + export RUSTFLAGS="${RUSTFLAGS}" + cargo_src_configure +} + +src_compile() { + local -x ZSTD_SYS_USE_PKG_CONFIG=1 + # Gentoo bug #927338 + if use !elibc_musl && use !elibc_Darwin && use !elibc_bionic; then + local -x CARGO_FEATURE_UNPREFIXED_MALLOC_ON_SUPPORTED_PLATFORMS=1 + local -x JEMALLOC_OVERRIDE="${ESYSROOT}/usr/$(get_libdir)"/libjemalloc.so + fi + cargo_src_compile --bin ruff + + local releasedir + releasedir=$(cargo_target_dir) + + ${releasedir}/ruff generate-shell-completion bash > ruff-completion.bash || die + ${releasedir}/ruff generate-shell-completion fish > ruff-completion.fish || die + ${releasedir}/ruff generate-shell-completion zsh > ruff-completion.zsh || die +} + +src_test() { + local -x ZSTD_SYS_USE_PKG_CONFIG=1 + # Gentoo bug #927338 + if use !elibc_musl && use !elibc_Darwin && use !elibc_bionic; then + local -x CARGO_FEATURE_UNPREFIXED_MALLOC_ON_SUPPORTED_PLATFORMS=1 + local -x JEMALLOC_OVERRIDE="${ESYSROOT}/usr/$(get_libdir)"/libjemalloc.so + fi + cargo_src_test --target-dir "${PWD}"/tested-target/ +} + +src_install() { + local releasedir=$(cargo_target_dir) + + dobin ${releasedir}/ruff + + newbashcomp ruff-completion.bash ruff + newfishcomp ruff-completion.fish ruff.fish + newzshcomp ruff-completion.zsh _ruff + + dodoc -r "${DOCS[@]}" +}