commit e8b79801fa1a3ba9749a625bcfffc24dc7c9732b Author: Adrian Schröter Date: Fri Jul 12 12:20:40 2024 +0200 Sync from SUSE:ALP:Source:Standard:1.0 saltbundlepy-looseversion revision 39a68ceea7354fe99daf75c6d1ef1810 diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..fecc750 --- /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/1.0.2.tar.gz b/1.0.2.tar.gz new file mode 100644 index 0000000..4f9bfaf --- /dev/null +++ b/1.0.2.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:27825aabe854f497c583ddb1f72d1e0b562144f1de75cb648c6493532cd823c1 +size 8144 diff --git a/add_compatible_setup_py_file.patch b/add_compatible_setup_py_file.patch new file mode 100644 index 0000000..2600ab5 --- /dev/null +++ b/add_compatible_setup_py_file.patch @@ -0,0 +1,8 @@ +Index: looseversion-1.0.2/setup.py +=================================================================== +--- /dev/null ++++ looseversion-1.0.2/setup.py +@@ -0,0 +1,3 @@ ++from setuptools import setup ++ ++setup() diff --git a/rpmlintrc b/rpmlintrc new file mode 100644 index 0000000..94e14ab --- /dev/null +++ b/rpmlintrc @@ -0,0 +1 @@ +setBadness('invalid-license', 0) diff --git a/saltbundlepy-looseversion.changes b/saltbundlepy-looseversion.changes new file mode 100644 index 0000000..95b4150 --- /dev/null +++ b/saltbundlepy-looseversion.changes @@ -0,0 +1,17 @@ +------------------------------------------------------------------- +Wed Mar 22 15:30:57 UTC 2023 - Pablo Suárez Hernández + +- Strictly require Python 3.10 with saltbundlepy requirement + +------------------------------------------------------------------- +Wed Mar 22 10:23:09 UTC 2023 - Pablo Suárez Hernández + +- Fix package build with old setuptools versions + +- Added: + * add_compatible_setup_py_file.patch + +------------------------------------------------------------------- +Mon Mar 20 12:03:11 UTC 2023 - Pablo Suárez Hernández + +- Initial package: looseversion 1.0.2 diff --git a/saltbundlepy-looseversion.spec b/saltbundlepy-looseversion.spec new file mode 100644 index 0000000..774ef35 --- /dev/null +++ b/saltbundlepy-looseversion.spec @@ -0,0 +1,77 @@ +# +# spec file for package saltbundlepy-looseversion +# +# Copyright (c) 2023 SUSE LINUX GmbH, Nuernberg, Germany. +# +# 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 http://bugs.opensuse.org/ +# + +%{?!saltbundlepy_module:%define saltbundlepy_module() saltbundlepy-%{**}} +%define pythons saltbundlepy + +# Disable python bytecompile for all distros +# It's called explicitly in the spec +%global __brp_python_bytecompile %{nil} + +%{?!pytest:%define pytest pytest} +%define skip_python2 1 + +Name: saltbundlepy-looseversion +Version: 1.0.2 +Release: 0 +Summary: A backwards/forwards-compatible fork of distutils.version.LooseVersion +License: PSF-2.0 +Group: Development/Languages/Python +Url: https://github.com/effigies/looseversion +Source: https://github.com/effigies/looseversion/archive/refs/tags/%{version}.tar.gz +Patch0: add_compatible_setup_py_file.patch +BuildRequires: %{saltbundlepy_module devel >= 3.10} +BuildRequires: %{saltbundlepy_module base >= 3.10} +BuildRequires: %{saltbundlepy_module pip} +BuildRequires: %{saltbundlepy_module pytest} +BuildRequires: %{saltbundlepy_module setuptools} +BuildRequires: fdupes +BuildRequires: saltbundlepy-rpm-macros +BuildArch: noarch + +%python_subpackages + +%description +A backwards/forwards-compatible fork of distutils.version.LooseVersion, for times when PEP-440 isn't what you need. + +The goal of this package is to be a drop-in replacement for the original LooseVersion. It implements an identical interface and comparison logic to LooseVersion. The only major change is that a looseversion.LooseVersion is comparable to a distutils.version.LooseVersion, which means tools should not need to worry whether all dependencies that use LooseVersion have migrated. + +If you are simply comparing versions of Python packages, consider moving to packaging.version.Version, which follows PEP-440. LooseVersion is better suited to interacting with heterogeneous version schemes that do not follow PEP-440. + +%prep +%setup -q -n looseversion-%{version} +%autopatch -p1 + +%build +%python_build + +%install +%python_install +%python_expand %fdupes %{buildroot}%{$python_sitelib} + +%check +%pytest -v tests.py + +%files %{python_files} +%license LICENSE +%doc README.md +%{python_sitelib}/looseversion.py +%{python_sitelib}/looseversion-* +%pycache_only %{python_sitelib}/__pycache__ + +%changelog +