From 2253278a210ab6cdc210e5236090cd20aaeabc2f Mon Sep 17 00:00:00 2001 From: CoprDistGit Date: Tue, 11 Apr 2023 22:29:23 +0000 Subject: automatic import of python-dephell-pythons --- .gitignore | 1 + python-dephell-pythons.spec | 261 ++++++++++++++++++++++++++++++++++++++++++++ sources | 1 + 3 files changed, 263 insertions(+) create mode 100644 python-dephell-pythons.spec create mode 100644 sources diff --git a/.gitignore b/.gitignore index e69de29..d4b4ae7 100644 --- a/.gitignore +++ b/.gitignore @@ -0,0 +1 @@ +/dephell_pythons-0.1.15.tar.gz diff --git a/python-dephell-pythons.spec b/python-dephell-pythons.spec new file mode 100644 index 0000000..fd78ac6 --- /dev/null +++ b/python-dephell-pythons.spec @@ -0,0 +1,261 @@ +%global _empty_manifest_terminate_build 0 +Name: python-dephell-pythons +Version: 0.1.15 +Release: 1 +Summary: Work with python versions +License: MIT +URL: https://pypi.org/project/dephell-pythons/ +Source0: https://mirrors.nju.edu.cn/pypi/web/packages/6d/fa/d0a59abf5b4b30445efb13ea3168a0f2b0371f156adcc17d80bacceb9c10/dephell_pythons-0.1.15.tar.gz +BuildArch: noarch + +Requires: python3-attrs +Requires: python3-dephell-specifier +Requires: python3-packaging + +%description +# Dephell Pythons + + +[![travis](https://travis-ci.org/dephell/dephell_pythons.svg?branch=master)](https://travis-ci.org/dephell/dephell_pythons) +[![appveyor](https://ci.appveyor.com/api/projects/status/github/dephell/dephell_pythons?svg=true)](https://ci.appveyor.com/project/orsinium/dephell-pythons) +[![MIT License](https://img.shields.io/pypi/l/dephell-pythons.svg)](https://github.com/dephell/dephell_pythons/blob/master/LICENSE) + +Work with python versions. + +## Installation + +Install from [PyPI](https://pypi.org/project/dephell-pythons/): + +```bash +python3 -m pip install --user dephell_pythons +``` + +## Usage + +```python +from dephell_pythons import Pythons + +pythons = Pythons() + +# get current: +python = pythons.get_best() + +# properties: +python.name # 'python3.7' +python.path # Path('/usr/local/bin/python3.7') +python.version # + +python.lib_paths +# [Path('/usr/local/lib/python37.zip'), Path('/usr/local/lib/python3.7'), ...] + +python.lib_path +# Path('/home/gram/.local/lib/python3.7/site-packages') + +# get by version +pythons.get_best('3.5').version +# + +# get by name +pythons.get_best('python3').version +# + +# get by specifier +pythons.get_best('<3.7').version +# + +# get by path +pythons.get_best('/usr/bin/python3.6').version +# + +# get all +list(pythons) +# [Python(...), Python(...), ...] + +# work not only with installed pythons: +Pythons(abstract=True).get_best('>=2.8,<3.5').version +# +``` + + +%package -n python3-dephell-pythons +Summary: Work with python versions +Provides: python-dephell-pythons +BuildRequires: python3-devel +BuildRequires: python3-setuptools +BuildRequires: python3-pip +%description -n python3-dephell-pythons +# Dephell Pythons + + +[![travis](https://travis-ci.org/dephell/dephell_pythons.svg?branch=master)](https://travis-ci.org/dephell/dephell_pythons) +[![appveyor](https://ci.appveyor.com/api/projects/status/github/dephell/dephell_pythons?svg=true)](https://ci.appveyor.com/project/orsinium/dephell-pythons) +[![MIT License](https://img.shields.io/pypi/l/dephell-pythons.svg)](https://github.com/dephell/dephell_pythons/blob/master/LICENSE) + +Work with python versions. + +## Installation + +Install from [PyPI](https://pypi.org/project/dephell-pythons/): + +```bash +python3 -m pip install --user dephell_pythons +``` + +## Usage + +```python +from dephell_pythons import Pythons + +pythons = Pythons() + +# get current: +python = pythons.get_best() + +# properties: +python.name # 'python3.7' +python.path # Path('/usr/local/bin/python3.7') +python.version # + +python.lib_paths +# [Path('/usr/local/lib/python37.zip'), Path('/usr/local/lib/python3.7'), ...] + +python.lib_path +# Path('/home/gram/.local/lib/python3.7/site-packages') + +# get by version +pythons.get_best('3.5').version +# + +# get by name +pythons.get_best('python3').version +# + +# get by specifier +pythons.get_best('<3.7').version +# + +# get by path +pythons.get_best('/usr/bin/python3.6').version +# + +# get all +list(pythons) +# [Python(...), Python(...), ...] + +# work not only with installed pythons: +Pythons(abstract=True).get_best('>=2.8,<3.5').version +# +``` + + +%package help +Summary: Development documents and examples for dephell-pythons +Provides: python3-dephell-pythons-doc +%description help +# Dephell Pythons + + +[![travis](https://travis-ci.org/dephell/dephell_pythons.svg?branch=master)](https://travis-ci.org/dephell/dephell_pythons) +[![appveyor](https://ci.appveyor.com/api/projects/status/github/dephell/dephell_pythons?svg=true)](https://ci.appveyor.com/project/orsinium/dephell-pythons) +[![MIT License](https://img.shields.io/pypi/l/dephell-pythons.svg)](https://github.com/dephell/dephell_pythons/blob/master/LICENSE) + +Work with python versions. + +## Installation + +Install from [PyPI](https://pypi.org/project/dephell-pythons/): + +```bash +python3 -m pip install --user dephell_pythons +``` + +## Usage + +```python +from dephell_pythons import Pythons + +pythons = Pythons() + +# get current: +python = pythons.get_best() + +# properties: +python.name # 'python3.7' +python.path # Path('/usr/local/bin/python3.7') +python.version # + +python.lib_paths +# [Path('/usr/local/lib/python37.zip'), Path('/usr/local/lib/python3.7'), ...] + +python.lib_path +# Path('/home/gram/.local/lib/python3.7/site-packages') + +# get by version +pythons.get_best('3.5').version +# + +# get by name +pythons.get_best('python3').version +# + +# get by specifier +pythons.get_best('<3.7').version +# + +# get by path +pythons.get_best('/usr/bin/python3.6').version +# + +# get all +list(pythons) +# [Python(...), Python(...), ...] + +# work not only with installed pythons: +Pythons(abstract=True).get_best('>=2.8,<3.5').version +# +``` + + +%prep +%autosetup -n dephell-pythons-0.1.15 + +%build +%py3_build + +%install +%py3_install +install -d -m755 %{buildroot}/%{_pkgdocdir} +if [ -d doc ]; then cp -arf doc %{buildroot}/%{_pkgdocdir}; fi +if [ -d docs ]; then cp -arf docs %{buildroot}/%{_pkgdocdir}; fi +if [ -d example ]; then cp -arf example %{buildroot}/%{_pkgdocdir}; fi +if [ -d examples ]; then cp -arf examples %{buildroot}/%{_pkgdocdir}; fi +pushd %{buildroot} +if [ -d usr/lib ]; then + find usr/lib -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/lib64 ]; then + find usr/lib64 -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/bin ]; then + find usr/bin -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/sbin ]; then + find usr/sbin -type f -printf "/%h/%f\n" >> filelist.lst +fi +touch doclist.lst +if [ -d usr/share/man ]; then + find usr/share/man -type f -printf "/%h/%f.gz\n" >> doclist.lst +fi +popd +mv %{buildroot}/filelist.lst . +mv %{buildroot}/doclist.lst . + +%files -n python3-dephell-pythons -f filelist.lst +%dir %{python3_sitelib}/* + +%files help -f doclist.lst +%{_docdir}/* + +%changelog +* Tue Apr 11 2023 Python_Bot - 0.1.15-1 +- Package Spec generated diff --git a/sources b/sources new file mode 100644 index 0000000..6409812 --- /dev/null +++ b/sources @@ -0,0 +1 @@ +28de153d24f1e65bbaf5ab97e12082e4 dephell_pythons-0.1.15.tar.gz -- cgit v1.2.3