Merge branch 'koh'
Conflicts: auth/scopes.py requirements-nover.txt requirements.txt static/css/quay.css static/directives/namespace-selector.html static/js/app.js static/partials/manage-application.html templates/oauthorize.html
This commit is contained in:
		
						commit
						f3259c862b
					
				
					 57 changed files with 537 additions and 141 deletions
				
			
		|  | @ -1,5 +0,0 @@ | |||
| import hashlib | ||||
| 
 | ||||
| 
 | ||||
| def compute_hash(email_address): | ||||
|   return hashlib.md5(email_address.strip().lower()).hexdigest() | ||||
|  | @ -1,6 +1,5 @@ | |||
| from app import get_app_url | ||||
| from app import get_app_url, avatar | ||||
| from data import model | ||||
| from util.gravatar import compute_hash | ||||
| from util.names import parse_robot_username | ||||
| from jinja2 import Template, Environment, FileSystemLoader, contextfilter | ||||
| 
 | ||||
|  | @ -25,10 +24,10 @@ def user_reference(username): | |||
|   alt = 'Organization' if user.organization else 'User' | ||||
|   return """ | ||||
|   <span> | ||||
|   <img src="http://www.gravatar.com/avatar/%s?s=16&d=identicon" | ||||
|   <img src="%s" | ||||
|       style="vertical-align: middle; margin-left: 6px; margin-right: 4px;" alt="%s"> | ||||
|   <b>%s</b> | ||||
|   </span>""" % (compute_hash(user.email), alt, username) | ||||
|   </span>""" % (avatar.get_url(user.email, 16), alt, username) | ||||
| 
 | ||||
| 
 | ||||
| def repository_tag_reference(repository_path_and_tag): | ||||
|  | @ -55,10 +54,10 @@ def repository_reference(pair): | |||
| 
 | ||||
|   return """ | ||||
|   <span style="white-space: nowrap;"> | ||||
|   <img src="http://www.gravatar.com/avatar/%s?s=16&d=identicon" style="vertical-align: middle; margin-left: 6px; margin-right: 4px;"> | ||||
|   <img src="%s" style="vertical-align: middle; margin-left: 6px; margin-right: 4px;"> | ||||
|   <a href="%s/repository/%s/%s">%s/%s</a> | ||||
|   </span> | ||||
|   """ % (compute_hash(owner.email), get_app_url(), namespace, repository, namespace, repository) | ||||
|   """ % (avatar.get_url(owner.email, 16), get_app_url(), namespace, repository, namespace, repository) | ||||
| 
 | ||||
| 
 | ||||
| def admin_reference(username): | ||||
|  |  | |||
|  | @ -5,7 +5,6 @@ from flask.ext.mail import Message | |||
| 
 | ||||
| from app import mail, app, get_app_url | ||||
| from data import model | ||||
| from util.gravatar import compute_hash | ||||
| from util.jinjautil import get_template_env | ||||
| 
 | ||||
| logger = logging.getLogger(__name__) | ||||
|  |  | |||
		Reference in a new issue