%global srcname sarge
%global _description %{expand:The sarge package provides a wrapper for subprocess which provides command
pipeline functionality.

This package leverages subprocess to provide easy-to-use cross-platform command
pipelines with a POSIX flavour: you can have chains of commands using ;, &,
pipes using | and |&, and redirection.}

Name:           python-%{srcname}
Version:        0.1.7.post1
Release:        1%{?dist}
Summary:        Subprocess Allegedly Rewards Good Encapsulation

License:        BSD-3-Clause
URL:            https://docs.red-dove.com/sarge/
Source0:        https://github.com/vsajip/%{srcname}/archive/%{version}/%{srcname}-%{version}.tar.gz

BuildRequires:  python3-devel
BuildArch:      noarch

%description
%{_description}


%package -n python3-%{srcname}
Summary:        %{summary}

%description -n python3-%{srcname}
%{_description}


%prep
%autosetup -n %{srcname}-%{version}


%generate_buildrequires
%pyproject_buildrequires -t


%build
%pyproject_wheel


%install
%pyproject_install
%pyproject_save_files %{srcname}


%check
%tox


%files -n python3-%{srcname} -f %{pyproject_files}
%doc README.rst
%license LICENSE


%changelog
* Sat Apr 15 2023 Mohamed El Morabity <melmorabity@fedoraproject.org> - 0.1.7.post1-1
- Update to 0.1.7.post1

* Mon Jan 02 2023 Mohamed El Morabity <melmorabity@fedoraproject.org> - 0.1.7-1
- Initial RPM release