Repository : http://git.fedorahosted.org/cgit/copr.git
On branch : master
commit c01e3ebd62218cc71a47ca5134bda539eb95a7ac Author: Adam Samalik asamalik@redhat.com Date: Mon Aug 3 13:21:46 2015 +0200
link to dist git hash
frontend/coprs_frontend/coprs/models.py | 8 +++++ .../coprs/templates/coprs/detail/build.html | 29 +++++++++++++++---- 2 files changed, 31 insertions(+), 6 deletions(-)
diff --git a/frontend/coprs_frontend/coprs/models.py b/frontend/coprs_frontend/coprs/models.py index 5d0c7b8..7e88a6a 100644 --- a/frontend/coprs_frontend/coprs/models.py +++ b/frontend/coprs_frontend/coprs/models.py @@ -614,6 +614,14 @@ class BuildChroot(db.Model, helpers.Serializer):
return "unknown"
+ @property + def dist_git_url(self): + if app.config["DIST_GIT_URL"]: + return "{}/{}.git/commit/?id={}".format(app.config["DIST_GIT_URL"], + self.build.package.dist_git_repo, + self.git_hash) + return None + def __str__(self): return "<BuildChroot: {}>".format(self.to_dict())
diff --git a/frontend/coprs_frontend/coprs/templates/coprs/detail/build.html b/frontend/coprs_frontend/coprs/templates/coprs/detail/build.html index 9956046..e5e59e3 100644 --- a/frontend/coprs_frontend/coprs/templates/coprs/detail/build.html +++ b/frontend/coprs_frontend/coprs/templates/coprs/detail/build.html @@ -1,6 +1,7 @@ {% extends "coprs/detail.html" %} {% from "coprs/detail/_builds_forms.html" import copr_build_cancel_form, copr_build_repeat_form, copr_build_delete_form %} {% from "coprs/detail/_describe_source.html" import describe_source %} +{% from "_helpers.html" import chroot_to_os_logo %} {% block title %}Build {{ build.id }} in {{ build.copr.owner.name }}/{{ build.copr.name }}{% endblock %} {%block project_breadcrumb %} <li> @@ -85,12 +86,15 @@ <h3> Build Source </h3> {{ describe_source(build) }}
+ </div> + <div class="col-sm-12"> <h3> Chroot Details </h3> <table class="table table-striped table-bordered"> <thead> <tr> - <th>Name</th> - <th>Source (Git Hash)</th> + <th>Chroot Name</th> + <th>Dist Git Source</th> + <th>Results</th> <th>Build Time</th> <th>State</th> </tr> @@ -99,14 +103,27 @@ {% for chroot in build.build_chroots %} <tr> <td> - {% if build.results %} - <a href="{{ build.results }}/{{ chroot.name }}/{{build.result_dir_name}}">{{ chroot.name }}</a> - {% else %} {{ chroot.name }} + </td> + <td> + {% if chroot.git_hash %} + <a href="{{chroot.dist_git_url}}"> + {{ chroot.git_hash[:7] }} + </a> + {% else %} + - {% endif %} </td> <td> - {{ chroot.git_hash }} + {% if build.results %} + <a href="{{ build.results }}/{{ chroot.name }}/{{build.result_dir_name}}"> + <span class="pficon pficon-folder-open"> + results + </span> + </a> + {% else %} + - + {% endif %} </td> <td> {{ chroot.started_on|time_ago(chroot.ended_on) }}
copr-commits@lists.fedorahosted.org