-<div class="panel panel-default">
- <div class="panel-heading">
- <div class="pull-right">
- <%= link_to raw('<i class="fa fa-plus"></i> Add new repository'), "#",
- {class: 'btn btn-xs btn-primary', 'data-toggle' => "modal",
- 'data-target' => '#add-repository-modal'} %>
- </div>
- <h4 class="panel-title">
- <%= link_to repositories_user_path(current_user) do%>
- Repositories
- <%end%>
- </h4>
- </div>
-
- <div id="manage_repositories" class="panel-body">
- <p>
- When you are using an Arvados virtual machine, you should clone the https:// URLs. This will authenticate automatically using your API token.
- </p>
- <p>
- In order to clone git repositories using SSH, <%= link_to ssh_keys_user_path(current_user) do%> add an SSH key to your account<%end%> and clone the git@ URLs.
- </p>
-
- <% if !@my_repositories.any? %>
- You do not seem to have access to any repositories. If you would like to request access, please contact your system admin.
- <% else %>
- <table class="table repositories-table">
- <colgroup>
- <col style="width: 5%" />
- <col style="width: 30%" />
- <col style="width: 60%" />
- <col style="width: 5%" />
- </colgroup>
- <thead>
- <tr>
- <th></th>
- <th> Name </th>
- <th> URL </th>
- <th></th>
- </tr>
- </thead>
- <tbody>
- <% @my_repositories.andand.each do |repo| %>
- <tr>
- <td>
- <%= render :partial => "show_object_button", :locals => {object: repo, size: 'xs' } %>
- </td>
- <td style="word-break:break-all;">
- <%= repo[:name] %>
- </td>
- <td style="word-break:break-all;">
- <code><%= repo.http_fetch_url %></code><br/>
- <code><%= @repo_writable[repo.uuid] ? repo.push_url : repo.fetch_url %></code>
- </td>
- <td>
- <% if repo.editable? %>
- <%= link_to(repository_path(id: repo.uuid), method: :delete, class: 'btn btn-sm', data: {confirm: "Really delete '#{repo.name || repo.uuid}'?"}) do %>
- <i class="fa fa-fw fa-trash-o"></i>
- <% end %>
- <% end %>
- </td>
- </tr>
- <% end %>
- </tbody>
- </table>
- <% end %>
- </div>
-</div>