From dd1ef76140eae83d488528e50504e8f1ed72128f Mon Sep 17 00:00:00 2001 From: Igor Gnatenko Date: Sat, 28 Jan 2017 17:17:15 +0100 Subject: [PATCH] Update to 2.6.0 Signed-off-by: Igor Gnatenko --- .gitignore | 1 + python-semantic_version.spec | 87 +++++++++++++++++++----------------- sources | 2 +- 3 files changed, 47 insertions(+), 43 deletions(-) diff --git a/.gitignore b/.gitignore index bb25f56..8db3d96 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ /semantic_version-2.4.1.tar.gz /semantic_version-2.4.2.tar.gz /semantic_version-2.5.0.tar.gz +/semantic_version-2.6.0.tar.gz diff --git a/python-semantic_version.spec b/python-semantic_version.spec index cf76baa..1cfa13b 100644 --- a/python-semantic_version.spec +++ b/python-semantic_version.spec @@ -1,112 +1,115 @@ %global pypi_name semantic_version -%{!?_licensedir:%global license %%doc} - -%if 0%{?fedora} -%global with_python3 1 +%if 0%{?rhel} && 0%{?rhel} <= 7 +%bcond_with python3 +%else +%bcond_without python3 %endif Name: python-%{pypi_name} -Version: 2.5.0 -Release: 3%{?dist} -Summary: A library implementing the 'SemVer' scheme +Version: 2.6.0 +Release: 1%{?dist} +Summary: Library implementing the 'SemVer' scheme License: BSD URL: https://github.com/rbarrois/python-semanticversion -Source0: https://pypi.python.org/packages/source/s/%{pypi_name}/%{pypi_name}-%{version}.tar.gz +Source0: %{url}/archive/v%{version}/%{pypi_name}-%{version}.tar.gz BuildArch: noarch +%global _description \ +This small python library provides a few tools to handle semantic versioning\ +in Python. -%description -This small python library provides a few tools to handle semantic versioning -in Python +%description %{_description} %package -n python2-%{pypi_name} Summary: %{summary} BuildRequires: python2-devel -BuildRequires: python-setuptools >= 0.8 - +%if 0%{?rhel} && 0%{?rhel} <= 7 +BuildRequires: python-setuptools +%else +BuildRequires: python2-setuptools +%endif +BuildRequires: python2-django %{?python_provide:%python_provide python2-%{pypi_name}} Provides: python-semantic-version -%description -n python2-%{pypi_name} -This small python library provides a few tools to handle semantic versioning -in Python +%description -n python2-%{pypi_name} %{_description} + +Python 2 version. %if 0%{?with_python3} %package -n python3-%{pypi_name} Summary: %{summary} BuildRequires: python3-devel -BuildRequires: python3-setuptools >= 0.8 - +BuildRequires: python3-setuptools +BuildRequires: python3-django %{?python_provide:%python_provide python3-%{pypi_name}} -%description -n python3-%{pypi_name} -This small python library provides a few tools to handle semantic versioning -in Python +%description -n python3-%{pypi_name} %{_description} + +Python 3 version %endif - %package doc -Summary: Documentation for python-%{pypi_name} - +Summary: Documentation for python-%{pypi_name} BuildRequires: python-sphinx %description doc -Documentation for python-%{pypi_name} - +%{summary}. %prep -%setup -q -n %{pypi_name}-%{version} +%autosetup -n python-semanticversion-%{version} # Remove bundled egg-info rm -rf %{pypi_name}.egg-info # documentation builds due to broken symlink # https://github.com/rbarrois/python-semanticversion/issues/20 rm docs/credits.rst - %build -%{__python2} setup.py build -%if 0%{?with_python3} -%{__python3} setup.py build +%py2_build +%if %{with python3} +%py3_build %endif # generate html docs sphinx-build docs html # remove the sphinx-build leftovers rm -rf html/.{doctrees,buildinfo} - %install -%{__python2} setup.py install --skip-build --root %{buildroot} -%if 0%{?with_python3} -%{__python3} setup.py install --skip-build --root %{buildroot} +%py2_install +%if %{with python3} +%py3_install %endif %check %{__python2} setup.py test -%if 0%{?with_python3} +%if %{with python3} %{__python3} setup.py test %endif %files -n python2-%{pypi_name} %license LICENSE %doc README.rst ChangeLog -%{python2_sitelib}/%{pypi_name} -%{python2_sitelib}/%{pypi_name}-%{version}-py?.?.egg-info +%{python2_sitelib}/%{pypi_name}/ +%{python2_sitelib}/%{pypi_name}-*.egg-info/ -%if 0%{?with_python3} +%if %{with python3} %files -n python3-%{pypi_name} %license LICENSE %doc README.rst ChangeLog -%{python3_sitelib}/%{pypi_name} -%{python3_sitelib}/%{pypi_name}-%{version}-py?.?.egg-info +%{python3_sitelib}/%{pypi_name}/ +%{python3_sitelib}/%{pypi_name}-*.egg-info/ %endif - %files doc %license LICENSE %doc html %changelog +* Sat Jan 28 2017 Igor Gnatenko - 2.6.0-1 +- Update to 2.6.0 +- Make package to comply guidelines + * Mon Dec 19 2016 Miro HronĨok - 2.5.0-3 - Rebuild for Python 3.6 diff --git a/sources b/sources index f0733c5..ff94e56 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -9a3f8e3ca00dcd2da16e30d55a4d4d99 semantic_version-2.5.0.tar.gz +SHA512 (semantic_version-2.6.0.tar.gz) = 18db9279c2728565b13362c54bedbf569f0878cbe6bb58e631d87ffe7cff7d9131a30a2592cbf511091c03e854851159bbb298fe7469f53e8a2d92cf26ab4d0b