diff --git a/vex.spec b/vex.spec index d75dc5b..b1318b8 100644 --- a/vex.spec +++ b/vex.spec @@ -11,6 +11,7 @@ BuildArch: noarch Requires: python3-virtualenv Requires: python3-setuptools +BuildRequires: python3-setuptools BuildRequires: python3-devel BuildRequires: python3-pytest @@ -23,6 +24,8 @@ nicer to use. And it works with non-bash shells. %prep %autosetup -n %{name}-%{version} +# Remove bundled egg-info +rm -rf %{name}.egg-info # Remove useless files (merge info) rm -rf %{name}/shell_configs/zsh.orig rm -rf %{name}/shell_configs/fish.orig @@ -30,23 +33,21 @@ rm -rf %{name}/shell_configs/fish.orig # Port from mock to unittest.mock sed -i "s/^from mock import /from unittest.mock import /" vex/tests/test_config.py vex/tests/test_main.py vex/tests/test_run.py vex/tests/test_shell_config.py -%generate_buildrequires -%pyproject_buildrequires - %build -%pyproject_wheel +%py3_build %install -%pyproject_install -%pyproject_save_files -l %{name} +%py3_install %check -%pyproject_check_import %{__python3} -m pytest %{name}/tests/ -%files -f %{pyproject_files} +%files %doc README.rst +%license LICENSE %{_bindir}/%{name} +%{python3_sitelib}/%{name} +%{python3_sitelib}/%{name}-%{version}-py%{python3_version}.egg-info %changelog %autochangelog