<%namespace name="base" file="/base/base.mako"/> <% elems = [ (_('Repository ID'), c.rhodecode_db_repo.repo_id, '', ''), (_('Owner'), lambda:base.gravatar_with_user(c.rhodecode_db_repo.user.email), '', ''), (_('Created on'), h.format_date(c.rhodecode_db_repo.created_on), '', ''), (_('Updated on'), h.format_date(c.rhodecode_db_repo.updated_on), '', ''), (_('Cached Commit id'), lambda: h.link_to(c.rhodecode_db_repo.changeset_cache.get('short_id'), h.route_path('repo_commit',repo_name=c.repo_name,commit_id=c.rhodecode_db_repo.changeset_cache.get('raw_id'))), '', ''), (_('Attached scoped tokens'), len(c.rhodecode_db_repo.scoped_tokens), '', [x.user for x in c.rhodecode_db_repo.scoped_tokens]), (_('Pull requests source'), len(c.rhodecode_db_repo.pull_requests_source), '', ['pr_id:{}, repo:{}'.format(x.pull_request_id,x.source_repo.repo_name) for x in c.rhodecode_db_repo.pull_requests_source]), (_('Pull requests target'), len(c.rhodecode_db_repo.pull_requests_target), '', ['pr_id:{}, repo:{}'.format(x.pull_request_id,x.target_repo.repo_name) for x in c.rhodecode_db_repo.pull_requests_target]), ] %>

${_('Repository: %s') % c.rhodecode_db_repo.repo_name}

${base.dt_info_panel(elems)}

${_('Fork Reference')}

${h.secure_form(h.route_path('edit_repo_advanced_fork', repo_name=c.rhodecode_db_repo.repo_name), request=request)} % if c.rhodecode_db_repo.fork:
${h.literal(_('This repository is a fork of %(repo_link)s') % {'repo_link': h.link_to_if(c.has_origin_repo_read_perm,c.rhodecode_db_repo.fork.repo_name, h.route_path('repo_summary', repo_name=c.rhodecode_db_repo.fork.repo_name))})} |
% endif
${h.hidden('id_fork_of')} ${h.submit('set_as_fork_%s' % c.rhodecode_db_repo.repo_name,_('Set'),class_="btn btn-small",)}
${_('Manually set this repository as a fork of another from the list')}
${h.end_form()}

${_('Public Journal Visibility')}

${h.secure_form(h.route_path('edit_repo_advanced_journal', repo_name=c.rhodecode_db_repo.repo_name), request=request)}
%if c.in_public_journal: %else: %endif
${_('All actions made on this repository will be visible to everyone following the public journal.')}
${h.end_form()}

${_('Locking state')}

${h.secure_form(h.route_path('edit_repo_advanced_locking', repo_name=c.rhodecode_db_repo.repo_name), request=request)} %if c.rhodecode_db_repo.locked[0]:
${'Locked by %s on %s. Lock reason: %s' % (h.person_by_id(c.rhodecode_db_repo.locked[0]), h.format_date(h. time_to_datetime(c.rhodecode_db_repo.locked[1])), c.rhodecode_db_repo.locked[2])}
%else:
${_('This Repository is not currently locked.')}
%endif
%if c.rhodecode_db_repo.locked[0]: ${h.hidden('set_unlock', '1')} %else: ${h.hidden('set_lock', '1')} %endif
${_('Force repository locking. This only works when anonymous access is disabled. Pulling from the repository locks the repository to that user until the same user pushes to that repository again.')}
${h.end_form()}

${_('Hooks')}

% if c.ver_info_dict: % else: % endif
${_('Hook type')} ${_('Hook version')} ${_('Current version')}
${_('PRE HOOK')} ${c.ver_info_dict['pre_version']} ${c.rhodecode_version}
${_('POST HOOK')} ${c.ver_info_dict['post_version']} ${c.rhodecode_version}
${_('Unable to read hook information from VCS Server')}
${_('Update Hooks')}

${_('Archive repository')}

${h.secure_form(h.route_path('edit_repo_advanced_archive', repo_name=c.repo_name), request=request)}
${_('Archiving the repository will make it entirely read-only. The repository cannot be committed to.' 'It is hidden from the search results and dashboard. ')}
${h.end_form()}

${_('Delete repository')}

${h.secure_form(h.route_path('edit_repo_advanced_delete', repo_name=c.repo_name), request=request)} <% attached_prs = len(c.rhodecode_db_repo.pull_requests_source + c.rhodecode_db_repo.pull_requests_target) %> % if c.rhodecode_db_repo.pull_requests_source or c.rhodecode_db_repo.pull_requests_target: % endif
${_ungettext('This repository has %s fork.', 'This repository has %s forks.', c.rhodecode_db_repo.forks.count()) % c.rhodecode_db_repo.forks.count()} %if c.rhodecode_db_repo.forks.count(): %endif %if c.rhodecode_db_repo.forks.count(): %endif
${_ungettext('This repository has %s attached pull request.', 'This repository has %s attached pull requests.', attached_prs) % attached_prs}
${_('Consider to archive this repository instead.')}
${_('This repository will be renamed in a special way in order to make it inaccessible to RhodeCode Enterprise and its VCS systems. If you need to fully delete it from the file system, please do it manually, or with rhodecode-cleanup-repos command available in rhodecode-tools.')}
${h.end_form()}