3 %bcond_with tests # do not perform "make test"
8 Summary: Weblate commandline client using Weblate's REST API
13 Group: Libraries/Python
14 Source0: https://files.pythonhosted.org/packages/source/w/%{module}/%{module}-%{version}.tar.gz
15 # Source0-md5: 15a3a221938aa4ef75698aed72ffd0be
16 URL: https://weblate.org/
17 BuildRequires: python3-devel
18 BuildRequires: python3-setuptools
19 BuildRequires: rpm-pythonprov
20 BuildRequires: rpmbuild(macros) >= 1.714
21 Requires: python3-pyxdg
22 Requires: python3-setuptools
24 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
27 A command line utility for Weblate, translation tool with tight
28 version control integration
31 %setup -q -n %{module}-%{version}
33 # Remove bundled egg-info
34 %{__rm} -r %{module}.egg-info
37 %py3_build %{?with_tests:test}
40 rm -rf $RPM_BUILD_ROOT
43 %{__rm} $RPM_BUILD_ROOT%{py3_sitescriptdir}/%{module}/test_*
44 %{__rm} $RPM_BUILD_ROOT%{py3_sitescriptdir}/%{module}/__pycache__/test_*
47 rm -rf $RPM_BUILD_ROOT
50 %defattr(644,root,root,755)
52 %attr(755,root,root) %{_bindir}/wlc
53 %{py3_sitescriptdir}/%{pypi_name}
54 %{py3_sitescriptdir}/%{egg_name}-%{version}-py*.egg-info