forked from pool/python-jsonpath-ng
- update to 1.7.0:
* Allow raw numeric values to be used as keys
* Add `wherenot`
* Added EZRegex pattern for the split extension regex
* Added negative and * indecies and quotes to `Split`
parameters
* Typo: duplicate line removed.
* Added `path` extension that exposes datum's path from the
jsonpath expression itself.
* Remove Python 3.7 support
* Only construct the parse table once
* updated test for `jsonpath.py` changes
* fix for Updating a json object fails if the value of a key is
boolean #73
* Add Codespaces configuration
* Add `.editorconfig`
* Fix a GitHub workflow schema issue
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-jsonpath-ng?expand=0&rev=10
This commit is contained in:
78
python-jsonpath-ng.spec
Normal file
78
python-jsonpath-ng.spec
Normal file
@@ -0,0 +1,78 @@
|
||||
#
|
||||
# spec file for package python-jsonpath-ng
|
||||
#
|
||||
# Copyright (c) 2024 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-jsonpath-ng
|
||||
Version: 1.7.0
|
||||
Release: 0
|
||||
Summary: JSONPath for Python
|
||||
License: Apache-2.0
|
||||
Group: Development/Languages/Python
|
||||
URL: https://github.com/h2non/jsonpath-ng
|
||||
Source: https://github.com/h2non/jsonpath-ng/archive/refs/tags/v%{version}.tar.gz#/jsonpath-ng-%{version}.tar.gz
|
||||
BuildRequires: %{python_module pip}
|
||||
BuildRequires: %{python_module setuptools}
|
||||
BuildRequires: %{python_module wheel}
|
||||
BuildRequires: fdupes
|
||||
BuildRequires: python-rpm-macros
|
||||
Requires: python-decorator
|
||||
Requires: python-ply
|
||||
Requires(post): update-alternatives
|
||||
Requires(postun): update-alternatives
|
||||
BuildArch: noarch
|
||||
# SECTION test requirements
|
||||
BuildRequires: %{python_module ply}
|
||||
#
|
||||
BuildRequires: %{python_module pytest}
|
||||
# /SECTION
|
||||
%python_subpackages
|
||||
|
||||
%description
|
||||
A final implementation of JSONPath for Python that aims to be
|
||||
standard compliant, including arithmetic and binary comparison
|
||||
operators and providing clear AST for metaprogramming.
|
||||
|
||||
%prep
|
||||
%setup -q -n jsonpath-ng-%{version}
|
||||
sed -i '1{/^#!/d}' jsonpath_ng/bin/jsonpath.py
|
||||
|
||||
%build
|
||||
%pyproject_wheel
|
||||
|
||||
%install
|
||||
%pyproject_install
|
||||
%python_clone -a %{buildroot}%{_bindir}/jsonpath_ng
|
||||
%python_expand %fdupes %{buildroot}%{$python_sitelib}
|
||||
|
||||
%post
|
||||
%python_install_alternative jsonpath_ng
|
||||
|
||||
%postun
|
||||
%python_uninstall_alternative jsonpath_ng
|
||||
|
||||
%check
|
||||
%pytest
|
||||
|
||||
%files %{python_files}
|
||||
%license LICENSE
|
||||
%doc README.rst History.md
|
||||
%python_alternative %{_bindir}/jsonpath_ng
|
||||
%{python_sitelib}/jsonpath_ng
|
||||
%{python_sitelib}/jsonpath_ng-%{version}.dist-info
|
||||
|
||||
%changelog
|
||||
Reference in New Issue
Block a user