#3 Remove the Python 2 subpackage, the Python 3 package provides the CLI now
Merged a year ago by cottsay. Opened a year ago by churchyard.
rpms/ churchyard/python-wstool nopy2  into  master

file modified
+8 -65
@@ -1,11 +1,8 @@ 

- %{?!_without_python2:%global with_python2 1}

- %{?!_without_python3:%global with_python3 0%{?_with_python3:1} || !0%{?rhel} || 0%{?rhel} >= 7}

- 

  %global srcname wstool

  

  Name:           python-%{srcname}

  Version:        0.1.17

- Release:        13%{?dist}

+ Release:        14%{?dist}

  Summary:        Tool for managing a workspace of multiple heterogeneous SCM repositories

  

  License:        BSD
@@ -41,33 +38,6 @@ 

  %description %_description

  

  

- %if 0%{?with_python2}

- %package -n python2-%{srcname}

- Summary:        %{summary}

- BuildRequires:  python2-dateutil

- BuildRequires:  python2-devel

- BuildRequires:  python2-mock

- BuildRequires:  python2-pyyaml

- BuildRequires:  python2-nose

- BuildRequires:  python2-setuptools

- BuildRequires:  python2-vcstools >= 0.1.38

- Requires:       bzr

- Requires:       git

- Requires:       mercurial

- Requires:       subversion

- %{?python_provide:%python_provide python2-%{srcname}}

- 

- %if %{undefined __pythondist_requires}

- Requires:       python2-dateutil

- Requires:       python2-pyyaml

- Requires:       python2-vcstools >= 0.1.38

- %endif # __pythondist_requires

- 

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

- %endif # with_python2

- 

- 

- %if 0%{?with_python3}

  %package -n python%{python3_pkgversion}-%{srcname}

  Summary:        %{summary}

  BuildRequires:  python%{python3_pkgversion}-dateutil
@@ -82,6 +52,7 @@ 

  Requires:       mercurial

  Requires:       subversion

  %{?python_provide:%python_provide python%{python3_pkgversion}-%{srcname}}

+ Obsoletes:      python2-%{srcname} < 0.1.17-14

  

  %if %{undefined __pythondist_requires}

  Requires:       python%{python3_pkgversion}-dateutil
@@ -90,7 +61,6 @@ 

  %endif # __pythondist_requires

  

  %description -n python%{python3_pkgversion}-%{srcname} %_description

- %endif # with_python3

  

  

  %prep
@@ -98,24 +68,11 @@ 

  

  

  %build

- %if 0%{?with_python2}

- %py2_build

- %endif # with_python2

- 

- %if 0%{?with_python3}

  %py3_build

- mv -v build/scripts-%{python3_version}/%{srcname} build/scripts-%{python3_version}/python3-%{srcname}

- %endif # with_python3

  

  

  %install

- %if 0%{?with_python2}

- %py2_install

- %endif # with_python2

- 

- %if 0%{?with_python3}

  %py3_install

- %endif # with_python3

  

  

  %check
@@ -125,21 +82,14 @@ 

  export GIT_COMMITTER_EMAIL="foo@example.com"

  export GIT_COMMITTER_NAME="Foo Bar"

  

- %if 0%{?with_python2}

- %{__python2} -m nose test

- %endif # with_python2

- 

- %if 0%{?with_python3}

  %{__python3} -m nose test

- %endif # with_python3

  

  

- %if 0%{?with_python2}

- %files -n python2-%{srcname}

+ %files -n python%{python3_pkgversion}-%{srcname}

  %license LICENSE

  %doc README.rst doc/changelog.rst

- %{python2_sitelib}/%{srcname}/

- %{python2_sitelib}/%{srcname}-%{version}-py%{python2_version}.egg-info/

+ %{python3_sitelib}/%{srcname}/

+ %{python3_sitelib}/%{srcname}-%{version}-py%{python3_version}.egg-info/

  %{_bindir}/%{srcname}

  %{_mandir}/man1/%{srcname}.1.gz

  # bash completion
@@ -148,19 +98,12 @@ 

  %dir %{_datadir}/zsh/

  %dir %{_datadir}/zsh/site-functions/

  %{_datadir}/zsh/site-functions/_wstool

- %endif # with_python2

- 

- %if 0%{?with_python3}

- %files -n python%{python3_pkgversion}-%{srcname}

- %license LICENSE

- %doc README.rst doc/changelog.rst

- %{python3_sitelib}/%{srcname}/

- %{python3_sitelib}/%{srcname}-%{version}-py%{python3_version}.egg-info/

- %{_bindir}/python3-%{srcname}

- %endif # with_python3

  

  

  %changelog

+ * Tue Sep 03 2019 Miro Hrončok <mhroncok@redhat.com> - 0.1.17-14

+ - Remove the Python 2 subpackage, the Python 3 package provides the CLI now

+ 

  * Mon Aug 19 2019 Miro Hrončok <mhroncok@redhat.com> - 0.1.17-13

  - Rebuilt for Python 3.8

  

I intent to merge this on Thursday if there is no feedback by then.

Pull-Request has been merged by cottsay

a year ago
Metadata