diff options
| -rw-r--r-- | .gitignore | 1 | ||||
| -rw-r--r-- | python-setupextras.spec | 423 | ||||
| -rw-r--r-- | sources | 1 |
3 files changed, 425 insertions, 0 deletions
@@ -0,0 +1 @@ +/setupextras-0.1.5.tar.gz diff --git a/python-setupextras.spec b/python-setupextras.spec new file mode 100644 index 0000000..f9c2c06 --- /dev/null +++ b/python-setupextras.spec @@ -0,0 +1,423 @@ +%global _empty_manifest_terminate_build 0 +Name: python-setupextras +Version: 0.1.5 +Release: 1 +Summary: Additional common `setuptools` helpers - for Python. +License: MIT +URL: https://github.com/grimen/python-setupextras +Source0: https://mirrors.nju.edu.cn/pypi/web/packages/2b/fc/e84b4f4ef49f669585ea8682899eead0406a688bf4d12d86c4da93d6aa8d/setupextras-0.1.5.tar.gz +BuildArch: noarch + +Requires: python3-six +Requires: python3-rootpath +Requires: python3-inspecta +Requires: python3-setuptools +Requires: python3-colour-runner +Requires: python3-deepdiff +Requires: python3-tox +Requires: python3-coverage +Requires: python3-codecov + +%description + +# `setupextras` [](https://badge.fury.io/py/setupextras) [](https://travis-ci.com/grimen/python-setupextras) [](https://codecov.io/gh/grimen/python-setupextras) + +*Additional common `setuptools` helpers - for Python.* + +## Introduction + +TODO + + +## Install + +Install using **pip**: + +```sh +$ pip install setupextras +``` + + +## Use + +Very basic **[example](https://github.com/grimen/python-setupextras/tree/master/examples/basic.py)**: + +```python +# ========================================= +# IMPORTS +# -------------------------------------- + +import os +import json +import setuptools + +import setupextras + + +# ========================================= +# PACKAGE +# -------------------------------------- + +name = 'foo' +version = '1.0.0' +description = 'A foo library.' +keywords = [ + 'foo', + 'bar', +] + +packages = setupextras.get_packages() +data_files = setupextras.get_data_files(['*.*'], os.path.join(name, 'tests', '__fixtures__')) +requirements = setupextras.get_requirements() +readme = setupextras.get_readme() + +config = { + 'name': name, + 'version': version, + 'description': (description), + 'keywords': keywords, + 'author': 'Jonas Grimfelt', + 'author_email': 'grimen@gmail.com', + 'url': 'https://github.com/grimen/python-{name}'.format(name = name), + 'download_url': 'https://github.com/grimen/python-{name}'.format(name = name), + 'project_urls': { + 'repository': 'https://github.com/grimen/python-{name}'.format(name = name), + 'bugs': 'https://github.com/grimen/python-{name}/issues'.format(name = name), + }, + 'license': 'MIT', + 'long_description': readme, + 'packages': packages, + 'data_files': data_files, + 'install_requires': requirements, +} + +print('CONFIG {0}'.format(json.dumps(config, indent = 4))) + + +# ========================================= +# MAIN +# -------------------------------------- + +setuptools.setup(**config) +``` + + +## Test + +Clone down source code: + +```sh +$ make install +``` + +Run **colorful tests**, with only native environment (dependency sandboxing up to you): + +```sh +$ make test +``` + +Run **less colorful tests**, with **multi-environment** (using **tox**): + +```sh +$ make test-tox +``` + + +## About + +This project was mainly initiated - in lack of solid existing alternatives - to be used at our work at **[Markable.ai](https://markable.ai)** to have common code conventions between various programming environments where **Python** (research, CV, AI) is heavily used. + + +## License + +Released under the MIT license. + + + + +%package -n python3-setupextras +Summary: Additional common `setuptools` helpers - for Python. +Provides: python-setupextras +BuildRequires: python3-devel +BuildRequires: python3-setuptools +BuildRequires: python3-pip +%description -n python3-setupextras + +# `setupextras` [](https://badge.fury.io/py/setupextras) [](https://travis-ci.com/grimen/python-setupextras) [](https://codecov.io/gh/grimen/python-setupextras) + +*Additional common `setuptools` helpers - for Python.* + +## Introduction + +TODO + + +## Install + +Install using **pip**: + +```sh +$ pip install setupextras +``` + + +## Use + +Very basic **[example](https://github.com/grimen/python-setupextras/tree/master/examples/basic.py)**: + +```python +# ========================================= +# IMPORTS +# -------------------------------------- + +import os +import json +import setuptools + +import setupextras + + +# ========================================= +# PACKAGE +# -------------------------------------- + +name = 'foo' +version = '1.0.0' +description = 'A foo library.' +keywords = [ + 'foo', + 'bar', +] + +packages = setupextras.get_packages() +data_files = setupextras.get_data_files(['*.*'], os.path.join(name, 'tests', '__fixtures__')) +requirements = setupextras.get_requirements() +readme = setupextras.get_readme() + +config = { + 'name': name, + 'version': version, + 'description': (description), + 'keywords': keywords, + 'author': 'Jonas Grimfelt', + 'author_email': 'grimen@gmail.com', + 'url': 'https://github.com/grimen/python-{name}'.format(name = name), + 'download_url': 'https://github.com/grimen/python-{name}'.format(name = name), + 'project_urls': { + 'repository': 'https://github.com/grimen/python-{name}'.format(name = name), + 'bugs': 'https://github.com/grimen/python-{name}/issues'.format(name = name), + }, + 'license': 'MIT', + 'long_description': readme, + 'packages': packages, + 'data_files': data_files, + 'install_requires': requirements, +} + +print('CONFIG {0}'.format(json.dumps(config, indent = 4))) + + +# ========================================= +# MAIN +# -------------------------------------- + +setuptools.setup(**config) +``` + + +## Test + +Clone down source code: + +```sh +$ make install +``` + +Run **colorful tests**, with only native environment (dependency sandboxing up to you): + +```sh +$ make test +``` + +Run **less colorful tests**, with **multi-environment** (using **tox**): + +```sh +$ make test-tox +``` + + +## About + +This project was mainly initiated - in lack of solid existing alternatives - to be used at our work at **[Markable.ai](https://markable.ai)** to have common code conventions between various programming environments where **Python** (research, CV, AI) is heavily used. + + +## License + +Released under the MIT license. + + + + +%package help +Summary: Development documents and examples for setupextras +Provides: python3-setupextras-doc +%description help + +# `setupextras` [](https://badge.fury.io/py/setupextras) [](https://travis-ci.com/grimen/python-setupextras) [](https://codecov.io/gh/grimen/python-setupextras) + +*Additional common `setuptools` helpers - for Python.* + +## Introduction + +TODO + + +## Install + +Install using **pip**: + +```sh +$ pip install setupextras +``` + + +## Use + +Very basic **[example](https://github.com/grimen/python-setupextras/tree/master/examples/basic.py)**: + +```python +# ========================================= +# IMPORTS +# -------------------------------------- + +import os +import json +import setuptools + +import setupextras + + +# ========================================= +# PACKAGE +# -------------------------------------- + +name = 'foo' +version = '1.0.0' +description = 'A foo library.' +keywords = [ + 'foo', + 'bar', +] + +packages = setupextras.get_packages() +data_files = setupextras.get_data_files(['*.*'], os.path.join(name, 'tests', '__fixtures__')) +requirements = setupextras.get_requirements() +readme = setupextras.get_readme() + +config = { + 'name': name, + 'version': version, + 'description': (description), + 'keywords': keywords, + 'author': 'Jonas Grimfelt', + 'author_email': 'grimen@gmail.com', + 'url': 'https://github.com/grimen/python-{name}'.format(name = name), + 'download_url': 'https://github.com/grimen/python-{name}'.format(name = name), + 'project_urls': { + 'repository': 'https://github.com/grimen/python-{name}'.format(name = name), + 'bugs': 'https://github.com/grimen/python-{name}/issues'.format(name = name), + }, + 'license': 'MIT', + 'long_description': readme, + 'packages': packages, + 'data_files': data_files, + 'install_requires': requirements, +} + +print('CONFIG {0}'.format(json.dumps(config, indent = 4))) + + +# ========================================= +# MAIN +# -------------------------------------- + +setuptools.setup(**config) +``` + + +## Test + +Clone down source code: + +```sh +$ make install +``` + +Run **colorful tests**, with only native environment (dependency sandboxing up to you): + +```sh +$ make test +``` + +Run **less colorful tests**, with **multi-environment** (using **tox**): + +```sh +$ make test-tox +``` + + +## About + +This project was mainly initiated - in lack of solid existing alternatives - to be used at our work at **[Markable.ai](https://markable.ai)** to have common code conventions between various programming environments where **Python** (research, CV, AI) is heavily used. + + +## License + +Released under the MIT license. + + + + +%prep +%autosetup -n setupextras-0.1.5 + +%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-setupextras -f filelist.lst +%dir %{python3_sitelib}/* + +%files help -f doclist.lst +%{_docdir}/* + +%changelog +* Tue Apr 11 2023 Python_Bot <Python_Bot@openeuler.org> - 0.1.5-1 +- Package Spec generated @@ -0,0 +1 @@ +02306fc78d9bc55995ceeb81c9c68aca setupextras-0.1.5.tar.gz |
