From 9d790ec43f7f27a03b5bc3f85392eb0e6c0047cdfc2f57101bb762fbaf89e3b6 Mon Sep 17 00:00:00 2001 From: Matej Cepl Date: Thu, 14 Jul 2022 10:32:41 +0000 Subject: [PATCH] Accepting request 989127 from home:bnavigator:branches:devel:languages:python . OBS-URL: https://build.opensuse.org/request/show/989127 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-validate-pyproject?expand=0&rev=1 --- .gitattributes | 23 +++++++++ .gitignore | 1 + python-validate-pyproject.changes | 4 ++ python-validate-pyproject.spec | 86 +++++++++++++++++++++++++++++++ validate-pyproject-0.9.tar.gz | 3 ++ 5 files changed, 117 insertions(+) create mode 100644 .gitattributes create mode 100644 .gitignore create mode 100644 python-validate-pyproject.changes create mode 100644 python-validate-pyproject.spec create mode 100644 validate-pyproject-0.9.tar.gz diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..9b03811 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,23 @@ +## Default LFS +*.7z filter=lfs diff=lfs merge=lfs -text +*.bsp filter=lfs diff=lfs merge=lfs -text +*.bz2 filter=lfs diff=lfs merge=lfs -text +*.gem filter=lfs diff=lfs merge=lfs -text +*.gz filter=lfs diff=lfs merge=lfs -text +*.jar filter=lfs diff=lfs merge=lfs -text +*.lz filter=lfs diff=lfs merge=lfs -text +*.lzma filter=lfs diff=lfs merge=lfs -text +*.obscpio filter=lfs diff=lfs merge=lfs -text +*.oxt filter=lfs diff=lfs merge=lfs -text +*.pdf filter=lfs diff=lfs merge=lfs -text +*.png filter=lfs diff=lfs merge=lfs -text +*.rpm filter=lfs diff=lfs merge=lfs -text +*.tbz filter=lfs diff=lfs merge=lfs -text +*.tbz2 filter=lfs diff=lfs merge=lfs -text +*.tgz filter=lfs diff=lfs merge=lfs -text +*.ttf filter=lfs diff=lfs merge=lfs -text +*.txz filter=lfs diff=lfs merge=lfs -text +*.whl filter=lfs diff=lfs merge=lfs -text +*.xz filter=lfs diff=lfs merge=lfs -text +*.zip filter=lfs diff=lfs merge=lfs -text +*.zst filter=lfs diff=lfs merge=lfs -text diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..57affb6 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +.osc diff --git a/python-validate-pyproject.changes b/python-validate-pyproject.changes new file mode 100644 index 0000000..2fc53e5 --- /dev/null +++ b/python-validate-pyproject.changes @@ -0,0 +1,4 @@ +------------------------------------------------------------------- +Wed Jul 13 15:53:58 UTC 2022 - Ben Greiner + +- initial specfile for v0.9, required by ini2toml diff --git a/python-validate-pyproject.spec b/python-validate-pyproject.spec new file mode 100644 index 0000000..41a34c2 --- /dev/null +++ b/python-validate-pyproject.spec @@ -0,0 +1,86 @@ +# +# spec file for package python-validate-pyproject +# +# Copyright (c) 2022 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/ +# + + +%{?!python_module:%define python_module() python-%{**} python3-%{**}} +Name: python-validate-pyproject +Version: 0.9 +Release: 0 +Summary: Validation library and CLI tool for checking on 'pyprojecttoml' +License: MPL-2.0 and MIT and BSD-3-Clause +URL: https://github.com/abravalheri/validate-pyproject/ +Source: https://files.pythonhosted.org/packages/source/v/validate-pyproject/validate-pyproject-0.9.tar.gz +BuildRequires: python-rpm-macros +BuildRequires: %{python_module pip} +BuildRequires: %{python_module wheel} +BuildRequires: %{python_module setuptools} +BuildRequires: %{python_module setuptools_scm} +BuildRequires: fdupes +%if 0%{python_version_nodots} < 38 +Requires: python-importlib-metadata +%endif +%if 0%{python_version_nodots} < 37 +Requires: python-importlib-resources +%endif +Requires(post): update-alternatives +Requires(postun):update-alternatives +Provides: python-validate_pyproject = %{version}-%{release} +# SECTION test +BuildRequires: %{python_module pytest} +BuildRequires: %{python_module tomli >= 1.2.1 if %python-base < 3.11} +BuildRequires: %{python_module packaging >= 20.4} +BuildRequires: %{python_module trove-classifiers >= 2021.10.20} +BuildRequires: %{python_module importlib-metadata if %python-base < 3.8} +BuildRequires: %{python_module importlib-resources if %python-base < 3.7} +# /SECTION +BuildArch: noarch +%python_subpackages + +%description +Validation library and CLI tool for checking on 'pyproject.toml' files using JSON Schema + +%prep +%setup -q -n validate-pyproject-%{version} +sed -i '/--cov/d' setup.cfg + +%build +# have to use PEP517: gh#abravalheri/validate-pyproject#52 +%pyproject_wheel + +%install +%pyproject_install +%python_clone -a %{buildroot}%{_bindir}/validate-pyproject +%python_expand %fdupes %{buildroot}%{$python_sitelib} + +%check +%pytest -k "not downloaded" + +%post +%python_install_alternative validate-pyproject + +%postun +%python_uninstall_alternative validate-pyproject + + +%files %{python_files} +%doc AUTHORS.rst CHANGELOG.rst README.rst +%license LICENSE.txt +%python_alternative %{_bindir}/validate-pyproject +%{python_sitelib}/validate_pyproject +%{python_sitelib}/validate_pyproject-%{version}*-info + +%changelog diff --git a/validate-pyproject-0.9.tar.gz b/validate-pyproject-0.9.tar.gz new file mode 100644 index 0000000..9825599 --- /dev/null +++ b/validate-pyproject-0.9.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d7f0bf7270534499ff960e02c120b8731a153e02bdf51b9a580cbf17317bc414 +size 105047