diff options
| -rw-r--r-- | .gitignore | 1 | ||||
| -rw-r--r-- | python-datetimerange.spec | 77 | ||||
| -rw-r--r-- | sources | 1 |
3 files changed, 79 insertions, 0 deletions
@@ -0,0 +1 @@ +/DateTimeRange-2.1.0.tar.gz diff --git a/python-datetimerange.spec b/python-datetimerange.spec new file mode 100644 index 0000000..7191c8e --- /dev/null +++ b/python-datetimerange.spec @@ -0,0 +1,77 @@ +%global _empty_manifest_terminate_build 0 +Name: python-DateTimeRange +Version: 2.1.0 +Release: 1 +Summary: DateTimeRange is a Python library to handle a time range. e.g. check whether a time is within the time range, get the intersection of time ranges, truncate a time range, iterate through a time range, and so forth. +License: MIT License +URL: https://github.com/thombashi/DateTimeRange +Source0: https://mirrors.nju.edu.cn/pypi/web/packages/ab/1d/6a2a5d223f5fbad1003cb45392df86620a0a9652144d6007989a0eaf542c/DateTimeRange-2.1.0.tar.gz +BuildArch: noarch + +Requires: python3-dateutil +Requires: python3-typepy[datetime] +Requires: python3-pytest +Requires: python3-pytest-md-report +Requires: python3-pytz + +%description +`DateTimeRange <https://github.com/thombashi/DateTimeRange>`__ is a Python library to handle a time range. e.g. check whether a time is within the time range, get the intersection of time ranges, truncate a time range, iterate through a time range, and so forth. + +%package -n python3-DateTimeRange +Summary: DateTimeRange is a Python library to handle a time range. e.g. check whether a time is within the time range, get the intersection of time ranges, truncate a time range, iterate through a time range, and so forth. +Provides: python-DateTimeRange +BuildRequires: python3-devel +BuildRequires: python3-setuptools +BuildRequires: python3-pip +%description -n python3-DateTimeRange +`DateTimeRange <https://github.com/thombashi/DateTimeRange>`__ is a Python library to handle a time range. e.g. check whether a time is within the time range, get the intersection of time ranges, truncate a time range, iterate through a time range, and so forth. + +%package help +Summary: Development documents and examples for DateTimeRange +Provides: python3-DateTimeRange-doc +%description help +`DateTimeRange <https://github.com/thombashi/DateTimeRange>`__ is a Python library to handle a time range. e.g. check whether a time is within the time range, get the intersection of time ranges, truncate a time range, iterate through a time range, and so forth. + +%prep +%autosetup -n DateTimeRange-2.1.0 + +%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-DateTimeRange -f filelist.lst +%dir %{python3_sitelib}/* + +%files help -f doclist.lst +%{_docdir}/* + +%changelog +* Tue Apr 11 2023 Python_Bot <Python_Bot@openeuler.org> - 2.1.0-1 +- Package Spec generated @@ -0,0 +1 @@ +231f685755cefb3801bb2be09a619c5b DateTimeRange-2.1.0.tar.gz |
