Login
4 branches 0 tags
Ben (Desktop/Arch) Removed CLAUDE.md, rather just write things myself 34f4401 1 month ago 186 Commits
rubhub / templates / project_tree.html
{% import "macros/markdown_content.html" as md %}
<html>
  <head>
    <title>{{ owner.name }}/{{ project.name }} - {{ current_path }}</title>
  </head>

  <body>
    {% include "partials/sidebar.html" %}
    <main>
      <section>
        <div class="page-header">
          <h1 class="project-header">
            <a href="{{ owner.uri() }}">{{ owner.name }}</a> /
            <a href="{{ project.uri() }}">{{ project.name }}</a> /
            <a href="{{ project.uri_tree(selected_branch, "") }}">Code</a>
          </h1>
        </div>

        {% include "partials/project_tabs.html" %}

        <div class="card">
          {% include "partials/repo_bar.html" %}

          {% if let Some(info) = info %}
          {% include "partials/commit_bar.html" %}
          {% endif %}

          <div class="file-browser">
            {% if path_parts.len() > 0 %}
            <div class="path-breadcrumb">
              <a href="{{ project.uri_tree(&selected_branch, "") }}">{{ project.slug }}</a>
              {% for (i, part) in path_parts.iter().enumerate() %}
                / <a href="{{ project.uri_tree(&selected_branch, &path_parts[..=i].join("/")) }}">{{ part }}</a>
              {% endfor %}
            </div>
            {% endif %}

            {% if let Some(parent) = parent_path %}
            <div class="tree-item parent">
              <a href="{{ project.uri_tree(&selected_branch, &parent) }}">
                <span class="icon i-folder"></span>
                <span class="name">..</span>
              </a>
            </div>
            {% endif %}

            {% for entry in tree_entries %}
            <div class="tree-item {% if entry.kind == EntryKind::Tree %}directory{% else %}file{% endif %} {% if entry.filename.starts_with(".") %}dotfile{% endif %}">
              {% if entry.kind == EntryKind::Tree %}
                <a href="{{ entry.uri_tree(&owner.slug, &project.slug, &selected_branch, &current_path) }}">
                  <span class="icon i-folder"></span>
                  <span class="name">{{ entry.filename }}</span>
                </a>
              {% else %}
                <a href="{{ entry.uri_blob(&owner.slug, &project.slug, &selected_branch, &current_path) }}">
                  <span class="icon i-file"></span>
                  <span class="name">{{ entry.filename }}</span>
                </a>
              {% endif %}
            </div>
            {% endfor %}
          </div>
          <br/>

          {% if let Some(readme_html) = readme_html %}
            {% call md::render(readme_frontmatter, readme_html) %}
          {% endif %}
        </div>
      </section>
    </main>
  </body>

</html>