15
0
Files
python-click-man/python-click-man.spec
Markéta Machová 5a51ab118c Accepting request 1244814 from home:glaubitz:branches:devel:languages:python
- Update to 0.5.0
  * Fix typo
  * Explicitly require setuptools, __main__.py imports pkg_resources
  * Fix typos
  * Update README.md
  * Fix typo
  * tests: Switch to pytest
  * Add GitHub Actions workflow, remove Travis
  * Fix man generation for CLI with hidden options
  * Move 'cli()' method to 'click_man.shell'
  * Add shell unit tests
  * cli: Expose knobs for date and version
  * README: Remove references to distutils command
  * Remove distutils command
  * Remove use of pkg_resources
  * Drop support for Python < 3.9
  * Add ruff configuration
  * Format with ruff-format
  * Add pre-commit
  * Add lint CI job
  * Migrate to pyproject.toml
- from version 0.4.2
  * get_short_help method only exists in Click 7.
- Add update-alternatives to Requires(post) and Requires(postun)
- Drop get-short-help.patch, merged upstream
- Limit Python files matched in %files section
- Switch package to modern Python Stack on SLE-15
  * Use Python 3.11 on SLE-15 by default
  * Drop support for older Python versions
- Switch build system from setuptools to pyproject.toml

OBS-URL: https://build.opensuse.org/request/show/1244814
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-click-man?expand=0&rev=9
2025-02-11 09:08:29 +00:00

75 lines
2.1 KiB
RPMSpec

#
# spec file for package python-click-man
#
# Copyright (c) 2025 SUSE LLC
#
# 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.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%{?sle15_python_module_pythons}
Name: python-click-man
Version: 0.5.0
Release: 0
Summary: Automate generation of man pages for python click applications
License: MIT
URL: https://github.com/click-contrib/click-man
Source: https://files.pythonhosted.org/packages/source/c/click_man/click_man-%{version}.tar.gz
BuildRequires: %{python_module click}
BuildRequires: %{python_module pip}
BuildRequires: %{python_module pytest}
BuildRequires: %{python_module setuptools}
BuildRequires: %{python_module sure}
BuildRequires: %{python_module wheel}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
Requires: python-click
Requires(post): update-alternatives
Requires(postun): update-alternatives
BuildArch: noarch
%python_subpackages
%description
Automate generation of man pages for Python Click applications.
%prep
%autosetup -p1 -n click_man-%{version}
%build
export LANG=en_US.UTF-8
%pyproject_wheel
%install
export LANG=en_US.UTF-8
%pyproject_install
%python_expand %fdupes %{buildroot}%{$python_sitelib}
%python_clone -a %{buildroot}%{_bindir}/click-man
%check
export LANG=en_US.UTF-8
%pytest
%post
%python_install_alternative click-man
%postun
%python_uninstall_alternative click-man
%files %{python_files}
%license LICENSE
%doc CHANGELOG.md README.md
%python_alternative %{_bindir}/click-man
%{python_sitelib}/click_man
%{python_sitelib}/click_man-%{version}.dist-info
%changelog