[Checkins] SVN: z3ext.formatter/trunk/ Use new i18n domain z3ext.formatter

Nikolay Kim fafhrd at datacom.kz
Fri Oct 10 05:19:36 EDT 2008


Log message for revision 91970:
  Use new i18n domain z3ext.formatter

Changed:
  U   z3ext.formatter/trunk/CHANGES.txt
  U   z3ext.formatter/trunk/buildout.cfg
  A   z3ext.formatter/trunk/i18ncheck.in
  U   z3ext.formatter/trunk/setup.py
  U   z3ext.formatter/trunk/src/z3ext/formatter/configure.zcml
  U   z3ext.formatter/trunk/src/z3ext/formatter/fancydatetime.py
  D   z3ext.formatter/trunk/src/z3ext/formatter/i18n.py
  U   z3ext.formatter/trunk/src/z3ext/formatter/interfaces.py
  A   z3ext.formatter/trunk/src/z3ext/formatter/locales/
  A   z3ext.formatter/trunk/src/z3ext/formatter/locales/z3ext.formatter.pot
  U   z3ext.formatter/trunk/src/z3ext/formatter/tests.py
  U   z3ext.formatter/trunk/src/z3ext/formatter/vocabulary.py

-=-
Modified: z3ext.formatter/trunk/CHANGES.txt
===================================================================
--- z3ext.formatter/trunk/CHANGES.txt	2008-10-10 08:06:34 UTC (rev 91969)
+++ z3ext.formatter/trunk/CHANGES.txt	2008-10-10 09:19:36 UTC (rev 91970)
@@ -2,6 +2,12 @@
 CHANGES
 =======
 
+1.2.2 (2008-10-10)
+------------------
+
+- Use new i18n domain z3ext.formatter
+
+
 1.2.1 (2008-05-16)
 ------------------
 

Modified: z3ext.formatter/trunk/buildout.cfg
===================================================================
--- z3ext.formatter/trunk/buildout.cfg	2008-10-10 08:06:34 UTC (rev 91969)
+++ z3ext.formatter/trunk/buildout.cfg	2008-10-10 09:19:36 UTC (rev 91970)
@@ -1,6 +1,6 @@
 [buildout]
 develop = .
-parts = test coverage-test coverage-report
+parts = test coverage-test coverage-report i18n i18ncheck i18ndude
 
 [test]
 recipe = zc.recipe.testrunner
@@ -18,3 +18,38 @@
 eggs = z3c.coverage
 scripts = coverage=coverage-report
 arguments = ('coverage', 'coverage/report')
+
+[i18n]
+recipe = z3c.recipe.i18n:i18n
+packages = z3ext.formatter
+domain = z3ext.formatter
+output = ${buildout:directory}/src/z3ext/formatter/locales
+eggs = z3ext.formatter [test]
+zcml =
+  <configure i18n_domain="zope"
+             xmlns:zcml="http://namespaces.zope.org/zcml"
+             xmlns:browser="http://namespaces.zope.org/browser">
+    <include package="zope.component" file="meta.zcml" />
+    <include package="zope.securitypolicy" file="meta.zcml" />
+    <include package="zope.app.component" file="meta.zcml" />
+    <include package="zope.app.security" file="meta.zcml" />
+    <include package="zope.app.pagetemplate" file="meta.zcml" />
+
+    <include package="zope.securitypolicy" />
+    <include package="zope.app.security" />
+    <include package="zope.app.zcmlfiles" />
+    <include package="zope.app.authentication" />
+
+    <include package="z3c.autoinclude" file="meta.zcml" />
+    <include package="z3ext.formatter" />
+  </configure>
+
+[i18ncheck]
+recipe = buildout_script
+template_dir = ${buildout:directory}/
+template = i18ncheck.in
+
+[i18ndude]
+unzip = true
+recipe = zc.recipe.egg
+eggs = i18ndude

Added: z3ext.formatter/trunk/i18ncheck.in
===================================================================
--- z3ext.formatter/trunk/i18ncheck.in	                        (rev 0)
+++ z3ext.formatter/trunk/i18ncheck.in	2008-10-10 09:19:36 UTC (rev 91970)
@@ -0,0 +1,4 @@
+#!/bin/sh
+# Startup or shutdown buildbot
+
+bin/i18ndude find-untranslated ./ | grep z3ext.persistentlayout | less


Property changes on: z3ext.formatter/trunk/i18ncheck.in
___________________________________________________________________
Name: svn:executable
   + *

Modified: z3ext.formatter/trunk/setup.py
===================================================================
--- z3ext.formatter/trunk/setup.py	2008-10-10 08:06:34 UTC (rev 91969)
+++ z3ext.formatter/trunk/setup.py	2008-10-10 09:19:36 UTC (rev 91970)
@@ -60,6 +60,7 @@
                           'zope.schema',
                           'zope.proxy',
                           'zope.tales',
+                          'zope.i18n',
                           'zope.i18nmessageid',
                           'zope.app.appsetup',
                           'zope.app.pagetemplate',
@@ -70,6 +71,7 @@
       extras_require = dict(test=['zope.app.zptpage',
                                   'zope.app.testing',
                                   'zope.testing',
+                                  'z3ext.controlpanel [test]',
                                   ]),
       include_package_data = True,
       zip_safe = False

Modified: z3ext.formatter/trunk/src/z3ext/formatter/configure.zcml
===================================================================
--- z3ext.formatter/trunk/src/z3ext/formatter/configure.zcml	2008-10-10 08:06:34 UTC (rev 91969)
+++ z3ext.formatter/trunk/src/z3ext/formatter/configure.zcml	2008-10-10 09:19:36 UTC (rev 91970)
@@ -1,9 +1,10 @@
 <configure
    xmlns="http://namespaces.zope.org/zope"
+   xmlns:i18n="http://namespaces.zope.org/i18n"
    xmlns:z3ext="http://namespaces.zope.org/z3ext"
    xmlns:tales="http://namespaces.zope.org/tales"
    xmlns:browser="http://namespaces.zope.org/browser"
-   i18n_domain="z3ext">
+   i18n_domain="z3ext.formatter">
 
   <includeDependencies package="z3ext.formatter" />
 
@@ -54,4 +55,7 @@
 
   </configure>
 
+  <!-- translations -->
+  <i18n:registerTranslations directory="locales"/>
+
 </configure>

Modified: z3ext.formatter/trunk/src/z3ext/formatter/fancydatetime.py
===================================================================
--- z3ext.formatter/trunk/src/z3ext/formatter/fancydatetime.py	2008-10-10 08:06:34 UTC (rev 91969)
+++ z3ext.formatter/trunk/src/z3ext/formatter/fancydatetime.py	2008-10-10 09:19:36 UTC (rev 91970)
@@ -23,8 +23,7 @@
 from zope.interface.common.idatetime import ITZInfo
 from zope.publisher.interfaces.http import IHTTPRequest
 
-from i18n import _
-from interfaces import IFormatter, IFormatterFactory, IFormatterConfiglet
+from interfaces import _, IFormatter, IFormatterFactory, IFormatterConfiglet
 
 
 class FancyDatetimeFormatter(object):

Deleted: z3ext.formatter/trunk/src/z3ext/formatter/i18n.py
===================================================================
--- z3ext.formatter/trunk/src/z3ext/formatter/i18n.py	2008-10-10 08:06:34 UTC (rev 91969)
+++ z3ext.formatter/trunk/src/z3ext/formatter/i18n.py	2008-10-10 09:19:36 UTC (rev 91970)
@@ -1,19 +0,0 @@
-##############################################################################
-#
-# Copyright (c) 2007 Zope Corporation and Contributors.
-# All Rights Reserved.
-#
-# This software is subject to the provisions of the Zope Public License,
-# Version 2.1 (ZPL).  A copy of the ZPL should accompany this distribution.
-# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED
-# WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
-# WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS
-# FOR A PARTICULAR PURPOSE.
-#
-##############################################################################
-""" i18n
-
-$Id$
-"""
-from zope.i18nmessageid import MessageFactory
-_ = MessageFactory('z3ext')

Modified: z3ext.formatter/trunk/src/z3ext/formatter/interfaces.py
===================================================================
--- z3ext.formatter/trunk/src/z3ext/formatter/interfaces.py	2008-10-10 08:06:34 UTC (rev 91969)
+++ z3ext.formatter/trunk/src/z3ext/formatter/interfaces.py	2008-10-10 09:19:36 UTC (rev 91970)
@@ -17,8 +17,9 @@
 """
 import vocabulary
 from zope import schema, interface
+from zope.i18nmessageid import MessageFactory
 
-from i18n import _
+_ = MessageFactory('z3ext.formatter')
 
 
 class FormatterNotDefined(Exception):

Added: z3ext.formatter/trunk/src/z3ext/formatter/locales/z3ext.formatter.pot
===================================================================
--- z3ext.formatter/trunk/src/z3ext/formatter/locales/z3ext.formatter.pot	                        (rev 0)
+++ z3ext.formatter/trunk/src/z3ext/formatter/locales/z3ext.formatter.pot	2008-10-10 09:19:36 UTC (rev 91970)
@@ -0,0 +1,74 @@
+##############################################################################
+#
+# Copyright (c) 2003-2004 Zope Corporation and Contributors.
+# All Rights Reserved.
+#
+# This software is subject to the provisions of the Zope Public License,
+# Version 2.1 (ZPL).  A copy of the ZPL should accompany this distribution.
+# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED
+# WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS
+# FOR A PARTICULAR PURPOSE.
+#
+##############################################################################
+msgid ""
+msgstr ""
+"Project-Id-Version: Development/Unknown\n"
+"POT-Creation-Date: Fri Oct 10 15:00:54 2008\n"
+"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
+"Last-Translator: FULL NAME <EMAIL at ADDRESS>\n"
+"Language-Team: Zope 3 Developers <zope3-dev at zope.org>\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Generated-By: zope/app/locales/extract.py\n"
+
+#: src/z3ext/formatter/configure.zcml:26
+msgid "Configure portal formatters."
+msgstr ""
+
+#: src/z3ext/formatter/configure.zcml:26
+msgid "Portal formatters"
+msgstr ""
+
+#: src/z3ext/formatter/fancydatetime.py:71
+msgid "Today at"
+msgstr ""
+
+#: src/z3ext/formatter/fancydatetime.py:79
+msgid "Yesterday at"
+msgstr ""
+
+#: src/z3ext/formatter/interfaces.py:36
+msgid "Timezone"
+msgstr ""
+
+#: src/z3ext/formatter/interfaces.py:37
+msgid "Portal timezone."
+msgstr ""
+
+#: src/z3ext/formatter/interfaces.py:43
+#: src/z3ext/formatter/interfaces.py:44
+msgid "Timezone format"
+msgstr ""
+
+#: src/z3ext/formatter/interfaces.py:50
+msgid "Use principal timezone"
+msgstr ""
+
+#: src/z3ext/formatter/interfaces.py:51
+msgid "Render datetime with user selected timezone."
+msgstr ""
+
+#: src/z3ext/formatter/vocabulary.py:28
+msgid "No timezone"
+msgstr ""
+
+#: src/z3ext/formatter/vocabulary.py:29
+msgid "Number of hours"
+msgstr ""
+
+#: src/z3ext/formatter/vocabulary.py:30
+msgid "Timezone name"
+msgstr ""
+

Modified: z3ext.formatter/trunk/src/z3ext/formatter/tests.py
===================================================================
--- z3ext.formatter/trunk/src/z3ext/formatter/tests.py	2008-10-10 08:06:34 UTC (rev 91969)
+++ z3ext.formatter/trunk/src/z3ext/formatter/tests.py	2008-10-10 09:19:36 UTC (rev 91970)
@@ -33,7 +33,7 @@
 
 
 def setUp(test):
-    setup.placelessSetUp(True)
+    setup.placefulSetUp(True)
     setup.setUpTraversal()
     setUpControlPanel()
 

Modified: z3ext.formatter/trunk/src/z3ext/formatter/vocabulary.py
===================================================================
--- z3ext.formatter/trunk/src/z3ext/formatter/vocabulary.py	2008-10-10 08:06:34 UTC (rev 91969)
+++ z3ext.formatter/trunk/src/z3ext/formatter/vocabulary.py	2008-10-10 09:19:36 UTC (rev 91970)
@@ -19,8 +19,9 @@
 from zope import interface
 from zope.schema.interfaces import IVocabularyFactory
 from zope.schema.vocabulary import SimpleTerm, SimpleVocabulary
+from zope.i18nmessageid import MessageFactory
 
-from i18n import _
+_ = MessageFactory('z3ext.formatter')
 
 
 timezonesOptions = SimpleVocabulary(



More information about the Checkins mailing list