- Use %pyproject macros
- Skip failing test TestCli.test_no_arguments - Use libalternatives instead of update-alternatives OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-anymarkup?expand=0&rev=2
This commit is contained in:
@@ -1,3 +1,10 @@
|
||||
-------------------------------------------------------------------
|
||||
Mon May 12 10:33:47 UTC 2025 - Daniel Garcia <daniel.garcia@suse.com>
|
||||
|
||||
- Use %pyproject macros
|
||||
- Skip failing test TestCli.test_no_arguments
|
||||
- Use libalternatives instead of update-alternatives
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Jan 20 16:08:55 UTC 2021 - John Vandenberg <jayvdb@gmail.com>
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
#
|
||||
# spec file for package python-anymarkup
|
||||
#
|
||||
# Copyright (c) 2021 SUSE LLC
|
||||
# Copyright (c) 2025 SUSE LLC
|
||||
# Copyright (c) 2020 SUSE Software Solutions Germany GmbH.
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
@@ -17,7 +17,12 @@
|
||||
#
|
||||
|
||||
|
||||
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
||||
%if 0%{?suse_version} > 1500
|
||||
%bcond_without libalternatives
|
||||
%else
|
||||
%bcond_with libalternatives
|
||||
%endif
|
||||
|
||||
Name: python-anymarkup
|
||||
Version: 0.8.1
|
||||
Release: 0
|
||||
@@ -26,7 +31,9 @@ License: BSD-3-Clause
|
||||
Group: Development/Languages/Python
|
||||
URL: https://github.com/bkabrda/anymarkup
|
||||
Source0: https://github.com/bkabrda/anymarkup/archive/v%{version}/anymarkup-%{version}.tar.gz
|
||||
BuildRequires: %{python_module pip}
|
||||
BuildRequires: %{python_module setuptools}
|
||||
BuildRequires: %{python_module wheel}
|
||||
BuildRequires: fdupes
|
||||
BuildRequires: python-rpm-macros
|
||||
Suggests: python-click
|
||||
@@ -41,6 +48,22 @@ BuildRequires: %{python_module pytest}
|
||||
BuildRequires: %{python_module toml}
|
||||
BuildRequires: %{python_module xmltodict}
|
||||
# /SECTION
|
||||
Requires: python-anymarkup-core
|
||||
Requires: python-PyYAML
|
||||
Requires: python-click
|
||||
Requires: python-configobj
|
||||
Requires: python-json5
|
||||
Requires: python-toml
|
||||
Requires: python-xmltodict
|
||||
|
||||
%if %{with libalternatives}
|
||||
BuildRequires: alts
|
||||
Requires: alts
|
||||
%else
|
||||
Requires(post): update-alternatives
|
||||
Requires(postun): update-alternatives
|
||||
%endif
|
||||
|
||||
%python_subpackages
|
||||
|
||||
%description
|
||||
@@ -48,18 +71,23 @@ Parse or serialize any markup. Currently supports ini, json, json5, toml,
|
||||
xml and yaml.
|
||||
|
||||
%prep
|
||||
%setup -q -n anymarkup-%{version}
|
||||
%autosetup -p1 -n anymarkup-%{version}
|
||||
|
||||
%build
|
||||
%python_build
|
||||
%pyproject_wheel
|
||||
|
||||
%install
|
||||
%python_install
|
||||
%pyproject_install
|
||||
%python_clone -a %{buildroot}%{_bindir}/anymarkup
|
||||
%python_expand %fdupes %{buildroot}%{$python_sitelib}
|
||||
|
||||
%check
|
||||
%pytest
|
||||
donttest="test_no_arguments"
|
||||
%pytest -k "not ($donttest)"
|
||||
|
||||
%pre
|
||||
# If libalternatives is used: Removing old update-alternatives entries.
|
||||
%python_libalternatives_reset_alternative anymarkup
|
||||
|
||||
%post
|
||||
%python_install_alternative anymarkup
|
||||
@@ -71,6 +99,7 @@ xml and yaml.
|
||||
%doc README.rst
|
||||
%license LICENSE
|
||||
%python_alternative %{_bindir}/anymarkup
|
||||
%{python_sitelib}/*
|
||||
%{python_sitelib}/anymarkup
|
||||
%{python_sitelib}/anymarkup*-info
|
||||
|
||||
%changelog
|
||||
|
||||
Reference in New Issue
Block a user