blob: 9048de0e68d592f2fa0a0caee66ba37f3fa02132 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
|
%global _empty_manifest_terminate_build 0
%global pypi_name black
Name: python-%{pypi_name}
Version: 22.8.0
Release: 2
Summary: The uncompromising code formatter
License: MIT
URL: https://github.com/psf/black
Source0: https://files.pythonhosted.org/packages/3a/1b/38a013f75022fae724ed766fdac5f6777544c45eecbe00a6d8fd91a2a26b/black-22.8.0.tar.gz
BuildArch: noarch
# Patch0: CVE-2024-21503.patch
BuildRequires: python3-devel
# Base build requires
BuildRequires: python3-setuptools
BuildRequires: python3-setuptools_scm
BuildRequires: python3-pip
BuildRequires: python3-wheel
BuildRequires: python3-hatch-vcs
BuildRequires: python3-hatchling
BuildRequires: python3-hatch-fancy-pypi-readme
%global _description %{expand:
Black is the uncompromising Python code formatter. By using it, you agree to
cease control over minutiae of hand-formatting. In return, Black gives you
speed, determinism, and freedom from pycodestyle nagging about formatting.
You will save time and mental energy for more important matters.}
%description %_description
%package -n python3-%{pypi_name}
Summary: %{summary}
%{?python_provide:%python_provide python3-%{pypi_name}}
%description -n python3-%{pypi_name} %_description
%prep
%autosetup -p1 -n %{pypi_name}-%{version}
%build
%pyproject_build
%install
%pyproject_install
for exe in black blackd; do
ln -sr %{buildroot}%{_bindir}/${exe}{,-%{python3_version}}
done
%files -n python3-%{pypi_name}
%license LICENSE
%doc README.md
%{_bindir}/black
%{_bindir}/black-%{python3_version}
%{_bindir}/blackd
%{_bindir}/blackd-%{python3_version}
%{python3_sitelib}/_black_version.py
%{python3_sitelib}/__pycache__/*
%{python3_sitelib}/black*
%{python3_sitelib}/blib2to3/*
%changelog
* Fri Feb 23 2024 chendexi <chendexi@kylinos.cn> - 22.8.0-1
- init package to version 22.8.0
|