Skip to content

Commit

Permalink
Builder: Fixed ampersands in commits, file order in table
Browse files Browse the repository at this point in the history
  • Loading branch information
skyjake committed Dec 16, 2011
1 parent 1b55ca8 commit fcf163d
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 1 deletion.
1 change: 1 addition & 0 deletions distrib/builder/changes.py
Expand Up @@ -61,6 +61,7 @@ def parse(self):
logText = logText.encode('utf-8')
logText = logText.replace('<', '&lt;')
logText = logText.replace('>', '&gt;')
logText = logText.replace('&', '&amp;')

os.remove(tmpName)

Expand Down
14 changes: 13 additions & 1 deletion distrib/builder/event.py
Expand Up @@ -140,11 +140,23 @@ def compress_logs(self):
os.system('gzip -f9 %s' % combinedName)

def download_uri(self, fn):
# Available on SourceForge?
if self.number() >= 350 and (fn.endswith('.exe') or fn.endswith('.deb') or fn.endswith('.dmg')):
return "http://sourceforge.net/projects/deng/files/Doomsday%%20Engine/Builds/%s/download" % fn
# Default to the old location.
return "%s/%s/%s" % (config.BUILD_URI, self.name, fn)

def compressed_log_filename(self, binaryFn):
return 'buildlog-%s-%s.txt.gz' % (self.package_from_filename(binaryFn),
self.os_from_filename(binaryFn)[2])

def sort_by_package(self, binaries):
"""Returns the list of binaries sorted by package."""
pl = []
for bin in binaries:
pl.append((self.package_from_filename(bin), bin))
pl.sort()
return [bin for pkg, bin in pl]

def html_description(self, encoded=True):
"""Composes an HTML build report."""
Expand Down Expand Up @@ -176,7 +188,7 @@ def html_description(self, encoded=True):
continue

# List all the binaries. One row per binary.
for binary in binaries:
for binary in self.sort_by_package(binaries):
msg += '<tr><td>'
if isFirst:
msg += osName
Expand Down

0 comments on commit fcf163d

Please sign in to comment.