# Generated by rust2rpm 27
%global crate koji
# differentiate from fedora koji
%global diffname git-%{crate}
%global altdiffname cococonscious-%{crate}

Name:           rust-koji
Version:        3.4.0
Release:        1%?dist
Summary:        Interactive CLI for creating conventional commits

License:        MIT
URL:            https://crates.io/crates/koji
Source:         %{crates_source}

BuildRequires:  cargo-rpm-macros >= 24 anda-srpm-macros
BuildRequires:  openssl-devel

%global _description %{expand:
An interactive CLI for creating conventional commits.}

%description %{_description}

%package     -n %{diffname}
Summary:        %{summary}
License:        (Apache-2.0 OR MIT) AND BSD-3-Clause AND (Apache-2.0 OR BSL-1.0) AND (Apache-2.0 OR MIT) AND (Apache-2.0 WITH LLVM-exception OR Apache-2.0 OR MIT) AND (BSD-2-Clause OR Apache-2.0 OR MIT) AND BSD-3-Clause AND CC0-1.0 AND ISC AND MIT AND MIT AND (MIT OR Apache-2.0) AND (MIT OR Apache-2.0) AND MPL-2.0 AND Unicode-3.0 AND (Unlicense OR MIT)
# LICENSE.dependencies contains a full license breakdown
Provides:       cococonscious-%{crate} = %{version}-%{release}
Conflicts:      koji

%description -n %{diffname} %{_description}

%files       -n %{diffname}
%license LICENSE
%license LICENSE.dependencies
%doc CHANGELOG.md
%doc README.md
%{_bindir}/%{diffname}
%{_bindir}/%{crate}

%prep
%autosetup -n %{crate}-%{version}
%cargo_prep_online

%build
%cargo_build
%{cargo_license_summary_online}
%{cargo_license_online} > LICENSE.dependencies

%install
install -Dm755 target/rpm/%{crate} %{buildroot}%{_bindir}/%{diffname}
%{__ln} -sf %{diffname} %{buildroot}%{_bindir}/%{crate}
