<h2 class="page-header well clearfix">
  <a class="h2 text-primitive" href="{{group_url(project.group) }}">{{project.group.display_name}}</a>
  » <a class="h2 text-primary" href="{{project_url(project)}}">{{project.display_name}}</a>
  {% if pagetitle %}
  » {{pagetitle}}
  {% endif %}
  {% include "squad/_subscribe.jinja2" %}          
</h2>
<ul class="page-header nav nav-pills">
  {% with url_name=request.resolver_match.url_name %}
  <li role="presentation" {% if url_name == 'project' %}class="active"{% endif %}>
    <a href="{{project_url(project)}}">
      {{ _('Project Summary') }}
    </a>
  </li>
  <li role="presentation" {% if url_name == 'build' or url_name == 'builds' or url_name == 'testrun' %}class="active"{% endif %}>
    <a href="{{project_section_url(project, 'builds')}}">
      {{ _('Builds') }}
    </a>
  </li>

  <li role="presentation" {% if url_name == 'metrics' %}class="active"{% endif %}>
    <a href="{{project_section_url(project, 'metrics')}}">
      {{ _('Metrics') }}
    </a>
  </li>

 <li role="presentation" {% if url_name == 'knownissues' %}class="active"{% endif %}>
    <a href="{{url('knownissues', args=[project.group.slug, project.slug])}}">
      {{ _('Known Issues') }}
    </a>
  </li>

  {% if project.writable_by(user) %}
  <li role="presentation" {% if 'project-settings' in url_name %}class="active"{% endif %}>
    <a href="{{project_section_url(project, 'project-settings')}}">
      {{ _('Project settings') }}
    </a>
  </li>
  {% endif %}

  {% endwith %}
</ul>
