commit 88ab1b405dd79c1d5c5e162a0a4257dd2bcfb45d581f56500a9a3816c32812fc Author: Alberto Planas Dominguez Date: Fri Nov 14 10:27:14 2014 +0000 Accepting request 261559 from home:seilerphilipp now with the correct way to do the test (pytz as build dependency) OBS-URL: https://build.opensuse.org/request/show/261559 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-tzlocal?expand=0&rev=1 diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..9b03811 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,23 @@ +## Default LFS +*.7z filter=lfs diff=lfs merge=lfs -text +*.bsp filter=lfs diff=lfs merge=lfs -text +*.bz2 filter=lfs diff=lfs merge=lfs -text +*.gem filter=lfs diff=lfs merge=lfs -text +*.gz filter=lfs diff=lfs merge=lfs -text +*.jar filter=lfs diff=lfs merge=lfs -text +*.lz filter=lfs diff=lfs merge=lfs -text +*.lzma filter=lfs diff=lfs merge=lfs -text +*.obscpio filter=lfs diff=lfs merge=lfs -text +*.oxt filter=lfs diff=lfs merge=lfs -text +*.pdf filter=lfs diff=lfs merge=lfs -text +*.png filter=lfs diff=lfs merge=lfs -text +*.rpm filter=lfs diff=lfs merge=lfs -text +*.tbz filter=lfs diff=lfs merge=lfs -text +*.tbz2 filter=lfs diff=lfs merge=lfs -text +*.tgz filter=lfs diff=lfs merge=lfs -text +*.ttf filter=lfs diff=lfs merge=lfs -text +*.txz filter=lfs diff=lfs merge=lfs -text +*.whl filter=lfs diff=lfs merge=lfs -text +*.xz filter=lfs diff=lfs merge=lfs -text +*.zip filter=lfs diff=lfs merge=lfs -text +*.zst filter=lfs diff=lfs merge=lfs -text diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..57affb6 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +.osc diff --git a/python-tzlocal.changes b/python-tzlocal.changes new file mode 100644 index 0000000..2cb7601 --- /dev/null +++ b/python-tzlocal.changes @@ -0,0 +1,16 @@ +------------------------------------------------------------------- +Thu Nov 6 09:53:03 UTC 2014 - seiler@b1-systems.de + +- corrected license +- added check section with python test +------------------------------------------------------------------- +Thu Nov 6 08:50:54 UTC 2014 - seiler@b1-systems.de + +- added required pytz dependency +- enhanced truncated description and add URL to source + +------------------------------------------------------------------- +Wed Nov 5 13:16:15 UTC 2014 - seiler@b1-systems.de + +- inital commit + diff --git a/python-tzlocal.spec b/python-tzlocal.spec new file mode 100644 index 0000000..4cd6ec5 --- /dev/null +++ b/python-tzlocal.spec @@ -0,0 +1,91 @@ +# +# spec file for package +# +# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany. +# +# All modifications and additions to the file contributed by third parties +# remain the property of their copyright owners, unless otherwise agreed +# upon. The license for this file, and modifications and additions to the +# file, is the same license as for the pristine package itself (unless the +# license for the pristine package is not an Open Source License, in which +# case the license is the MIT License). An "Open Source License" is a +# license that conforms to the Open Source Definition (Version 1.9) +# published by the Open Source Initiative. + +# Please submit bugfixes or comments via http://bugs.opensuse.org/ +# +%define short_name tzlocal + +Name: python-tzlocal +Version: 1.1.2 +Release: 0 +License: CC0-1.0 +Summary: Tzinfo object for the local timezone +Url: https://pypi.python.org/pypi/tzlocal/ +Group: Development/Languages/Python +Source: https://pypi.python.org/packages/source/t/%{short_name}/%{short_name}-%{version}.zip +BuildRequires: unzip +BuildRequires: python-setuptools +BuildRequires: fdupes +BuildRequires: python-pytz +Requires: python-pytz +BuildArch: noarch +BuildRoot: %{_tmppath}/%{name}-%{version}-build + +%description +This Python module returns a tzinfo object with the local timezone information under Unix and Win-32. It requires pytz, and returns pytz tzinfo objects. + +This module attempts to fix a glaring hole in pytz, that there is no way to get the local timezone information, unless you know the zoneinfo name, and under several Linux distros that's hard or impossible to figure out. + +With tzlocal you only need to call get_localzone() and you will get a tzinfo object with the local time zone info. On some Unices you will still not get to know what the timezone name is, but you don't need that when you have the tzinfo file. However, if the timezone name is readily available it will be used. + +%prep +%setup -q -n %{short_name}-%{version} + +%build +python setup.py build + +%install +python setup.py install --root=%{buildroot} --prefix=%{_prefix} +%fdupes -s %{buildroot} + +%check +python setup.py test + +%files +%defattr(-,root,root) +%doc README.rst MANIFEST.in LICENSE.txt CHANGES.txt + +%dir %{python_sitelib}/tzlocal +%dir %{python_sitelib}/tzlocal-*.egg-info +%dir %{python_sitelib}/tzlocal/test_data +%dir %{python_sitelib}/tzlocal/test_data/localtime +%dir %{python_sitelib}/tzlocal/test_data/localtime/etc +%dir %{python_sitelib}/tzlocal/test_data/timezone +%dir %{python_sitelib}/tzlocal/test_data/timezone/etc +%dir %{python_sitelib}/tzlocal/test_data/timezone_setting +%dir %{python_sitelib}/tzlocal/test_data/timezone_setting/etc +%dir %{python_sitelib}/tzlocal/test_data/timezone_setting/etc/conf.d +%dir %{python_sitelib}/tzlocal/test_data/zone_setting +%dir %{python_sitelib}/tzlocal/test_data/zone_setting/etc +%dir %{python_sitelib}/tzlocal/test_data/zone_setting/etc/sysconfig + +%{python_sitelib}/tzlocal-*.egg-info/PKG-INFO +%{python_sitelib}/tzlocal-*.egg-info/SOURCES.txt +%{python_sitelib}/tzlocal-*.egg-info/dependency_links.txt +%{python_sitelib}/tzlocal-*.egg-info/requires.txt +%{python_sitelib}/tzlocal-*.egg-info/top_level.txt +%{python_sitelib}/tzlocal-*.egg-info/zip-safe +%{python_sitelib}/tzlocal/__init__.py* +%{python_sitelib}/tzlocal/darwin.py* +%{python_sitelib}/tzlocal/test_data/Harare +%{python_sitelib}/tzlocal/test_data/localtime/etc/localtime +%{python_sitelib}/tzlocal/test_data/timezone/etc/timezone +%{python_sitelib}/tzlocal/test_data/timezone_setting/etc/conf.d/clock +%{python_sitelib}/tzlocal/test_data/zone_setting/etc/sysconfig/clock +%{python_sitelib}/tzlocal/tests.py* +%{python_sitelib}/tzlocal/unix.py* +%{python_sitelib}/tzlocal/win32.py* +%{python_sitelib}/tzlocal/windows_tz.py* + +%changelog diff --git a/tzlocal-1.1.2.zip b/tzlocal-1.1.2.zip new file mode 100644 index 0000000..a57290c --- /dev/null +++ b/tzlocal-1.1.2.zip @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4d9ddb8d5eab086e3a7c504c6e994ffa85df43e40da4d6be776218be051c677a +size 22504