* Refactor the code for getting the svn revision so it can be shared.

* Refactor the code for uploading files to the nightly server to its own helper function.
* Add command to build and upload a docs tarball.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@71231 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robin Dunn
2012-04-19 03:04:04 +00:00
parent 441352345f
commit 79f6e60a7b
3 changed files with 164 additions and 119 deletions

View File

@@ -20,7 +20,7 @@ import subprocess
# Phoenix-specific imports
import templates
from buildtools.config import copyIfNewer, writeIfChanged, newer
from buildtools.config import copyIfNewer, writeIfChanged, newer, getSvnRev
from utilities import Wx2Sphinx
from constants import HTML_REPLACE, TODAY, SPHINXROOT, SECTIONS_EXCLUDE
@@ -661,18 +661,8 @@ def PostProcess(folder):
# ----------------------------------------------------------------------- #
def ChangeSVNRevision(text):
svn_result = subprocess.Popen(["svn", "info"], stdout=subprocess.PIPE).communicate()[0]
SVN_REVISION = ''
for line in svn_result.split("\n"):
if line.startswith("Revision"):
SVN_REVISION = line.split(":")[-1].strip()
break
if not SVN_REVISION:
text = text.replace('|TODAY|', TODAY)
return text
SVN_REVISION = getSvnRev()
text = text.replace('|TODAY|', TODAY)
text = text.replace('|SVN|', SVN_REVISION)
return text