micropipenv/micropipenv.spec

48 lines
1.1 KiB
RPMSpec
Raw Normal View History

2020-03-16 13:37:41 +00:00
Name: micropipenv
2023-02-22 21:12:15 +00:00
Version: 1.4.6
2023-02-22 21:04:57 +00:00
Release: %autorelease
2020-03-16 13:37:41 +00:00
Summary: A simple wrapper around pip to support Pipenv and Poetry files
License: LGPLv3+
2020-03-16 13:37:41 +00:00
URL: https://github.com/thoth-station/%{name}
Source0: %{url}/archive/v%{version}.tar.gz
BuildArch: noarch
2020-05-05 17:01:30 +00:00
2020-03-16 13:37:41 +00:00
BuildRequires: python3-devel
%py_provides python3-%{name}
2020-03-16 13:37:41 +00:00
Recommends: micropipenv+toml
2020-03-16 13:37:41 +00:00
%description
A lightweight wrapper for pip to support Pipenv and Poetry lock files or
converting them to pip-tools compatible output.
%pyproject_extras_subpkg -n %{name} toml
2020-03-16 13:37:41 +00:00
%prep
2021-03-12 09:48:26 +00:00
%autosetup
2020-03-16 13:37:41 +00:00
# Remove shebang line from the module
sed -i '1{\@^#!/usr/bin/env python@d}' %{name}.py
2022-07-26 07:27:04 +00:00
%generate_buildrequires
%pyproject_buildrequires -r -t -x toml
2022-07-26 07:27:04 +00:00
2020-03-16 13:37:41 +00:00
%build
2022-07-26 07:27:04 +00:00
%pyproject_wheel
2020-03-16 13:37:41 +00:00
%install
2022-07-26 07:27:04 +00:00
%pyproject_install
%pyproject_save_files %{name}
2020-03-16 13:37:41 +00:00
%check
2020-10-22 12:43:34 +00:00
# skipped tests requires internet or checks pip version
2022-02-21 09:39:11 +00:00
%pytest -m "not online" -k "not test_check_pip_version and not test_install_invalid_toml_file"
2020-03-16 13:37:41 +00:00
2022-07-26 07:27:04 +00:00
%files -f %pyproject_files
2020-03-16 13:37:41 +00:00
%doc README.rst
%{_bindir}/micropipenv
%changelog
2023-02-22 21:04:57 +00:00
%autochangelog