Hash :
ab2b7fd2
Author :
Thomas de Grivel
Date :
2022-01-17T15:43:06
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71
<h2><%= gettext "Properties" %></h2>
<table class="table admin-properties">
<%= if @repo.public_access do %>
<tr>
<th><%= gettext "Git HTTP" %></th>
<td><%= Repository.http_url(@repo) %></td>
</tr>
<% end %>
<tr>
<th><%= gettext "Git SSH" %></th>
<td><%= Repository.ssh_url(@repo) %></td>
</tr>
<tr>
<th><%= gettext "Public access ?" %></th>
<td>
<%= if @repo.public_access do %>
<%= gettext "public" %>
<% else %>
<%= gettext "private" %>
<% end %>
</td>
</tr>
<tr>
<th><%= gettext "Description" %></th>
<td>
<%= if @repo.description do %>
<%= raw Earmark.as_html!(@repo.description) %>
<% end %>
</td>
</tr>
<tr>
<th>
<%= gettext "Users" %><br/>
<%= if Repository.owner?(@repo, @current_user) do %>
<%= link "-",
to: Routes.repository_path(@conn, :remove_user, @owner.slug.slug, Repository.splat(@repo)),
class: "btn btn-danger btn-sm" %>
<%= link "+",
to: Routes.repository_path(@conn, :add_user, @owner.slug.slug, Repository.splat(@repo)),
class: "btn btn-primary btn-sm" %>
<% end %>
</th>
<td>
<ul>
<%= for user <- @members do %>
<li>
<%= link user.slug.slug, to: Routes.slug_path(@conn, :show, user.slug.slug) %>
</li>
<% end %>
</ul>
</td>
</tr>
<%= if @git.tags do %>
<tr>
<th><%= gettext("Tags") %></th>
<td>
<ul>
<%= for tag <- @git.tags |> Enum.reverse() do %>
<li>
<%= link tag.tag, to: Routes.repository_path(@conn, :show, Repository.owner_slug(@repo), Repository.splat(@repo, ["_tag", tag.tag])) %>
</li>
<% end %>
</ul>
</td>
</tr>
<% end %>
<tr>
<th><%= gettext("Disk usage") %></th>
<td><%= disk_usage(@disk_usage) %></td>
</tr>
</table>