Changeset - 8924172b07ff
[Not reviewed]
default
0 4 0
Thomas De Schampheleire - 11 years ago 2015-04-06 21:05:05
thomas.de.schampheleire@gmail.com
summary: repeat repo type in front of clone URL

Repeatedly, users report cloning problems of the Kallithea sources on IRC,
caused by them assuming that it is a Git repository.

Try to solve this problem by repeating the repository tag, indicating 'hg'
or 'git' in front of the clone URL.

Additionally, decrease the font size of the URL a notch, and improve
alignment with the repotag by removing top/bottom padding.

To avoid duplication of the repotag logic, introduce a mako def for it.
4 files changed with 16 insertions and 13 deletions:
0 comments (0 inline, 0 general)
kallithea/public/css/style.css
Show inline comments
 
@@ -1276,8 +1276,8 @@ div.label-summary label {
 
#content div.box div.form div.fields div.field div.input input#clone_url,
 
#content div.box div.form div.fields div.field div.input input#clone_url_id
 
{
 
    font-size: 16px;
 
    padding: 2px;
 
    font-size: 14px;
 
    padding: 0 2px;
 
}
 

	
 
#content div.box div.form div.fields div.field div.file input {
kallithea/templates/base/base.html
Show inline comments
 
@@ -85,6 +85,15 @@
 
  </ul>
 
</%def>
 

	
 
<%def name="repotag(repo)">
 
  %if h.is_hg(repo):
 
    <span class="repotag" title="${_('Mercurial repository')}">hg</span>
 
  %endif
 
  %if h.is_git(repo):
 
    <span class="repotag" title="${_('Git repository')}">git</span>
 
  %endif
 
</%def>
 

	
 
<%def name="repo_context_bar(current=None, rev=None)">
 
  <% rev = None if rev == 'tip' else rev %>
 
  <%
 
@@ -103,12 +112,7 @@
 
  <!--- CONTEXT BAR -->
 
  <div id="context-bar" class="box">
 
      <h2>
 
        %if h.is_hg(c.db_repo):
 
          <span class="repotag">hg</span>
 
        %endif
 
        %if h.is_git(c.db_repo):
 
          <span class="repotag">git</span>
 
        %endif
 
        ${repotag(c.db_repo)}
 

	
 
        ## public/private
 
        %if c.db_repo.private:
kallithea/templates/data_table/_dt_elements.html
Show inline comments
 
@@ -2,6 +2,8 @@
 
## usage:
 
## <%namespace name="dt" file="/data_table/_dt_elements.html"/>
 

	
 
<%namespace name="base" file="/base/base.html"/>
 

	
 
<%def name="quick_menu(repo_name)">
 
  <ul class="menu_items hidden">
 
  ##<ul class="dropdown-menu" role="menu" aria-labelledby="dropdownMenu">
 
@@ -63,11 +65,7 @@
 
    <a href="${h.url('edit_repo' if admin else 'summary_home', repo_name=name)}">
 

	
 
    ##TYPE OF REPO
 
    %if h.is_hg(rtype):
 
        <span class="repotag" title="${_('Mercurial repository')}">hg</span>
 
    %elif h.is_git(rtype):
 
        <span class="repotag" title="${_('Git repository')}">git</span>
 
    %endif
 
    ${base.repotag(rtype)}
 

	
 
    ##PRIVATE/PUBLIC
 
    %if private and c.visual.show_private_icon:
kallithea/templates/summary/summary.html
Show inline comments
 
@@ -72,6 +72,7 @@ summary = lambda n:{False:'summary-short
 
                  <label>${_('Clone URL')}:</label>
 
                </div>
 
                <div class="input ${summary(c.show_stats)}">
 
                  ${self.repotag(c.db_repo)}
 
                  <input style="width:80%" type="text" id="clone_url" readonly="readonly" value="${c.clone_repo_url}"/>
 
                  <input style="display:none;width:80%" type="text" id="clone_url_id" readonly="readonly" value="${c.clone_repo_url_id}"/>
 
                  <div style="display:none" id="clone_by_name" class="btn btn-small">${_('Show by Name')}</div>
0 comments (0 inline, 0 general)