!8 Init package python-asttokens
From: @li_zengyi Reviewed-by: @zhunaipan, @nicholas_yhr Signed-off-by: @zhunaipan
This commit is contained in:
commit
a81a556faa
24
0001-patch-for-openeuler.patch
Normal file
24
0001-patch-for-openeuler.patch
Normal file
@ -0,0 +1,24 @@
|
||||
diff --git a/pyproject.toml b/pyproject.toml
|
||||
index 2543e24..a633f94 100644
|
||||
--- a/pyproject.toml
|
||||
+++ b/pyproject.toml
|
||||
@@ -1,5 +1,5 @@
|
||||
[build-system]
|
||||
-requires = ["setuptools>=44", "wheel", "setuptools_scm[toml]>=3.4.3"]
|
||||
+requires = ["setuptools>=44", "wheel", "setuptools_scm[toml]>=3.4.1"]
|
||||
build-backend = "setuptools.build_meta"
|
||||
|
||||
[tool.setuptools_scm]
|
||||
diff --git a/setup.cfg b/setup.cfg
|
||||
index 9dc3a9c..b59a55d 100644
|
||||
--- a/setup.cfg
|
||||
+++ b/setup.cfg
|
||||
@@ -37,7 +37,7 @@ packages = asttokens
|
||||
install_requires =
|
||||
six
|
||||
typing; python_version < "3.5"
|
||||
-setup_requires = setuptools>=44; setuptools_scm[toml]>=3.4.3
|
||||
+setup_requires = setuptools>=44; setuptools_scm[toml]>=3.4.1
|
||||
|
||||
[options.extras_require]
|
||||
test = astroid; pytest
|
||||
BIN
python-asttokens-2.2.1.tar.gz
Normal file
BIN
python-asttokens-2.2.1.tar.gz
Normal file
Binary file not shown.
63
python-asttokens.spec
Normal file
63
python-asttokens.spec
Normal file
@ -0,0 +1,63 @@
|
||||
Name: python-asttokens
|
||||
Version: 2.2.1
|
||||
Release: 1%{?dist}
|
||||
Summary: Module to annotate Python abstract syntax trees with source code positions
|
||||
|
||||
License: Apache-2.0
|
||||
URL: https://pypi.python.org/pypi/asttokens/
|
||||
Source0: %{name}-%{version}.tar.gz
|
||||
|
||||
Patch0: 0001-patch-for-openeuler.patch
|
||||
|
||||
BuildArch: noarch
|
||||
BuildRequires: python3-devel
|
||||
BuildRequires: python3-setuptools
|
||||
BuildRequires: python3-setuptools_scm
|
||||
BuildRequires: python3-wheel
|
||||
BuildRequires: python3-toml
|
||||
BuildRequires: python3-pytest
|
||||
BuildRequires: python3-astroid
|
||||
BuildRequires: python3-six
|
||||
BuildRequires: python3-typing-extensions
|
||||
|
||||
%global _description %{expand:
|
||||
The asttokens module annotates Python abstract syntax trees (ASTs)
|
||||
with the positions of tokens and text in the source code that
|
||||
generated them. This makes it possible for tools that work with
|
||||
logical AST nodes to find the particular text that resulted in those
|
||||
nodes, for example for automated refactoring or highlighting.}
|
||||
|
||||
%description %_description
|
||||
|
||||
|
||||
%package -n python3-asttokens
|
||||
Summary: %{summary}
|
||||
Requires: python3dist(six)
|
||||
%{?python_provide:%python_provide python3-asttokens}
|
||||
|
||||
%description -n python3-asttokens %_description
|
||||
|
||||
|
||||
%prep
|
||||
%autosetup -p1 -n asttokens-%{version}
|
||||
|
||||
|
||||
%build
|
||||
%py3_build
|
||||
|
||||
|
||||
%install
|
||||
%py3_install
|
||||
|
||||
%check
|
||||
pytest-3 tests/ -v --ignore=tests/testdata/
|
||||
|
||||
%files -n python3-asttokens
|
||||
%license LICENSE
|
||||
%doc README.rst
|
||||
%{python3_sitelib}/*
|
||||
|
||||
|
||||
%changelog
|
||||
* Wed Mar 29 2023 li_zengyi <zengyi@isrc.iscas.ac.cn> - 2.2.1-1
|
||||
- Init asttokens 2.2.1 package
|
||||
4
python-asttokens.yaml
Normal file
4
python-asttokens.yaml
Normal file
@ -0,0 +1,4 @@
|
||||
version_control: pypi
|
||||
src_repo: asttokens
|
||||
tag_prefix:
|
||||
seperator: .
|
||||
Loading…
x
Reference in New Issue
Block a user