diff options
| -rw-r--r-- | .gitignore | 1 | ||||
| -rw-r--r-- | python-configupdater.spec | 112 | ||||
| -rw-r--r-- | sources | 1 |
3 files changed, 114 insertions, 0 deletions
@@ -0,0 +1 @@ +/ConfigUpdater-3.1.1.tar.gz 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 @@ -0,0 +1 @@ +f72831b715e20240ff99648551cf85cd ConfigUpdater-3.1.1.tar.gz |
