summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlex Alexander <wired@gentoo.org>2011-02-23 07:54:34 +0000
committerAlex Alexander <wired@gentoo.org>2011-02-23 07:54:34 +0000
commit9ebda1c2ecba822aa622f1259ccef10d0344a44c (patch)
tree4064dd4331b7949462b6b9d0da71e245e9027c94 /net-misc/googlecl
parent[bump] virtual/perl-Test-Harness-3.230 (diff)
downloadgentoo-2-9ebda1c2ecba822aa622f1259ccef10d0344a44c.tar.gz
gentoo-2-9ebda1c2ecba822aa622f1259ccef10d0344a44c.tar.bz2
gentoo-2-9ebda1c2ecba822aa622f1259ccef10d0344a44c.zip
fixed bug #355913 (date not showing in the calendar's 'when' field)
(Portage version: 2.2.0_alpha24/cvs/Linux x86_64)
Diffstat (limited to 'net-misc/googlecl')
-rw-r--r--net-misc/googlecl/ChangeLog8
-rw-r--r--net-misc/googlecl/files/googlecl-0.9.12-calendar_dates.patch64
-rw-r--r--net-misc/googlecl/googlecl-0.9.12-r1.ebuild40
3 files changed, 111 insertions, 1 deletions
diff --git a/net-misc/googlecl/ChangeLog b/net-misc/googlecl/ChangeLog
index be46c1d130f4..904868808955 100644
--- a/net-misc/googlecl/ChangeLog
+++ b/net-misc/googlecl/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for net-misc/googlecl
# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-misc/googlecl/ChangeLog,v 1.8 2011/01/28 17:14:10 wired Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-misc/googlecl/ChangeLog,v 1.9 2011/02/23 07:54:33 wired Exp $
+
+*googlecl-0.9.12-r1 (23 Feb 2011)
+
+ 23 Feb 2011; Alex Alexander <wired@gentoo.org> +googlecl-0.9.12-r1.ebuild,
+ +files/googlecl-0.9.12-calendar_dates.patch:
+ fixed bug #355913 (date not showing in the calendar's 'when' field)
*googlecl-0.9.12 (28 Jan 2011)
diff --git a/net-misc/googlecl/files/googlecl-0.9.12-calendar_dates.patch b/net-misc/googlecl/files/googlecl-0.9.12-calendar_dates.patch
new file mode 100644
index 000000000000..83897bb69550
--- /dev/null
+++ b/net-misc/googlecl/files/googlecl-0.9.12-calendar_dates.patch
@@ -0,0 +1,64 @@
+fix "when" field in calendar not showing dates
+
+http://bugs.gentoo.org/show_bug.cgi?id=355913
+http://code.google.com/p/googlecl/issues/detail?id=358
+
+Index: googlecl/base.py
+===================================================================
+--- src/googlecl/base.py (revision 527)
++++ src/googlecl/base.py (working copy)
+@@ -673,10 +673,12 @@
+ except ValueError, err:
+ LOG.debug(err.args[0] + ' (Did not add value for field ' + attr + ')')
+ except AttributeError, err:
++ LOG.debug(err.args[0] + ' (value for field ' + attr + ')')
+ try:
+ # Last ditch effort to blindly grab the attribute
+ val = getattr(wrapped_entry.entry, attr).text or missing_field_value
+ except AttributeError:
++ LOG.debug(err.args[0] + ' (value for field ' + attr + ')')
+ val = missing_field_value
+ # Apparently, atom(?) doesn't always return a Unicode type when there are
+ # non-latin characters, so force everything to Unicode.
+Index: googlecl/calendar/__init__.py
+===================================================================
+--- src/googlecl/calendar/__init__.py (revision 527)
++++ src/googlecl/calendar/__init__.py (working copy)
+@@ -235,12 +235,22 @@
+
+
+ class CalendarEntryToStringWrapper(googlecl.base.BaseEntryToStringWrapper):
++ def __init__(self, entry, config):
++ """Initialize a CalendarEntry wrapper.
++
++ Args:
++ entry: CalendarEntry to interpret to strings.
++ config: Configuration parser. Needed for some values.
++ """
++ googlecl.base.BaseEntryToStringWrapper.__init__(self, entry)
++ self.config_parser = config
++
+ @property
+ def when(self):
+ """When event takes place."""
+ start_date, end_date, freq = get_datetimes(self.entry)
+- print_format = googlecl.CONFIG.lazy_get(SECTION_HEADER,
+- 'date_print_format')
++ print_format = self.config_parser.lazy_get(SECTION_HEADER,
++ 'date_print_format')
+ start_text = time.strftime(print_format, start_date)
+ end_text = time.strftime(print_format, end_date)
+ value = start_text + ' - ' + end_text
+@@ -277,9 +287,9 @@
+
+ for entry in single_events:
+ print googlecl.base.compile_entry_string(
+- CalendarEntryToStringWrapper(entry),
+- options.fields.split(','),
+- delimiter=options.delimiter)
++ CalendarEntryToStringWrapper(entry, client.config),
++ options.fields.split(','),
++ delimiter=options.delimiter)
+
+
+ #===============================================================================
diff --git a/net-misc/googlecl/googlecl-0.9.12-r1.ebuild b/net-misc/googlecl/googlecl-0.9.12-r1.ebuild
new file mode 100644
index 000000000000..09b624d28970
--- /dev/null
+++ b/net-misc/googlecl/googlecl-0.9.12-r1.ebuild
@@ -0,0 +1,40 @@
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-misc/googlecl/googlecl-0.9.12-r1.ebuild,v 1.1 2011/02/23 07:54:33 wired Exp $
+
+EAPI=3
+PYTHON_DEPEND="2:2.5:2.7"
+
+inherit distutils eutils
+
+DESCRIPTION="Command line tools for the Google Data APIs"
+HOMEPAGE="http://code.google.com/p/googlecl/"
+SRC_URI="http://${PN}.googlecode.com/files/${P}.tar.gz"
+
+LICENSE="Apache-2.0"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+DEPEND=""
+RDEPEND="
+ dev-python/gdata
+"
+
+pkg_setup() {
+ python_set_active_version 2
+}
+
+src_prepare() {
+ # fix 'when' field not showing dates, bug #355913
+ epatch "${FILESDIR}"/"${P}"-calendar_dates.patch
+
+ distutils_src_prepare
+}
+
+src_install() {
+ distutils_src_install
+
+ dodoc changelog || die "dodoc failed"
+ doman man/*.1 || die "doman failed"
+}