From 79e23daa12521c8d1f214db4c3bcc69dc4a3744e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Miro=20Hron=C4=8Dok?= Date: Mon, 12 Aug 2019 12:42:41 +0200 Subject: [PATCH] Make /usr/bin/coverage Python 3 - Remove /usr/bin/python*-coverage links to cleanse tab completion results - Drop no longer needed Obsoletes for platform-python-coverage --- python-coverage.spec | 42 ++++++++++++++++++------------------------ 1 file changed, 18 insertions(+), 24 deletions(-) diff --git a/python-coverage.spec b/python-coverage.spec index 7556ca1..5670459 100644 --- a/python-coverage.spec +++ b/python-coverage.spec @@ -3,7 +3,7 @@ Name: python-coverage Summary: Code coverage testing module for Python Version: 4.5.4 -Release: 1%{?prever}%{?dist} +Release: 2%{?prever}%{?dist} # jquery(MIT): # coverage/htmlfiles/jquery.min.js # MIT or GPL: @@ -55,7 +55,7 @@ Provides: bundled(js-jquery-debounce) = 1.1 Provides: bundled(js-jquery-hotkeys) = 0.8 Provides: bundled(js-jquery-isonscreen) = 1.2.0 Provides: bundled(js-jquery-tablesorter) -Obsoletes: platform-python-coverage < %{version}-%{release} +Conflicts: python2-coverage < 4.5.4-2 %description -n python3-coverage Coverage.py is a Python 3 module that measures code coverage during Python @@ -75,49 +75,43 @@ sed -i 's/\r//g' README.rst %py3_build %install -%py3_install -mv %{buildroot}/%{_bindir}/coverage %{buildroot}/%{_bindir}/python3-coverage - %py2_install +rm %{buildroot}/%{_bindir}/coverage -# rename binaries, make compat symlinks +%py3_install +rm %{buildroot}/%{_bindir}/coverage + +# make compat symlinks pushd %{buildroot}%{_bindir} -mv coverage python-coverage - -rm -rf coverage-2* coverage2 - -for i in python2-coverage coverage coverage2 coverage-%{python2_version}; do - ln -s python-coverage $i -done - -rm -rf coverage-3* coverage3 - -for i in coverage3 coverage-%{python3_version}; do - ln -s python3-coverage $i -done +ln -s coverage-%{python2_version} coverage-2 +ln -s coverage-%{python3_version} coverage-3 +ln -s coverage-%{python3_version} coverage popd + %files -n python2-coverage %license LICENSE.txt NOTICE.txt %doc README.rst -%{_bindir}/coverage %{_bindir}/coverage2 %{_bindir}/coverage-2* -%{_bindir}/python-coverage -%{_bindir}/python2-coverage %{python2_sitearch}/coverage/ %{python2_sitearch}/coverage*.egg-info/ %files -n python3-coverage %license LICENSE.txt NOTICE.txt %doc README.rst -%{_bindir}/coverage-3* +%{_bindir}/coverage %{_bindir}/coverage3 -%{_bindir}/python3-coverage +%{_bindir}/coverage-3* %{python3_sitearch}/coverage/ %{python3_sitearch}/coverage*.egg-info/ %changelog +* Mon Aug 12 2019 Miro HronĨok - 4.5.4-2 +- Make /usr/bin/coverage Python 3 +- Remove /usr/bin/python*-coverage links to cleanse tab completion results +- Drop no longer needed Obsoletes for platform-python-coverage + * Mon Aug 5 2019 Tom Callaway - 4.5.4-1 - update to 4.5.4