You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@couchdb.apache.org by ja...@apache.org on 2013/12/19 21:47:51 UTC

git commit: updated refs/heads/2007-fix-docs-under-ci to b37d578

Updated Branches:
  refs/heads/2007-fix-docs-under-ci bb326eff5 -> b37d57895 (forced update)


Docs: Fix doc building under CI

Under CI the CouchDB version configured can break the LaTeX PDF
building.

This patch munges the release name for doc builds.

Python styles from Eli Stevens.

Closes COUCHDB-2007


Project: http://git-wip-us.apache.org/repos/asf/couchdb/repo
Commit: http://git-wip-us.apache.org/repos/asf/couchdb/commit/b37d5789
Tree: http://git-wip-us.apache.org/repos/asf/couchdb/tree/b37d5789
Diff: http://git-wip-us.apache.org/repos/asf/couchdb/diff/b37d5789

Branch: refs/heads/2007-fix-docs-under-ci
Commit: b37d578957f8a7fd0a29ff79122f29800c13c98a
Parents: d5f0976
Author: Jan Lehnardt <ja...@apache.org>
Authored: Thu Dec 19 17:37:22 2013 +0100
Committer: Jan Lehnardt <ja...@apache.org>
Committed: Thu Dec 19 21:47:13 2013 +0100

----------------------------------------------------------------------
 share/doc/src/conf.py | 11 ++++++++++-
 1 file changed, 10 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/couchdb/blob/b37d5789/share/doc/src/conf.py
----------------------------------------------------------------------
diff --git a/share/doc/src/conf.py b/share/doc/src/conf.py
index 3d2536e..1286f56 100644
--- a/share/doc/src/conf.py
+++ b/share/doc/src/conf.py
@@ -55,7 +55,16 @@ release = '.'.join([
 if _info.get('LOCAL_VERSION_RELEASE') == '.%revision%':
     release += '-dev'
 elif _info.get('LOCAL_VERSION_RELEASE'):
-    release += _info['LOCAL_VERSION_STAGE'] + _info['LOCAL_VERSION_RELEASE']
+    # jenkins hack, the release name is too long or uses
+    # characters that cause pain down the road. Example:
+    # 1.6.0+build.jenkins-ERLANG_VERSION=R14B04,label=Mac-OS-10-8-2-832-76-g2996574
+    # which breaks the LaTeX PDF build. Let’s strip this
+    # down to the git hash at the end.
+    if _info['LOCAL_VERSION_RELEASE'].find('jenkins') > 0:
+        release += _info['LOCAL_VERSION_RELEASE'][-9:]
+    else: # regular case
+        release += _info['LOCAL_VERSION_STAGE'] + _info['LOCAL_VERSION_RELEASE']
+
 
 project = _info['LOCAL_PACKAGE_NAME']