[Checkins] SVN: hurry.jquerytools/trunk/ Preparing release 1.2.5

Christian Klinger cklinger at novareto.de
Thu Oct 7 10:34:56 EDT 2010


Log message for revision 117348:
  Preparing release 1.2.5

Changed:
  U   hurry.jquerytools/trunk/CHANGES.txt
  U   hurry.jquerytools/trunk/buildout.cfg
  U   hurry.jquerytools/trunk/setup.py
  U   hurry.jquerytools/trunk/src/hurry/jquerytools/__init__.py
  D   hurry.jquerytools/trunk/src/hurry/jquerytools/configure.zcml
  U   hurry.jquerytools/trunk/src/hurry/jquerytools/jquerytools.txt
  U   hurry.jquerytools/trunk/src/hurry/jquerytools/prepare.py

-=-
Modified: hurry.jquerytools/trunk/CHANGES.txt
===================================================================
--- hurry.jquerytools/trunk/CHANGES.txt	2010-10-07 12:56:39 UTC (rev 117347)
+++ hurry.jquerytools/trunk/CHANGES.txt	2010-10-07 14:34:56 UTC (rev 117348)
@@ -1,12 +1,12 @@
 CHANGES
 *******
 
-1.2.5 (unreleased)
+1.2.5 (2010-10-07)
 ==================
 
-- Nothing changed yet.
+* upgrade to use hurry.jquery 0.10
+* upgrade to jquerytools-1.2.5
 
-
 1.2.4 (2010-09-08)
 ==================
 

Modified: hurry.jquerytools/trunk/buildout.cfg
===================================================================
--- hurry.jquerytools/trunk/buildout.cfg	2010-10-07 12:56:39 UTC (rev 117347)
+++ hurry.jquerytools/trunk/buildout.cfg	2010-10-07 14:34:56 UTC (rev 117348)
@@ -4,7 +4,7 @@
 versions = versions
 
 [versions]
-zest.releaser = 3.0
+zest.releaser = 3.12
 
 [scripts]
 recipe = zc.recipe.egg

Modified: hurry.jquerytools/trunk/setup.py
===================================================================
--- hurry.jquerytools/trunk/setup.py	2010-10-07 12:56:39 UTC (rev 117347)
+++ hurry.jquerytools/trunk/setup.py	2010-10-07 14:34:56 UTC (rev 117348)
@@ -1,8 +1,8 @@
 from setuptools import setup, find_packages
 import os
 
-JQUERYTOOLS_VERSION = '1.2.4'
-version = '1.2.5dev'
+JQUERYTOOLS_VERSION = '1.2.5'
+version = '1.2.5'
 
 def read(*rnames):
     return open(os.path.join(os.path.dirname(__file__), *rnames)).read()
@@ -29,20 +29,25 @@
     zip_safe=False,
     install_requires=[
         'setuptools',
-        'hurry.jquery == 1.4.2.1',
-        'hurry.resource == 0.4.1',
+        'py',
+        'hurry.jquery',
+        'hurry.resource',
         ],
     entry_points={
         'console_scripts': [
             'jquerytoolsprepare = hurry.jquerytools.prepare:main',
             ],
         'zest.releaser.prereleaser.middle': [
-            'prepare = hurry.jquerytools.prepare:entrypoint',
+            'prepare = hurry.jquerytools.prepare:working_entrypoint',
             ],
         # ALSO grab jquerytools in the separate tag checkout...
-        'zest.releaser.releaser.middle': [
-            'prepare = hurry.jquerytools.prepare:entrypoint',
+        'zest.releaser.releaser.after_checkout': [
+            'prepare = hurry.jquerytools.prepare:tag_entrypoint',
             ],
+        'hurry.resource.libraries': [
+            'jqueryui = hurry.jquerytools:jquerytools_lib',
+            ],
+
         },
     extras_require={
         'zopesupport': ['hurry.zoperesource'],

Modified: hurry.jquerytools/trunk/src/hurry/jquerytools/__init__.py
===================================================================
--- hurry.jquerytools/trunk/src/hurry/jquerytools/__init__.py	2010-10-07 12:56:39 UTC (rev 117347)
+++ hurry.jquerytools/trunk/src/hurry/jquerytools/__init__.py	2010-10-07 14:34:56 UTC (rev 117348)
@@ -1,7 +1,7 @@
 from hurry.resource import Library, ResourceInclusion, GroupInclusion
 from hurry.jquery import jquery
 
-JqueryToolsLibrary = Library('JqueryToolsLibrary')
+JqueryToolsLibrary = Library('JqueryToolsLibrary', 'JqueryTools-build')
 
 jquerytools = ResourceInclusion(
     JqueryToolsLibrary, 'jquery.tools.min.js', depends=[jquery])

Deleted: hurry.jquerytools/trunk/src/hurry/jquerytools/configure.zcml
===================================================================
--- hurry.jquerytools/trunk/src/hurry/jquerytools/configure.zcml	2010-10-07 12:56:39 UTC (rev 117347)
+++ hurry.jquerytools/trunk/src/hurry/jquerytools/configure.zcml	2010-10-07 14:34:56 UTC (rev 117348)
@@ -1,11 +0,0 @@
-<configure
-  xmlns="http://namespaces.zope.org/zope"
-  xmlns:browser="http://namespaces.zope.org/browser">
-
-  <include package="hurry.jquery" />
-
-  <browser:resourceDirectory
-      name="JqueryToolsLibrary"
-      directory="jquerytools-build" />
-
-</configure>

Modified: hurry.jquerytools/trunk/src/hurry/jquerytools/jquerytools.txt
===================================================================
--- hurry.jquerytools/trunk/src/hurry/jquerytools/jquerytools.txt	2010-10-07 12:56:39 UTC (rev 117347)
+++ hurry.jquerytools/trunk/src/hurry/jquerytools/jquerytools.txt	2010-10-07 14:34:56 UTC (rev 117348)
@@ -7,15 +7,14 @@
 Let's set up a way to render URLs; typically the framework has already
 done this::
 
-  >>> def get_library_url(library):
-  ...    return 'http://localhost/static/%s' % (library.name)
-  >>> from hurry.resource import Library
-  >>> from hurry.resource.interfaces import ILibraryUrl
-  >>> from zope import component
-  >>> # register the ILibraryUrl adaptation for the tests.
-  >>> component.provideAdapter(
-  ...     factory=get_library_url, adapts=(Library,), provides=ILibraryUrl)
+  >>> class Plugin(object):
+  ...   def get_library_url(self, library):
+  ...     return 'http://localhost/static/%s' % (library.name)
+  >>> from hurry.resource import register_plugin
+  >>> register_plugin(Plugin())
 
+
+
 Render the inclusion::
 
   >>> from hurry.resource import NeededInclusions
@@ -23,7 +22,7 @@
   >>> needed = NeededInclusions()
   >>> needed.need(jquerytools)
   >>> print needed.render()
-  <script type="text/javascript" src="http://localhost/static/jquery/jquery-1...js"></script>
+  <script type="text/javascript" src="http://localhost/static/jquery_lib/jquery-1...js"></script>
   <script type="text/javascript" src="http://localhost/static/JqueryToolsLibrary/jquery.tools.min.js"></script>
 
 """

Modified: hurry.jquerytools/trunk/src/hurry/jquerytools/prepare.py
===================================================================
--- hurry.jquerytools/trunk/src/hurry/jquerytools/prepare.py	2010-10-07 12:56:39 UTC (rev 117347)
+++ hurry.jquerytools/trunk/src/hurry/jquerytools/prepare.py	2010-10-07 14:34:56 UTC (rev 117348)
@@ -12,41 +12,45 @@
 #
 ##############################################################################
 
+import py
 import os
 import shutil
 import urllib2
 import urlparse
 import zipfile
 
-VERSION = '1.2.4'
+VERSION = '1.2.5'
 BASEURL = "http://cdn.jquerytools.org/%s/all/jquery.tools.min.js" %VERSION
 FILENAME = "jquery.tools.min.js"
 
-def prepare_jquerytools():
-    jquerytools_dest_path = os.path.dirname(__file__)
-    library_path = os.path.join(jquerytools_dest_path, "jquerytools-build")
+def prepare_jquerytools(package_path):
+    library_path = package_path.join("jquerytools-build")
 
     # remove previous slimbox library
     print 'recursivly removing "%s"' % library_path
-    shutil.rmtree(library_path, ignore_errors=True)
+    if library_path.check():
+        library_path.remove()
+    print 'create new "%s"' % library_path 
+    library_path.ensure(dir=True)
 
     url = BASEURL
     print 'downloading "%s"' % url
     f = urllib2.urlopen(url)
     file_data = f.read()
     f.close()
-    dest_filename = os.path.join(jquerytools_dest_path, FILENAME)
-    dest = open(dest_filename, 'wb')
+    dest_filename = library_path.join(FILENAME)
     print 'writing data to "%s"' % dest_filename
-    dest.write(file_data)
-    dest.close()
-    os.mkdir(library_path)
-    shutil.move(dest_filename, library_path)
+    dest_filename.write(file_data)
 
 def main():
-    prepare_jquerytools()
+    prepare_jquerytools(os.path.dirname(__file__))
 
+def working_entrypoint(data):
+    if data['name'] != 'hurry.jquerytools':
+        return
+    prepare_jquerytools(py.path.local(os.path.dirname(__file__)))
 
-def entrypoint(data):
-    """Entry point for zest.releaser's prerelease script"""
-    prepare_jquerytools()
+def tag_entrypoint(data):
+    if data['name'] != 'hurry.jquertools':
+        return
+    prepare_jquerytools(py.path.local(data['tagdir'] + '/src/hurry/jquerytools'))



More information about the checkins mailing list