diff --git a/python-webassets.changes b/python-webassets.changes index 94ef558..3fdec26 100644 --- a/python-webassets.changes +++ b/python-webassets.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Mon May 18 07:25:35 UTC 2020 - Petr Gajdos + +- %python3_only -> %python_alternative + ------------------------------------------------------------------- Thu Feb 6 14:17:00 UTC 2020 - Marketa Calabkova diff --git a/python-webassets.spec b/python-webassets.spec index c7a729a..38018b0 100644 --- a/python-webassets.spec +++ b/python-webassets.spec @@ -36,6 +36,8 @@ BuildRequires: %{python_module setuptools} BuildRequires: fdupes BuildRequires: python-rpm-macros Requires: python-setuptools +Requires(post): update-alternatives +Requires(postun): update-alternatives BuildArch: noarch %python_subpackages @@ -55,16 +57,23 @@ sed -i -e 's:e.message:e.args[0]:g' tests/test_filters.py %install %python_install +%python_clone -a %{buildroot}%{_bindir}/webassets %python_expand %fdupes %{buildroot}%{$python_sitelib} %check export LANG="en_US.UTF8" %pytest +%post +%python_install_alternative webassets + +%postun +%python_uninstall_alternative webassets + %files %{python_files} %license LICENSE %doc AUTHORS CHANGES README.rst -%python3_only %{_bindir}/webassets +%python_alternative %{_bindir}/webassets %{python_sitelib}/* %changelog