# Generated by go2rpm 1.10.0
%bcond_without check

# https://github.com/sentriz/cliphist
%global goipath         go.senan.xyz/cliphist
%global forgeurl        https://github.com/sentriz/cliphist
Version:                0.6.1

%gometa -L -f

%global goname cliphist

%global common_description %{expand:
Wayland clipboard manager with support for multimedia.}

%global golicenses      LICENSE
%global godocs          CHANGELOG.md version.txt readme.md

Name:           cliphist
Release:        %autorelease.1
Summary:        Wayland clipboard manager with support for multimedia

License:        GPL-3.0-only
URL:            %{gourl}
Source:         %{gosource}
Source:         vendor-%{version}.tar.gz
Source:         bundle_go_deps_for_rpm.sh

Requires:       wl-clipboard
Recommends:     xdg-utils

%description %{common_description}

%prep
%goprep -k
%setup -q -T -D -a 1
%autopatch -p1

%build
%gobuild -o %{gobuilddir}/bin/cliphist %{goipath}

%install
install -m 0755 -vd                     %{buildroot}%{_bindir}
install -m 0755 -vp %{gobuilddir}/bin/* %{buildroot}%{_bindir}/

%if %{with check}
%check
%gocheck
%endif

%files
%license LICENSE
%license vendor/modules.txt
%doc CHANGELOG.md version.txt readme.md
%{_bindir}/cliphist

%changelog
%autochangelog