[copr] master: typo s/submited/submitted/ (e7739e9)
by Miroslav Suchý
Repository : http://git.fedorahosted.org/cgit/copr.git
On branch : master
>---------------------------------------------------------------
commit e7739e949d731b653232cd079edd0f3e83251518
Author: Miroslav Suchý <msuchy(a)redhat.com>
Date: Wed Oct 30 14:04:18 2013 +0100
typo s/submited/submitted/
>---------------------------------------------------------------
.../coprs/templates/coprs/_coprs_forms.html | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/coprs_frontend/coprs/templates/coprs/_coprs_forms.html b/coprs_frontend/coprs/templates/coprs/_coprs_forms.html
index fb7e368..ae57bef 100644
--- a/coprs_frontend/coprs/templates/coprs/_coprs_forms.html
+++ b/coprs_frontend/coprs/templates/coprs/_coprs_forms.html
@@ -30,7 +30,7 @@
{% endfor %}
{{ render_field(form.repos, rows=5, cols=50, placeholder='Optional - URL to additional yum repos, which can be used during build. Space separated.') }}
{% if copr is none %}{# we're creating the copr, so display initial builds area #}
- {{ render_field(form.initial_pkgs, rows=5, cols=50, placeholder='Optional - list of src.rpm to build initially. Can be skipped and submited later.') }}
+ {{ render_field(form.initial_pkgs, rows=5, cols=50, placeholder='Optional - list of src.rpm to build initially. Can be skipped and submitted later.') }}
{% endif %}
<dt><input type="submit" value="{% if copr %}Update{% else %}Create{% endif %}"></dt>
</dl>
10 years, 5 months
[copr] master: UX - show details of build only after click (9d02b61)
by Miroslav Suchý
Repository : http://git.fedorahosted.org/cgit/copr.git
On branch : master
>---------------------------------------------------------------
commit 9d02b61f5b75b658ff379f3e9b6f112bdb15e14d
Author: Miroslav Suchý <msuchy(a)redhat.com>
Date: Wed Oct 30 13:12:59 2013 +0100
UX - show details of build only after click
and decorate hovered line with underline
>---------------------------------------------------------------
coprs_frontend/coprs/static/copr.css | 4 ++++
coprs_frontend/coprs/static/copr.js | 8 ++++----
.../templates/coprs/detail/_builds_table.html | 2 +-
3 files changed, 9 insertions(+), 5 deletions(-)
diff --git a/coprs_frontend/coprs/static/copr.css b/coprs_frontend/coprs/static/copr.css
index cde5420..38059dc 100644
--- a/coprs_frontend/coprs/static/copr.css
+++ b/coprs_frontend/coprs/static/copr.css
@@ -266,6 +266,10 @@ table.builds-table tr.details {
display: none;
}
+tr.build-state:hover {
+ text-decoration: underline;
+}
+
tr.build-pending {
color: #3B6EB4;
}
diff --git a/coprs_frontend/coprs/static/copr.js b/coprs_frontend/coprs/static/copr.js
index cb09b34..41b9fd6 100644
--- a/coprs_frontend/coprs/static/copr.js
+++ b/coprs_frontend/coprs/static/copr.js
@@ -1,20 +1,20 @@
// showing build details
$(document).ready(function () {
$("table.builds-table tr[class^='build-']").each(function (i, e) {
- $(this).hover(function() { $("table.builds-table tr.details").hide(); $(this).next().show(); });
+ $(this).click(function() { $("table.builds-table tr.details").hide(); $(this).next().show(); });
});
});
// build detail menu arrow slider
$(document).ready(function() {
- $("div.horizontal-menu li").hover(
+ $("div.horizontal-menu li").click(
function() {
$("div.horizontal-menu li.selected").removeClass('selected').addClass('left-for-now');
- $(this).toggleClass('hovered');
+ $(this).toggleClass('clicked');
},
function() {
$("div.horizontal-menu li.left-for-now").removeClass('left-for-now').addClass('selected');
- $(this).toggleClass('hovered');
+ $(this).toggleClass('clicked');
}
);
});
diff --git a/coprs_frontend/coprs/templates/coprs/detail/_builds_table.html b/coprs_frontend/coprs/templates/coprs/detail/_builds_table.html
index cc0d842..f65d7ed 100644
--- a/coprs_frontend/coprs/templates/coprs/detail/_builds_table.html
+++ b/coprs_frontend/coprs/templates/coprs/detail/_builds_table.html
@@ -12,7 +12,7 @@
<th>State</th>
</tr>
{% for build in builds %}
- <tr class="build-{{ build.state }}">
+ <tr class="build-{{ build.state }} build-state">
<td>{{ build.id }}</td>
<td>{{ build.submitted_on|date_from_secs }}</td>
<td>{{ build.user.name }}</td>
10 years, 5 months
[copr] master: add link to FAQ to footer (f7b3383)
by Miroslav Suchý
Repository : http://git.fedorahosted.org/cgit/copr.git
On branch : master
>---------------------------------------------------------------
commit f7b33835694207ad02fe6c8f5948c410d3706bb5
Author: Miroslav Suchý <msuchy(a)redhat.com>
Date: Wed Oct 30 11:59:10 2013 +0100
add link to FAQ to footer
>---------------------------------------------------------------
coprs_frontend/coprs/templates/layout.html | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/coprs_frontend/coprs/templates/layout.html b/coprs_frontend/coprs/templates/layout.html
index 3573134..982fdb7 100644
--- a/coprs_frontend/coprs/templates/layout.html
+++ b/coprs_frontend/coprs/templates/layout.html
@@ -35,6 +35,7 @@
<p>
<a href="{{ url_for('coprs_ns.coprs_show') }}">Home</a>
<a href="https://fedorahosted.org/copr/">Copr Project</a>
+ <a href="https://fedorahosted.org/copr/wiki/UserDocs#FAQ">FAQ</a>
<a class="last" href="{{ url_for('api_ns.api_home') }}">API</a>
</p>
</div>
10 years, 5 months
[copr] master: UX - add placeholders (f018838)
by Miroslav Suchý
Repository : http://git.fedorahosted.org/cgit/copr.git
On branch : master
>---------------------------------------------------------------
commit f018838c383e2e99dff747c92bc8686af9e17fa5
Author: Miroslav Suchý <msuchy(a)redhat.com>
Date: Wed Oct 30 11:14:17 2013 +0100
UX - add placeholders
>---------------------------------------------------------------
.../coprs/templates/coprs/_coprs_forms.html | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/coprs_frontend/coprs/templates/coprs/_coprs_forms.html b/coprs_frontend/coprs/templates/coprs/_coprs_forms.html
index 4d3e7ab..fb7e368 100644
--- a/coprs_frontend/coprs/templates/coprs/_coprs_forms.html
+++ b/coprs_frontend/coprs/templates/coprs/_coprs_forms.html
@@ -13,8 +13,8 @@
{{ form.csrf_token }}
{{ render_field(form.id, hidden = True) }}
{{ render_field(form.name, label='Project Name', required = True, class="required") }}
- {{ render_field(form.description, rows=5, cols=50) }}
- {{ render_field(form.instructions, rows=5, cols=50) }}
+ {{ render_field(form.description, rows=5, cols=50, placeholder='Optional - describe your project briefly.') }}
+ {{ render_field(form.instructions, rows=5, cols=50, placeholder='Optional - describe how your project can be installed. Link to wiki is good as well.') }}
<dt class="field-label required">Chroots</dt>
{% if form._mock_chroots_error %}
<p class="form-error">{{ form._mock_chroots_error }}</p>
@@ -28,9 +28,9 @@
{% endfor %}
</table>
{% endfor %}
- {{ render_field(form.repos, rows=5, cols=50) }}
+ {{ render_field(form.repos, rows=5, cols=50, placeholder='Optional - URL to additional yum repos, which can be used during build. Space separated.') }}
{% if copr is none %}{# we're creating the copr, so display initial builds area #}
- {{ render_field(form.initial_pkgs, rows=5, cols=50) }}
+ {{ render_field(form.initial_pkgs, rows=5, cols=50, placeholder='Optional - list of src.rpm to build initially. Can be skipped and submited later.') }}
{% endif %}
<dt><input type="submit" value="{% if copr %}Update{% else %}Create{% endif %}"></dt>
</dl>
10 years, 5 months
[copr] master: UX - add asterisk to required fields (d0e36f8)
by Miroslav Suchý
Repository : http://git.fedorahosted.org/cgit/copr.git
On branch : master
>---------------------------------------------------------------
commit d0e36f8422dc25bb23a4cff55b5e95eaceb9e1f3
Author: Miroslav Suchý <msuchy(a)redhat.com>
Date: Wed Oct 30 09:09:38 2013 +0100
UX - add asterisk to required fields
In add new project field only.
Create new class "required" which automatically add red asterisk before
the tag.
Additionally add to this form required attribute, which move validation to browser.
>---------------------------------------------------------------
coprs_frontend/coprs/static/copr.css | 7 +++++++
coprs_frontend/coprs/templates/_helpers.html | 4 ++--
.../coprs/templates/coprs/_coprs_forms.html | 4 ++--
3 files changed, 11 insertions(+), 4 deletions(-)
diff --git a/coprs_frontend/coprs/static/copr.css b/coprs_frontend/coprs/static/copr.css
index 61a87d3..cde5420 100644
--- a/coprs_frontend/coprs/static/copr.css
+++ b/coprs_frontend/coprs/static/copr.css
@@ -360,3 +360,10 @@ hr {
.footer .last {
border-right: none;
}
+
+.required:before {
+ content: "* ";
+ color: red;
+ font-weight: bold;
+}
+
diff --git a/coprs_frontend/coprs/templates/_helpers.html b/coprs_frontend/coprs/templates/_helpers.html
index 487a5dc..04630bb 100644
--- a/coprs_frontend/coprs/templates/_helpers.html
+++ b/coprs_frontend/coprs/templates/_helpers.html
@@ -1,6 +1,6 @@
-{% macro render_field(field, label=None) %}
+{% macro render_field(field, label=None, class='') %}
{% if not kwargs['hidden'] %}
- <dt class="field-label">{{ label or field.label }}</dt>
+ <dt class="field-label {{ class }}">{{ label or field.label }}</dt>
<dd>
{% if field.errors %}
{% for error in field.errors %}
diff --git a/coprs_frontend/coprs/templates/coprs/_coprs_forms.html b/coprs_frontend/coprs/templates/coprs/_coprs_forms.html
index 6fe89d9..4d3e7ab 100644
--- a/coprs_frontend/coprs/templates/coprs/_coprs_forms.html
+++ b/coprs_frontend/coprs/templates/coprs/_coprs_forms.html
@@ -12,10 +12,10 @@
<dl>
{{ form.csrf_token }}
{{ render_field(form.id, hidden = True) }}
- {{ render_field(form.name, label='Project Name') }}
+ {{ render_field(form.name, label='Project Name', required = True, class="required") }}
{{ render_field(form.description, rows=5, cols=50) }}
{{ render_field(form.instructions, rows=5, cols=50) }}
- <dt class="field-label">Chroots</dt>
+ <dt class="field-label required">Chroots</dt>
{% if form._mock_chroots_error %}
<p class="form-error">{{ form._mock_chroots_error }}</p>
{% endif %}
10 years, 5 months
[copr] master: dynamicly generate url for home (14ea610)
by Miroslav Suchý
Repository : http://git.fedorahosted.org/cgit/copr.git
On branch : master
>---------------------------------------------------------------
commit 14ea6101dd21bdf957cfd6caf89b6f53f887ab0d
Author: Miroslav Suchý <msuchy(a)redhat.com>
Date: Tue Oct 29 23:00:13 2013 +0100
dynamicly generate url for home
this will help when copr is not only one application in web server and have some relative path
>---------------------------------------------------------------
coprs_frontend/coprs/templates/layout.html | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/coprs_frontend/coprs/templates/layout.html b/coprs_frontend/coprs/templates/layout.html
index 4c2a903..3573134 100644
--- a/coprs_frontend/coprs/templates/layout.html
+++ b/coprs_frontend/coprs/templates/layout.html
@@ -9,7 +9,7 @@
<body>
<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>
+ <a href="{{ url_for('coprs_ns.coprs_show') }}"><img id="logo" src="{{ url_for('static', filename='copr_logo.png') }}" alt="Copr Build System"></a>
<div class="login">
{% if g.user %}
<div><span class="text">logged in as </span>{{ g.user.name }} | <a href="{{ url_for('misc.logout') }}">log out</a></div>
10 years, 5 months
[copr] master: add footer (af93467)
by Miroslav Suchý
Repository : http://git.fedorahosted.org/cgit/copr.git
On branch : master
>---------------------------------------------------------------
commit af934676b9773d0b03020674a456c64f75f7d9ac
Author: Miroslav Suchý <msuchy(a)redhat.com>
Date: Tue Oct 29 22:59:01 2013 +0100
add footer
>---------------------------------------------------------------
coprs_frontend/coprs/static/copr.css | 3 ++-
coprs_frontend/coprs/templates/layout.html | 7 +++++++
2 files changed, 9 insertions(+), 1 deletions(-)
diff --git a/coprs_frontend/coprs/static/copr.css b/coprs_frontend/coprs/static/copr.css
index e7be7e3..61a87d3 100644
--- a/coprs_frontend/coprs/static/copr.css
+++ b/coprs_frontend/coprs/static/copr.css
@@ -342,7 +342,8 @@ hr {
.footer {
padding: 25px;
- background: #f2f2f2;
+ background: white;
+ font-size: 0.8em;
}
.footer p {
diff --git a/coprs_frontend/coprs/templates/layout.html b/coprs_frontend/coprs/templates/layout.html
index 6312d49..4c2a903 100644
--- a/coprs_frontend/coprs/templates/layout.html
+++ b/coprs_frontend/coprs/templates/layout.html
@@ -31,5 +31,12 @@
{% block body %}{% endblock %}
</div>
</div>
+<div class="footer">
+<p>
+ <a href="{{ url_for('coprs_ns.coprs_show') }}">Home</a>
+ <a href="https://fedorahosted.org/copr/">Copr Project</a>
+ <a class="last" href="{{ url_for('api_ns.api_home') }}">API</a>
+</p>
+</div>
</body>
</html>
10 years, 5 months
[copr] master: Automatic commit of package [copr] release [1.11-1]. (5b54cc2)
by Miroslav Suchý
Repository : http://git.fedorahosted.org/cgit/copr.git
On branch : master
>---------------------------------------------------------------
commit 5b54cc21e7fae529cab8280b1f09adb6d54e89d7
Author: Miroslav Suchý <msuchy(a)redhat.com>
Date: Sat Oct 26 00:58:58 2013 +0200
Automatic commit of package [copr] release [1.11-1].
>---------------------------------------------------------------
copr.spec | 5 ++++-
rel-eng/packages/copr | 2 +-
2 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/copr.spec b/copr.spec
index b5f0797..57fcb5b 100644
--- a/copr.spec
+++ b/copr.spec
@@ -5,7 +5,7 @@
%global modulename copr
Name: copr
-Version: 1.10
+Version: 1.11
Release: 1%{?dist}
Summary: Cool Other Package Repo
@@ -380,6 +380,9 @@ fi
%{_mandir}/man8/%{name}-selinux-relabel.8*
%changelog
+* Sat Oct 26 2013 Miroslav Suchý <msuchy(a)redhat.com> 1.11-1
+- catch IOError from libravatar if there is no network
+
* Fri Oct 25 2013 Miroslav Suchý <msuchy(a)redhat.com> 1.10-1
- do not normalize url
- specify full prefix of http
diff --git a/rel-eng/packages/copr b/rel-eng/packages/copr
index 412af9b..c8db600 100644
--- a/rel-eng/packages/copr
+++ b/rel-eng/packages/copr
@@ -1 +1 @@
-1.10-1 ./
+1.11-1 ./
10 years, 5 months
[copr] master: catch IOError from libravatar if there is no network (02ac057)
by Miroslav Suchý
Repository : http://git.fedorahosted.org/cgit/copr.git
On branch : master
>---------------------------------------------------------------
commit 02ac05793fef7485e9475a55f07eb017d2fdeca2
Author: Miroslav Suchý <msuchy(a)redhat.com>
Date: Sat Oct 26 00:12:25 2013 +0200
catch IOError from libravatar if there is no network
otherwise libravatar will fail with:
self = <coprs.models.User object at 0xa80e44c>
@property
def gravatar_url(self):
"""Return url to libravatar image."""
> return libravatar_url(email = self.mail)
coprs/models.py:133:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
email = u'user1(a)foo.bar', openid = None, https = False, default = None
size = None
def libravatar_url(email=None, openid=None, https=False,
default=None, size=None):
"""
Return a URL to the appropriate avatar
"""
avatar_hash, domain = parse_user_identity(email, openid)
query_string = parse_options(default, size)
> delegation_server = lookup_avatar_server(domain, https)
/usr/lib/python2.7/site-packages/libravatar.py:60:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
domain = u'foo.bar', https = False
def lookup_avatar_server(domain, https):
"""
Extract the avatar server from an SRV record in the DNS zone
The SRV records should look like this:
_avatars._tcp.example.com. IN SRV 0 0 80 avatars.example.com
_avatars-sec._tcp.example.com. IN SRV 0 0 443 avatars.example.com
"""
> DNS.DiscoverNameServers()
/usr/lib/python2.7/site-packages/libravatar.py:165:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
def DiscoverNameServers():
import sys
if sys.platform in ('win32', 'nt'):
import win32dns
defaults['server']=win32dns.RegistryResolve()
else:
> return ParseResolvConf()
/usr/lib/python2.7/site-packages/DNS/Base.py:78:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
resolv_path = '/etc/resolv.conf'
def ParseResolvConf(resolv_path="/etc/resolv.conf"):
"parses the /etc/resolv.conf file and sets defaults for name servers"
global defaults
> lines=open(resolv_path).readlines()
E IOError: [Errno 2] No such file or directory: '/etc/resolv.conf'
>---------------------------------------------------------------
coprs_frontend/coprs/models.py | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
diff --git a/coprs_frontend/coprs/models.py b/coprs_frontend/coprs/models.py
index 002ebcb..11e9073 100644
--- a/coprs_frontend/coprs/models.py
+++ b/coprs_frontend/coprs/models.py
@@ -130,7 +130,10 @@ class User(db.Model, Serializer):
@property
def gravatar_url(self):
"""Return url to libravatar image."""
- return libravatar_url(email = self.mail)
+ try:
+ return libravatar_url(email = self.mail)
+ except IOError:
+ return ""
class Copr(db.Model, Serializer):
10 years, 5 months