# Copyright 2026 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

# Autogenerated by pycargoebuild 0.15.1

EAPI=8

RUST_MIN_VER="1.85.0"

CRATES="
"

inherit cargo

DESCRIPTION="Fast command line app to run commands in parallel"
HOMEPAGE="https://github.com/aaronriekenberg/rust-parallel"

SRC_URI="
	https://github.com/aaronriekenberg/${PN}/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz
	https://github.com/gentoo-crate-dist/${PN}/releases/download/v${PV}/${P}-crates.tar.xz
"

LICENSE="MIT"
# Dependent crate licenses
LICENSE+=" Apache-2.0 BSD MIT Unicode-DFS-2016"
SLOT="0"
KEYWORDS="~amd64"
IUSE="symlink"

RDEPEND="symlink? ( !sys-process/parallel )"

src_install() {
	dobin $(cargo_target_dir)/rust-parallel

	if use symlink ; then
		dosym rust-parallel /usr/bin/parallel
	fi
}
