diff options
| author | CoprDistGit <infra@openeuler.org> | 2023-04-11 09:50:47 +0000 |
|---|---|---|
| committer | CoprDistGit <infra@openeuler.org> | 2023-04-11 09:50:47 +0000 |
| commit | 94aaead68103fb6a3a90fc2d7a4b62790cde753a (patch) | |
| tree | dbc2e3d65bc015ed8afa7427cd8e5b4033c5e1e2 /python-configupdater.spec | |
| parent | 50195322f06cfbec41002de080c6749247dcccea (diff) | |
automatic import of python-configupdater
Diffstat (limited to 'python-configupdater.spec')
| -rw-r--r-- | python-configupdater.spec | 112 |
1 files changed, 112 insertions, 0 deletions
diff --git a/python-configupdater.spec b/python-configupdater.spec new file mode 100644 index 0000000..7a798ef --- /dev/null +++ b/python-configupdater.spec @@ -0,0 +1,112 @@ +%global _empty_manifest_terminate_build 0 +Name: python-ConfigUpdater +Version: 3.1.1 +Release: 1 +Summary: Parser like ConfigParser but for updating configuration files +License: MIT +URL: https://github.com/pyscaffold/configupdater +Source0: https://mirrors.nju.edu.cn/pypi/web/packages/1a/3e/3dc189e7127ddc594540146c79244a471fdb27362ebe35626c6760c10e6f/ConfigUpdater-3.1.1.tar.gz +BuildArch: noarch + +Requires: python3-importlib-metadata +Requires: python3-sphinx +Requires: python3-flake8 +Requires: python3-pytest +Requires: python3-pytest-cov +Requires: python3-pytest-virtualenv +Requires: python3-pytest-xdist + +%description +The key differences to `ConfigParser`_ are: +* minimal invasive changes in the update configuration file, +* proper handling of comments, +* only a single config file can be updated at a time, +* the original case of sections and keys are kept, +* control over the position of a new section/key +Following features are **deliberately not** implemented: +* interpolation of values, +* propagation of parameters from the default section, +* conversions of values, +* passing key/value-pairs with ``default`` argument, +* non-strict mode allowing duplicate sections and keys. + +%package -n python3-ConfigUpdater +Summary: Parser like ConfigParser but for updating configuration files +Provides: python-ConfigUpdater +BuildRequires: python3-devel +BuildRequires: python3-setuptools +BuildRequires: python3-pip +%description -n python3-ConfigUpdater +The key differences to `ConfigParser`_ are: +* minimal invasive changes in the update configuration file, +* proper handling of comments, +* only a single config file can be updated at a time, +* the original case of sections and keys are kept, +* control over the position of a new section/key +Following features are **deliberately not** implemented: +* interpolation of values, +* propagation of parameters from the default section, +* conversions of values, +* passing key/value-pairs with ``default`` argument, +* non-strict mode allowing duplicate sections and keys. + +%package help +Summary: Development documents and examples for ConfigUpdater +Provides: python3-ConfigUpdater-doc +%description help +The key differences to `ConfigParser`_ are: +* minimal invasive changes in the update configuration file, +* proper handling of comments, +* only a single config file can be updated at a time, +* the original case of sections and keys are kept, +* control over the position of a new section/key +Following features are **deliberately not** implemented: +* interpolation of values, +* propagation of parameters from the default section, +* conversions of values, +* passing key/value-pairs with ``default`` argument, +* non-strict mode allowing duplicate sections and keys. + +%prep +%autosetup -n ConfigUpdater-3.1.1 + +%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-ConfigUpdater -f filelist.lst +%dir %{python3_sitelib}/* + +%files help -f doclist.lst +%{_docdir}/* + +%changelog +* Tue Apr 11 2023 Python_Bot <Python_Bot@openeuler.org> - 3.1.1-1 +- Package Spec generated |
