%{?python_enable_dependency_generator} %global revnum 116 %global commit a420e389f7272f2c665241d0766e67480a228867 %global shortcommit %(c=%{commit}; echo ${c:0:7}) Name: sgmanager Version: 2.0.0 Release: 0+20180906git+%{revnum}.%{shortcommit}%{?dist} Summary: OpenStack Security Groups Management Tool License: BSD URL: https://github.com/gooddata/sgmanager Source: %{url}/archive/%{commit}/%{name}-%{version}~git+%{revnum}.%{shortcommit}.tar.gz BuildRequires: python3-devel >= 3.6 BuildRequires: /usr/bin/flit BuildRequires: python3dist(pytest) BuildRequires: python3dist(orderedset) BuildRequires: python3dist(pyyaml) BuildArch: noarch %description %{summary}. %prep %autosetup -n %{name}-%{commit} %build FLIT_NO_NETWORK=1 flit build --format wheel %install %py3_install_wheel sgmanager-2.0.0-py3-none-any.whl %check PYTHONPATH=%{buildroot}%{python3_sitelib} %{__python3} -m pytest -vv %files %license LICENSE %doc README.md %{_bindir}/sgmanager %{python3_sitelib}/sgmanager-*.dist-info/ %{python3_sitelib}/sgmanager/ %changelog * Tue Sep 04 2018 Igor Gnatenko - 2.0.0-0+20180906git+116.a420e38 - Initial package