Blame python-accept-types.spec

b62000a
%global pypi_name accept-types
b62000a
%global pypi_version 0.4.1
b62000a
%global commit cb2531768689478737e4a8454def6a60575424e3
b62000a
%global shortcommit %(c=%{commit}; echo ${c:0:12})
b62000a
%global owner tim_heap
b62000a
b62000a
Name:           python-%{pypi_name}
b62000a
Version:        %{pypi_version}
b62000a
Release:        3%{?dist}
b62000a
Summary:        Use the correct accept type for an HTTP request
b62000a
License:        MIT
b62000a
URL:            https://bitbucket.org/%{owner}/%{name}
b62000a
# The pypi source has the test suite stripped out :/
b62000a
Source0:        %{URL}/get/%{version}.tar.gz
b62000a
b62000a
BuildArch:      noarch
b62000a
BuildRequires:  python3-devel
b62000a
b62000a
%global desc \
b62000a
accept-types helps your application respond to a HTTP request in a way \
b62000a
that a client prefers.  The Accept header of an HTTP request informs the \
b62000a
server which MIME types the client is expecting back from this request, \
b62000a
with weighting to indicate the most prefered. If your server can respond \
b62000a
in multiple formats (e.g.: JSON, XML, HTML), the client can easily tell \
b62000a
your server which is the prefered format without resorting to hacks like \
b62000a
'&format=json' on the end of query strings.
b62000a
b62000a
%description
b62000a
%{desc}
b62000a
b62000a
%package -n     python3-%{pypi_name}
b62000a
Summary:        %{summary}
b62000a
b62000a
%description -n python3-%{pypi_name}
b62000a
%{desc}
b62000a
b62000a
%prep
b62000a
%autosetup -p1 -n %{owner}-%{name}-%{shortcommit}
b62000a
%generate_buildrequires
b62000a
%pyproject_buildrequires -t
b62000a
b62000a
%build
b62000a
%pyproject_wheel
b62000a
b62000a
%check
b62000a
%tox
b62000a
b62000a
%install
b62000a
%pyproject_install
b62000a
%pyproject_save_files accept_types
b62000a
b62000a
%files -n python3-%{pypi_name} -f %{pyproject_files}
b62000a
%doc README.rst
b62000a
b62000a
%changelog
b62000a
* Tue Mar 15 2022 Paul Wouters <paul.wouters@aiven.io> - 0.4.1-3
b62000a
- Resolves: rhbz#2050434 python-accept-types
b62000a
- Fix license, description and summary, cleanup BuildRequires:
b62000a
b62000a
* Mon Feb 07 2022 Paul Wouters <paul.wouters@aiven.io> - 0.4.1-2
b62000a
- Use latest python macros
b62000a
b62000a
* Thu Feb 03 2022 Paul Wouters <paul.wouters@aiven.io> - 0.4.1-1
b62000a
- Initial package.