[copr] master: By default, display user's owned coprs if logged in, otherwise all (f76dc72)
by bkabrda@fedoraproject.org
Repository : http://git.fedorahosted.org/cgit/copr.git
On branch : master
>---------------------------------------------------------------
commit f76dc72e4196f3c2b914789ddbd236af5428fd07
Author: Bohuslav Kabrda <bkabrda(a)redhat.com>
Date: Fri Jan 18 13:34:02 2013 +0100
By default, display user's owned coprs if logged in, otherwise all
>---------------------------------------------------------------
.../coprs/views/coprs_ns/coprs_general.py | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
diff --git a/coprs_frontend/coprs/views/coprs_ns/coprs_general.py b/coprs_frontend/coprs/views/coprs_ns/coprs_general.py
index c377e6a..b408d30 100644
--- a/coprs_frontend/coprs/views/coprs_ns/coprs_general.py
+++ b/coprs_frontend/coprs/views/coprs_ns/coprs_general.py
@@ -18,7 +18,10 @@ from coprs.logic import coprs_logic
@coprs_ns.route('/', defaults = {'page': 1})
@coprs_ns.route('/<int:page>/')
def coprs_show(page = 1):
- query = coprs_logic.CoprsLogic.get_multiple(flask.g.user)
+ if flask.g.user:
+ query = coprs_logic.CoprsLogic.get_multiple(flask.g.user, user_relation = 'owned', username = flask.g.user.name)
+ else:
+ query = coprs_logic.CoprsLogic.get_multiple(flask.g.user)
paginator = helpers.Paginator(query, query.count(), page)
coprs = paginator.sliced_query
11 years, 4 months
[copr] master: Always display the search field (da574e6)
by bkabrda@fedoraproject.org
Repository : http://git.fedorahosted.org/cgit/copr.git
On branch : master
>---------------------------------------------------------------
commit da574e66fa923b2d43a842a8a7d48882372c3400
Author: Bohuslav Kabrda <bkabrda(a)redhat.com>
Date: Fri Jan 18 13:31:15 2013 +0100
Always display the search field
>---------------------------------------------------------------
coprs_frontend/coprs/templates/layout.html | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/coprs_frontend/coprs/templates/layout.html b/coprs_frontend/coprs/templates/layout.html
index 23c96e3..87ebfff 100644
--- a/coprs_frontend/coprs/templates/layout.html
+++ b/coprs_frontend/coprs/templates/layout.html
@@ -10,11 +10,11 @@
<a href="/"><img id="logo" src="{{ url_for('static', filename='copr_logo.png') }}" alt="Copr Build System"></a>
<div class="login">
{% if g.user %}
- <span class="text">logged in as </span>{{ g.user.name }}
+ <div><span class="text">logged in as </span>{{ g.user.name }}</div>
{% else %}
<div><a href="{{ url_for('misc.login') }}">log in</a></div>
- <input class="rounded" type="text" name="search_text">
{% endif %}
+ <input class="rounded" type="text" name="search_text">
</div>
</div>
</div>
11 years, 4 months
[copr] master: Only display username bold (f7a7181)
by bkabrda@fedoraproject.org
Repository : http://git.fedorahosted.org/cgit/copr.git
On branch : master
>---------------------------------------------------------------
commit f7a7181d6d57156c68a40a896b4661746b7d69d7
Author: Bohuslav Kabrda <bkabrda(a)redhat.com>
Date: Fri Jan 18 13:30:07 2013 +0100
Only display username bold
>---------------------------------------------------------------
coprs_frontend/coprs/static/style-new.css | 4 ++++
coprs_frontend/coprs/templates/layout.html | 2 +-
2 files changed, 5 insertions(+), 1 deletions(-)
diff --git a/coprs_frontend/coprs/static/style-new.css b/coprs_frontend/coprs/static/style-new.css
index ade2ba1..9ed1715 100644
--- a/coprs_frontend/coprs/static/style-new.css
+++ b/coprs_frontend/coprs/static/style-new.css
@@ -35,6 +35,10 @@ div.login, div.login a {
float: right;
}
+div.login .text {
+ font-weight: normal;
+}
+
div.page, div.menu-inner {
width: 780px;
margin-left: auto;
diff --git a/coprs_frontend/coprs/templates/layout.html b/coprs_frontend/coprs/templates/layout.html
index 0e1f870..23c96e3 100644
--- a/coprs_frontend/coprs/templates/layout.html
+++ b/coprs_frontend/coprs/templates/layout.html
@@ -10,7 +10,7 @@
<a href="/"><img id="logo" src="{{ url_for('static', filename='copr_logo.png') }}" alt="Copr Build System"></a>
<div class="login">
{% if g.user %}
- logged in as {{ g.user.name }}
+ <span class="text">logged in as </span>{{ g.user.name }}
{% else %}
<div><a href="{{ url_for('misc.login') }}">log in</a></div>
<input class="rounded" type="text" name="search_text">
11 years, 4 months
[copr] master: Display user's copr count (3558098)
by bkabrda@fedoraproject.org
Repository : http://git.fedorahosted.org/cgit/copr.git
On branch : master
>---------------------------------------------------------------
commit 3558098f22a999cc51c9db5b5587be9a44df5688
Author: Bohuslav Kabrda <bkabrda(a)redhat.com>
Date: Fri Jan 18 13:21:32 2013 +0100
Display user's copr count
>---------------------------------------------------------------
coprs_frontend/coprs/models.py | 4 ++++
coprs_frontend/coprs/templates/coprs/show.html | 2 +-
2 files changed, 5 insertions(+), 1 deletions(-)
diff --git a/coprs_frontend/coprs/models.py b/coprs_frontend/coprs/models.py
index 9e2a67b..c9888ca 100644
--- a/coprs_frontend/coprs/models.py
+++ b/coprs_frontend/coprs/models.py
@@ -98,6 +98,10 @@ class User(db.Model, Serializer):
# enumerate here to prevent exposing credentials
return ['id', 'name']
+ @property
+ def coprs_count(self):
+ return Copr.query.filter_by(owner=self).count()
+
class Copr(db.Model, Serializer):
id = db.Column(db.Integer, primary_key = True)
diff --git a/coprs_frontend/coprs/templates/coprs/show.html b/coprs_frontend/coprs/templates/coprs/show.html
index 710f84b..4bbefa0 100644
--- a/coprs_frontend/coprs/templates/coprs/show.html
+++ b/coprs_frontend/coprs/templates/coprs/show.html
@@ -7,7 +7,7 @@
<div class="user-info">
<img src="{{ url_for('static', filename='default_user.png') }}" alt="User Image">
<p>{{ g.user.name }}</p>
- <p class="coprs-count">11{# TODO #}</p>
+ <p class="coprs-count">{{ g.user.coprs_count }}</p>
<p class="other-text">coprs</p>
</div>
{% endif %}
11 years, 4 months
[copr] master: Dont display the heading text on front page (87b7a27)
by bkabrda@fedoraproject.org
Repository : http://git.fedorahosted.org/cgit/copr.git
On branch : master
>---------------------------------------------------------------
commit 87b7a27f86474cecc2448d84fe1d54e84fdaada5
Author: Bohuslav Kabrda <bkabrda(a)redhat.com>
Date: Fri Jan 18 13:14:17 2013 +0100
Dont display the heading text on front page
>---------------------------------------------------------------
coprs_frontend/coprs/templates/layout.html | 1 -
1 files changed, 0 insertions(+), 1 deletions(-)
diff --git a/coprs_frontend/coprs/templates/layout.html b/coprs_frontend/coprs/templates/layout.html
index e6f88f6..0e1f870 100644
--- a/coprs_frontend/coprs/templates/layout.html
+++ b/coprs_frontend/coprs/templates/layout.html
@@ -19,7 +19,6 @@
</div>
</div>
<div class="page">
- <h1>{% block header %}Coprs Build System{% endblock %}</h1>
{% for message in get_flashed_messages() %}
<div class="flash">{{ message }}</div>
{% endfor %}
11 years, 4 months
[copr] master: Alter displaying list of coprs (9c7d40e)
by bkabrda@fedoraproject.org
Repository : http://git.fedorahosted.org/cgit/copr.git
On branch : master
>---------------------------------------------------------------
commit 9c7d40e1401233122f8c7210b7980526831b013f
Author: Bohuslav Kabrda <bkabrda(a)redhat.com>
Date: Fri Jan 18 13:13:41 2013 +0100
Alter displaying list of coprs
>---------------------------------------------------------------
coprs_frontend/coprs/static/default_user.png | Bin 0 -> 1961 bytes
coprs_frontend/coprs/static/style-new.css | 98 ++++++++++++++++++++++-
coprs_frontend/coprs/templates/coprs/show.html | 37 +++++----
3 files changed, 115 insertions(+), 20 deletions(-)
diff --git a/coprs_frontend/coprs/static/default_user.png b/coprs_frontend/coprs/static/default_user.png
new file mode 100644
index 0000000..31b6c60
Binary files /dev/null and b/coprs_frontend/coprs/static/default_user.png differ
diff --git a/coprs_frontend/coprs/static/style-new.css b/coprs_frontend/coprs/static/style-new.css
index 01bbe6e..ade2ba1 100644
--- a/coprs_frontend/coprs/static/style-new.css
+++ b/coprs_frontend/coprs/static/style-new.css
@@ -1,20 +1,27 @@
html, body {
font-family: Cantarell, "Droid Sans", Verdana, sans-serif;
- font-size: 0.9em;
+ font-size: 1em;
margin: 0px;
padding: 0px;
}
+a {
+ color: #3d69a8;
+ text-decoration: none;
+}
+
#logo {
position: relative;
top: 8px;
}
div.menu {
+ font-size: 0.9em;
background-image: url("header_background.png");
background-repeat: repeat-x;
height: 81px;
+ margin-bottom: 3em;
}
div.login, div.login a {
@@ -34,13 +41,94 @@ div.page, div.menu-inner {
margin-right: auto;
}
-div.grey-box {
+div.user-info {
+ width: 174px;
+ margin-right: 25px;
+ float: left;
+ border-right: 1px solid #c3c3c3;
+
+ color: #565656;
+ font-size: 1.5em;
+ font-weight: bold;
+}
+
+div.user-info .coprs-count {
+ margin: 0px;
+ font-size: 0.8em;
+}
+
+div.user-info .other-text {
+ margin: 0px;
+ font-size: 0.6em;
+}
+
+div.coprs-list-thin, div.coprs-list-thick {
+ float: left;
+}
+
+div.coprs-list-thin {
+ width: 580px;
+}
+
+div.coprs-list-thick {
+ width: 100%;
+}
+
+div.copr {
+ width: 100%;
+ background-color: #f9f9f9;
+ padding-top: 1em;
+ padding-bottom: 1em;
+
+ border-radius: 5px;
+ -moz-border-radius: 5px;
+ -webkit-border-radius: 5px;
+}
+
+div.copr * {
+ padding-left: 1em;
+ padding-right: 1em;
+}
+
+div.copr a {
+ font-size: 1.4em;
+ font-weight: bold;
+ display: block;
+}
+
+div.copr p {
+ margin-top: 0.3em;
+ margin-bottom: 0.3em;
+}
+
+div.copr .repos {
+ color: #808080;
+}
+
+div.add-copr {
background-color: #ececec;
+ padding: 0.5em;
+ margin-bottom: 0.6em;
+
+ color: #cccccc;
+ text-align: center;
+ vertical-align: middle;
+ font-size: 1.1em;
+ font-weight: bold;
+
+ border-radius: 5px;
+ -moz-border-radius: 5px;
+ -webkit-border-radius: 5px;
+}
+
+div.add-copr a {
+ text-decoration: none;
+ color: #666666;
}
input.rounded {
padding-left: 4px;
- border-radius:10px;
- -moz-border-radius:10px;
- -webkit-border-radius:10px;
+ border-radius: 10px;
+ -moz-border-radius: 10px;
+ -webkit-border-radius: 10px;
}
diff --git a/coprs_frontend/coprs/templates/coprs/show.html b/coprs_frontend/coprs/templates/coprs/show.html
index c0524f3..710f84b 100644
--- a/coprs_frontend/coprs/templates/coprs/show.html
+++ b/coprs_frontend/coprs/templates/coprs/show.html
@@ -3,20 +3,27 @@
{% block header %}Coprs List{% endblock %}
{% from "_helpers.html" import render_pagination %}
{% block body %}
- <a href={{ url_for('coprs_ns.copr_add') }}>Add a new Copr</a>
- {% for copr in coprs %}
- <div class=copr>
- <h2><a href="{{ url_for('coprs_ns.copr_detail', username = copr.owner.name, coprname = copr.name) }}">{{ copr.owner.name }}/{{ copr.name }}</a></h2>
- builds: {{ copr.build_count }}<br>
- {% if copr.repos %}
- repos: {{ copr.repos_list|length }}
- {% endif %}
- </div>
- {% else %}
- <p><em>Unbelievable. No entries here so far</em></p>
- {% endfor %}
- <div class=pagination>
- {{ render_pagination(request, paginator) }}
+ {% if g.user %}
+ <div class="user-info">
+ <img src="{{ url_for('static', filename='default_user.png') }}" alt="User Image">
+ <p>{{ g.user.name }}</p>
+ <p class="coprs-count">11{# TODO #}</p>
+ <p class="other-text">coprs</p>
+ </div>
+ {% endif %}
+ <div class="coprs-list-{% if g.user %}thin{% else %}thick{% endif %}">
+ <div class="add-copr">+ <a href={{ url_for('coprs_ns.copr_add') }}>add a new Copr</a></div>
+ {% for copr in coprs %}
+ <div class="copr">
+ <a href="{{ url_for('coprs_ns.copr_detail', username = copr.owner.name, coprname = copr.name) }}">{{ copr.owner.name }}/{{ copr.name }}</a>
+ <p>description blah blah blah</p>
+ <p class="repos">F18 blah blah</p>
+ </div>
+ {% else %}
+ <p>No coprs...</p>
+ {% endfor %}
+ <div class="pagination">
+ {{ render_pagination(request, paginator) }}
+ </div>
</div>
- <a href={{ url_for('coprs_ns.copr_add') }}>Add a new Copr</a>
{% endblock %}
11 years, 4 months
[copr] master: Start the styling... layout first (b7ff50a)
by bkabrda@fedoraproject.org
Repository : http://git.fedorahosted.org/cgit/copr.git
On branch : master
>---------------------------------------------------------------
commit b7ff50a54f1529d28265e0844e68688b91b4602b
Author: Bohuslav Kabrda <bkabrda(a)redhat.com>
Date: Fri Jan 18 12:01:47 2013 +0100
Start the styling... layout first
>---------------------------------------------------------------
coprs_frontend/coprs/static/copr_logo.png | Bin 0 -> 3411 bytes
coprs_frontend/coprs/static/header_background.png | Bin 0 -> 195 bytes
coprs_frontend/coprs/static/style-new.css | 46 +++++++++++++++++++++
coprs_frontend/coprs/templates/layout.html | 33 +++++++--------
4 files changed, 62 insertions(+), 17 deletions(-)
diff --git a/coprs_frontend/coprs/static/copr_logo.png b/coprs_frontend/coprs/static/copr_logo.png
new file mode 100644
index 0000000..4576f78
Binary files /dev/null and b/coprs_frontend/coprs/static/copr_logo.png differ
diff --git a/coprs_frontend/coprs/static/header_background.png b/coprs_frontend/coprs/static/header_background.png
new file mode 100644
index 0000000..61fcb6f
Binary files /dev/null and b/coprs_frontend/coprs/static/header_background.png differ
diff --git a/coprs_frontend/coprs/static/style-new.css b/coprs_frontend/coprs/static/style-new.css
new file mode 100644
index 0000000..01bbe6e
--- /dev/null
+++ b/coprs_frontend/coprs/static/style-new.css
@@ -0,0 +1,46 @@
+html, body {
+ font-family: Cantarell, "Droid Sans", Verdana, sans-serif;
+ font-size: 0.9em;
+
+ margin: 0px;
+ padding: 0px;
+}
+
+#logo {
+ position: relative;
+ top: 8px;
+}
+
+div.menu {
+ background-image: url("header_background.png");
+ background-repeat: repeat-x;
+ height: 81px;
+}
+
+div.login, div.login a {
+ color: white;
+ font-weight: bold;
+ text-align: right;
+ text-decoration: none;
+ line-height: 250%;
+
+ position: relative;
+ float: right;
+}
+
+div.page, div.menu-inner {
+ width: 780px;
+ margin-left: auto;
+ margin-right: auto;
+}
+
+div.grey-box {
+ background-color: #ececec;
+}
+
+input.rounded {
+ padding-left: 4px;
+ border-radius:10px;
+ -moz-border-radius:10px;
+ -webkit-border-radius:10px;
+}
diff --git a/coprs_frontend/coprs/templates/layout.html b/coprs_frontend/coprs/templates/layout.html
index a9c6c6b..e6f88f6 100644
--- a/coprs_frontend/coprs/templates/layout.html
+++ b/coprs_frontend/coprs/templates/layout.html
@@ -1,30 +1,29 @@
<!doctype html>
<html>
<head>
- <title>{% block title %}Coprs Build System{% endblock %}</title>
-<link rel=stylesheet type=text/css href="{{ url_for('static', filename='style.css') }}">
+ <title>{% block title %}Coprs Build System{% endblock %}</title>
+ <link rel=stylesheet type=text/css href="{{ url_for('static', filename='style-new.css') }}">
</head>
<body>
-<div class=menu>
- <div class=menu-inner>
- {% block menu %}
- <a href="{{ url_for('coprs_ns.coprs_show') }}">All Coprs</a>
- {% if g.user %}
- <a href="{{ url_for('coprs_ns.coprs_by_owner', username = g.user.name) }}">Owned Coprs</a>
- <a href="{{ url_for('coprs_ns.coprs_by_allowed', username = g.user.name) }}">Coprs I Can Build In</a>
- <a class=log-url href="{{ url_for('misc.logout') }}">Log out</a>
- {% else %}
- <a class=log-url href="{{ url_for('misc.login') }}">Log in</a>
- {% endif %}
- {% endblock %}
+<div class="menu">
+ <div class="menu-inner">
+ <a href="/"><img id="logo" src="{{ url_for('static', filename='copr_logo.png') }}" alt="Copr Build System"></a>
+ <div class="login">
+ {% if g.user %}
+ logged in as {{ g.user.name }}
+ {% else %}
+ <div><a href="{{ url_for('misc.login') }}">log in</a></div>
+ <input class="rounded" type="text" name="search_text">
+ {% endif %}
+ </div>
</div>
</div>
-<div class=page>
+<div class="page">
<h1>{% block header %}Coprs Build System{% endblock %}</h1>
{% for message in get_flashed_messages() %}
- <div class=flash>{{ message }}</div>
+ <div class="flash">{{ message }}</div>
{% endfor %}
- <div class=page-inner>
+ <div class="page-inner">
{% block body %}{% endblock %}
</div>
</div>
11 years, 4 months
handling lots of builds on the same copr and same distro/chroots
by Seth Vidal
So I'm trying to figure out how to sensibly handle the following
situation:
user creates a new copr with fedora-16-i386 and fedora-16-x86_64
submits 3 pkgs to build: - that's buildid 45
submits 4 more pkgs to build: that's buildid 46
submits 2 more pkgs to build: that's buildid 47
If they are all building at the same time - then we're going to have a
conflict when createrepo will try to run (to say nothing of rsync for
syncing pkgs over).
I was thinking of tracking per-copr builds and locking the build process
such that if the copr has a build active another one cannot be added to
the queue until the earlier one has finished.
That's going to involve moving some code around so I can track which
builds are active a bit more easily.
Anyone have any better ideas?
Thanks,
-sv
11 years, 4 months
access to build logs, is there any?
by Troy Dawson
Hi,
I guess the subject says most everything.
I had a package that continued to fail despite it building for me
locally. I tried my hardest to figure out how to see the logs to see
what it was failing on, but I was unsuccessful.
Is there a way for a user to see the logs from their builds?
I don't mind if the answer is no.
But if the answer is yes, can you let me know how.
Thanks
Troy
11 years, 4 months