%global srcname twine
Name: python-%{srcname}
Version: 2.0.0
Release: 1%{?dist}
Summary: Collection of utilities for interacting with PyPI
License: ASL 2.0
URL: https://github.com/pypa/%{srcname}
Source0: %{url}/archive/%{version}/%{srcname}-%{version}.tar.gz
# The dependencies for the docs pin Sphinx to a super old version
Source1: twine.1
# There's a shebang in twine/__main__.py which generates rpmlint warnings.
Patch0: 0001-Remove-shebang-from-__main__.py.patch
BuildArch: noarch
%description
Twine is a utility for interacting with PyPI.
Currently it only supports registering projects and uploading distributions.
%package -n %{srcname}
Summary: Twine is a utility for publishing Python packages on PyPI
Requires: %{py3_dist pkginfo readme-renderer requests requests-toolbelt setuptools tqdm}
Recommends: %{py3_dist keyring}
BuildRequires: python3-devel
BuildRequires: %{py3_dist pkginfo readme-renderer requests requests-toolbelt setuptools tqdm}
BuildRequires: %{py3_dist pytest pretend}
Obsoletes: python2-%{srcname} < 1.12.2-3
Obsoletes: python3-%{srcname} < 1.12.2-3
# There used to be a doc sub-package, but the CLI should ship with man pages
Provides: %{name}-doc = %{version}-%{release}
Obsoletes: %{name}-doc < 1.9.1-3
%description -n %{srcname}
Twine is a utility for interacting with PyPI.
Currently it only supports registering projects and uploading distributions.
%prep
%autosetup -p1 -n %{srcname}-%{version}
%build
%py3_build
%install
%py3_install
install -p -D -T -m 0644 %{SOURCE1} %{buildroot}%{_mandir}/man1/%{srcname}.1
%check
%{__python3} -m pytest
%files -n %{srcname}
%license LICENSE
%doc README.rst AUTHORS
%{_mandir}/man1/%{srcname}.1*
%{_bindir}/twine
%{python3_sitelib}/twine/
%{python3_sitelib}/twine-*.egg-info/
%changelog
* Tue Jun 16 2020 Charalampos Stratakis <cstratak@redhat.com> - 2.0.0-1
- Update to version 2.0.0
* Fri Jul 26 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.12.2-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
* Tue Apr 30 2019 Jeremy Cline <jcline@redhat.com> - 1.12.2-3
- Bump the obsoletes so the upgrade path from F29 works
- Include the manpage since the dep chain for docs building is broken
* Sat Feb 02 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.12.2-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
* Wed Dec 05 2018 Randy Barlow <bowlofeggs@fedoraproject.org> - 1.12.2-1
- Update to 1.12.2 (#1551178).
- https://github.com/pypa/twine/blob/1.12.2/docs/changelog.rst
* Tue Nov 20 2018 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 1.10.0-6
- Drop python2 subpackage
* Mon Sep 24 2018 Miro Hrončok <mhroncok@redhat.com> - 1.10.0-5
- Make the keyring dependency optional
- Run tests
* Thu Sep 13 2018 Jeremy Cline <jeremy@jcline.org> - 1.10.0-4
- Update the summary of the "twine" package
* Sat Jul 14 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.10.0-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
* Tue Jun 19 2018 Miro Hrončok <mhroncok@redhat.com> - 1.10.0-2
- Rebuilt for Python 3.7
* Thu Mar 08 2018 Jeremy Cline <jeremy@jcline.org> - 1.10.0-1
- Update to latest upstream
* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.9.1-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
* Tue Nov 14 2017 Jeremy Cline <jeremy@jcline.org> - 1.9.1-4
- Re-add the Python 2 package (rhbz #1512552)
* Tue Oct 31 2017 Jeremy Cline <jeremy@jcline.org> - 1.9.1-3
- Drop pythonX- subpackages as Twine is a CLI (rhbz #1507815)
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.9.1-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
* Thu Jun 01 2017 Jeremy Cline <jeremy@jcline.org> - 1.9.1-1
- Update to 1.9.1 (#1448841)
- Add python-keyring and python-tqdm as dependencies
- Remove python-clint as a dependency
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.8.1-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
* Mon Dec 19 2016 Miro Hrončok <mhroncok@redhat.com> - 1.8.1-2
- Rebuild for Python 3.6
* Tue Aug 09 2016 Jeremy Cline <jeremy@jcline.org> - 1.8.1-1
- Update to 1.8.1
* Mon Jul 18 2016 Jeremy Cline <jeremy@jcline.org> - 1.7.4-3
- Keep objects.inv to support intersphinx documentation
* Mon Jul 18 2016 Jeremy Cline <jeremy@jcline.org> - 1.7.4-2
- Add clint as a build dependency so the tests pass
* Fri Jul 15 2016 Jeremy Cline <jeremy@jcline.org> - 1.7.4-1
- Update to the latest upstream release
- Add clint as a dependency
* Tue Jul 12 2016 Jeremy Cline <jeremy@jcline.org> - 1.6.5-5
- Remove unnecessary shebang in __main__.py that caused rpmlint errors
* Mon Jul 11 2016 Jeremy Cline <jeremy@jcline.org> - 1.6.5-4
- Mark man pages as docs
* Mon Jul 11 2016 Jeremy Cline <jeremy@jcline.org> - 1.6.5-3
- Use python_version macro rather than hardcoding version numbers.
* Fri Jul 08 2016 Jeremy Cline <jeremy@jcline.org> - 1.6.5-2
- Update Source0 url to the <name>-<version>.tar.gz format
* Thu Jun 09 2016 Jeremy Cline <jeremy@jcline.org> - 1.6.5-1
- Initial commit