mirror of
https://gitlab.com/fdroid/fdroidserver.git
synced 2024-09-17 10:40:12 +02:00
Better build log formatting for wiki
This commit is contained in:
parent
8a99fb3da4
commit
d832bf8e9e
@ -677,7 +677,7 @@ def main():
|
|||||||
if options.stop:
|
if options.stop:
|
||||||
sys.exit(1)
|
sys.exit(1)
|
||||||
failed_apps[app['id']] = be
|
failed_apps[app['id']] = be
|
||||||
wikilog = str(be)
|
wikilog = be.get_wikitext()
|
||||||
except VCSException as vcse:
|
except VCSException as vcse:
|
||||||
print "VCS error while building app %s: %s" % (app['id'], vcse)
|
print "VCS error while building app %s: %s" % (app['id'], vcse)
|
||||||
if options.stop:
|
if options.stop:
|
||||||
|
@ -886,6 +886,20 @@ class BuildException(Exception):
|
|||||||
self.stdout = stdout
|
self.stdout = stdout
|
||||||
self.stderr = stderr
|
self.stderr = stderr
|
||||||
|
|
||||||
|
def get_wikitext(self):
|
||||||
|
ret = repr(self.value) + "\n"
|
||||||
|
if self.stdout:
|
||||||
|
ret += "=stdout=\n"
|
||||||
|
ret += "<pre>\n"
|
||||||
|
ret += str(self.stdout)
|
||||||
|
ret += "</pre>\n"
|
||||||
|
if self.stderr:
|
||||||
|
ret += "=stderr=\n"
|
||||||
|
ret += "<pre>\n"
|
||||||
|
ret += str(self.stderr)
|
||||||
|
ret += "</pre>\n"
|
||||||
|
return ret
|
||||||
|
|
||||||
def __str__(self):
|
def __str__(self):
|
||||||
ret = repr(self.value)
|
ret = repr(self.value)
|
||||||
if self.stdout:
|
if self.stdout:
|
||||||
|
Loading…
Reference in New Issue
Block a user