[Python-checkins] cpython (3.2): #8040: fix the version.

ezio.melotti python-checkins at python.org
Sat Oct 27 22:13:50 CEST 2012


http://hg.python.org/cpython/rev/36a35b86e3b0
changeset:   79984:36a35b86e3b0
branch:      3.2
parent:      79980:740be7346c92
user:        Ezio Melotti <ezio.melotti at gmail.com>
date:        Sat Oct 27 23:12:48 2012 +0300
summary:
  #8040: fix the version.

files:
  Doc/tools/sphinxext/static/version_switch.js |  8 ++++++--
  1 files changed, 6 insertions(+), 2 deletions(-)


diff --git a/Doc/tools/sphinxext/static/version_switch.js b/Doc/tools/sphinxext/static/version_switch.js
--- a/Doc/tools/sphinxext/static/version_switch.js
+++ b/Doc/tools/sphinxext/static/version_switch.js
@@ -52,8 +52,12 @@
   }
 
   $(document).ready(function() {
-    var select = build_select(DOCUMENTATION_OPTIONS.VERSION,
-                              DOCUMENTATION_OPTIONS.RELEASE);
+    var version = DOCUMENTATION_OPTIONS.VERSION.split('.'),
+        release = DOCUMENTATION_OPTIONS.RELEASE || DOCUMENTATION_OPTIONS.VERSION;
+
+    version = version[0] + '.' + version[1];
+    var select = build_select(version, release);
+
     $('.version_switcher_placeholder').html(select);
     $('.version_switcher_placeholder select').bind('change', on_switch);
   });

-- 
Repository URL: http://hg.python.org/cpython


More information about the Python-checkins mailing list