2016-01-20 20:40:49 +00:00
|
|
|
#
|
2021-07-07 08:27:47 +00:00
|
|
|
# spec file
|
2016-01-20 20:40:49 +00:00
|
|
|
#
|
2021-01-11 15:07:33 +00:00
|
|
|
# Copyright (c) 2021 SUSE LLC
|
2016-01-20 20:40:49 +00:00
|
|
|
#
|
|
|
|
# All modifications and additions to the file contributed by third parties
|
|
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
|
|
# upon. The license for this file, and modifications and additions to the
|
|
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
|
|
# license for the pristine package is not an Open Source License, in which
|
|
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
|
|
# published by the Open Source Initiative.
|
|
|
|
|
2018-09-17 09:21:33 +00:00
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
2016-01-20 20:40:49 +00:00
|
|
|
#
|
|
|
|
|
2018-07-14 09:02:23 +00:00
|
|
|
|
2017-07-07 12:56:37 +00:00
|
|
|
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
2020-11-03 16:09:29 +00:00
|
|
|
%define allpython python
|
2019-02-09 13:21:50 +00:00
|
|
|
%global flavor @BUILD_FLAVOR@%{nil}
|
|
|
|
%if "%{flavor}" == "test"
|
|
|
|
%define test 1
|
2019-12-01 23:22:43 +00:00
|
|
|
%define pkg_suffix -test
|
2019-02-18 08:41:56 +00:00
|
|
|
%bcond_without test
|
2019-02-09 13:21:50 +00:00
|
|
|
%else
|
2019-12-01 23:22:43 +00:00
|
|
|
%define pkg_suffix %{nil}
|
2019-02-18 08:41:56 +00:00
|
|
|
%bcond_with test
|
2019-02-09 13:21:50 +00:00
|
|
|
%endif
|
2019-12-01 23:22:43 +00:00
|
|
|
Name: python-tqdm%{pkg_suffix}
|
2021-07-07 08:27:47 +00:00
|
|
|
Version: 4.61.1
|
2016-01-20 20:40:49 +00:00
|
|
|
Release: 0
|
2017-10-06 14:49:40 +00:00
|
|
|
Summary: An extensible progress meter
|
2021-04-06 08:29:37 +00:00
|
|
|
License: MIT AND MPL-2.0
|
2018-07-14 09:02:23 +00:00
|
|
|
URL: https://github.com/tqdm/tqdm
|
2016-09-22 20:54:41 +00:00
|
|
|
Source: https://files.pythonhosted.org/packages/source/t/tqdm/tqdm-%{version}.tar.gz
|
2021-01-11 15:07:33 +00:00
|
|
|
BuildRequires: %{python_module setuptools_scm}
|
2017-07-07 12:56:37 +00:00
|
|
|
BuildRequires: %{python_module setuptools}
|
2021-01-11 15:07:33 +00:00
|
|
|
BuildRequires: %{python_module toml}
|
2017-10-11 06:59:36 +00:00
|
|
|
BuildRequires: fdupes
|
2017-07-07 12:56:37 +00:00
|
|
|
BuildRequires: python-rpm-macros
|
2018-08-25 20:11:37 +00:00
|
|
|
Requires(post): update-alternatives
|
2021-04-06 08:29:37 +00:00
|
|
|
Requires(postun):update-alternatives
|
2021-02-14 20:47:28 +00:00
|
|
|
Enhances: python-ipython
|
2021-04-06 08:29:37 +00:00
|
|
|
BuildArch: noarch
|
2019-02-09 13:21:50 +00:00
|
|
|
%if %{with test}
|
2017-07-07 12:56:37 +00:00
|
|
|
# SECTION test requirements
|
2021-04-06 08:29:37 +00:00
|
|
|
BuildRequires: %{python_module numpy if (python-base without python36-base)}
|
2021-01-13 11:30:12 +00:00
|
|
|
BuildRequires: %{python_module pytest-asyncio}
|
2021-01-13 09:31:24 +00:00
|
|
|
BuildRequires: %{python_module pytest-timeout}
|
2021-01-13 11:30:12 +00:00
|
|
|
BuildRequires: %{python_module pytest}
|
2019-02-12 12:14:05 +00:00
|
|
|
BuildRequires: %{python_module tqdm}
|
2021-02-16 09:58:35 +00:00
|
|
|
%if ! 0%{?_with_ringdisabled}
|
2021-04-06 08:29:37 +00:00
|
|
|
BuildRequires: %{python_module pandas if (python-base without python36-base)}
|
2021-02-16 09:58:35 +00:00
|
|
|
%endif
|
2017-07-07 12:56:37 +00:00
|
|
|
# /SECTION
|
2019-02-09 13:21:50 +00:00
|
|
|
%endif
|
2017-07-07 12:56:37 +00:00
|
|
|
%python_subpackages
|
2016-01-20 20:40:49 +00:00
|
|
|
|
|
|
|
%description
|
2017-10-06 14:49:40 +00:00
|
|
|
tqdm lets you output a progress meter from within loops by wrapping
|
|
|
|
any iterable with "tqdm(iterable)".
|
|
|
|
tqdm's overhead is one order of magnitude less than python-progressbar
|
|
|
|
and does not require ncurses.
|
2016-01-20 20:40:49 +00:00
|
|
|
|
2021-04-06 08:29:37 +00:00
|
|
|
%package -n %{allpython}-tqdm-bash-completion
|
2020-11-03 16:09:29 +00:00
|
|
|
Summary: Bash completion for python-tqdm
|
|
|
|
Requires: bash-completion
|
2021-02-01 10:31:49 +00:00
|
|
|
Supplements: %{python_module tqdm and bash-completion}
|
2020-11-03 16:09:29 +00:00
|
|
|
|
2021-04-06 08:29:37 +00:00
|
|
|
%description -n %{allpython}-tqdm-bash-completion
|
2020-11-03 16:09:29 +00:00
|
|
|
tqdm lets you output a progress meter from within loops by wrapping
|
|
|
|
any iterable with "tqdm(iterable)".
|
|
|
|
tqdm's overhead is one order of magnitude less than python-progressbar
|
|
|
|
and does not require ncurses.
|
|
|
|
|
|
|
|
This package provides the completion file for bash
|
|
|
|
|
2016-01-20 20:40:49 +00:00
|
|
|
%prep
|
|
|
|
%setup -q -n tqdm-%{version}
|
2020-11-03 16:09:29 +00:00
|
|
|
# remove bash shebang for completion script
|
|
|
|
sed -i '1 s/^#!.*/# bash completion for tqdm -*- shell-script -*-/' tqdm/completion.sh
|
|
|
|
chmod a-x tqdm/completion.sh
|
2016-01-20 20:40:49 +00:00
|
|
|
|
|
|
|
%build
|
2017-07-07 12:56:37 +00:00
|
|
|
%python_build
|
2016-01-20 20:40:49 +00:00
|
|
|
|
|
|
|
%install
|
2019-02-12 12:10:55 +00:00
|
|
|
%if !%{with test}
|
2017-07-07 12:56:37 +00:00
|
|
|
%python_install
|
|
|
|
%python_clone -a %{buildroot}%{_bindir}/tqdm
|
2020-07-03 08:42:43 +00:00
|
|
|
install -m 644 -D tqdm/completion.sh %{buildroot}%{_datadir}/bash-completion/completions/tqdm
|
2017-10-11 06:59:36 +00:00
|
|
|
%python_expand %fdupes %{buildroot}%{$python_sitelib}
|
2019-02-12 12:10:55 +00:00
|
|
|
%endif
|
2016-09-22 20:54:41 +00:00
|
|
|
|
2019-02-12 12:10:55 +00:00
|
|
|
%if !%{with test}
|
2016-09-22 20:54:41 +00:00
|
|
|
%post
|
2020-11-03 16:09:29 +00:00
|
|
|
%python_install_alternative tqdm
|
2016-09-22 20:54:41 +00:00
|
|
|
|
|
|
|
%postun
|
2017-07-07 12:56:37 +00:00
|
|
|
%python_uninstall_alternative tqdm
|
2019-02-12 12:10:55 +00:00
|
|
|
%endif
|
2016-01-20 20:40:49 +00:00
|
|
|
|
2019-02-09 13:21:50 +00:00
|
|
|
%if %{with test}
|
2019-02-12 12:10:55 +00:00
|
|
|
%check
|
2020-10-23 22:48:31 +00:00
|
|
|
# test_perf: flaky
|
|
|
|
# test_synchronisation: hangs
|
2021-01-13 11:30:12 +00:00
|
|
|
%pytest -k "not (tests_perf or tests_synchronisation)"
|
2019-02-09 13:21:50 +00:00
|
|
|
%endif
|
2016-01-20 20:40:49 +00:00
|
|
|
|
2019-02-12 12:10:55 +00:00
|
|
|
%if !%{with test}
|
2017-07-07 12:56:37 +00:00
|
|
|
%files %{python_files}
|
2018-05-17 19:38:43 +00:00
|
|
|
%doc README.rst logo.png
|
|
|
|
%doc examples/
|
2017-07-07 12:56:37 +00:00
|
|
|
%license LICENCE
|
2020-01-06 14:58:36 +00:00
|
|
|
%{python_sitelib}/tqdm/
|
2020-11-03 16:09:29 +00:00
|
|
|
%{python_sitelib}/tqdm-%{version}*-info
|
2017-07-07 12:56:37 +00:00
|
|
|
%python_alternative %{_bindir}/tqdm
|
2020-11-03 16:09:29 +00:00
|
|
|
|
2021-04-06 08:29:37 +00:00
|
|
|
%files -n %{allpython}-tqdm-bash-completion
|
2020-11-03 16:09:29 +00:00
|
|
|
%license LICENCE
|
2020-07-03 08:42:43 +00:00
|
|
|
%{_datadir}/bash-completion/completions/tqdm
|
2019-02-09 13:21:50 +00:00
|
|
|
%endif
|
2016-01-20 20:40:49 +00:00
|
|
|
|
|
|
|
%changelog
|