{% extends "layout.html" %}
{% block title %}inetutils PyPI Server{% endblock %}
{% block content %}

{% if packages %}
<h1>Available Packages</h1>
    <div class="rows">
        <span class="header">Name</span>
        <span class="header">Author</span>
        <span class="header">Latest</span>
    </div>

    <div class="clear"></div>

    {% for p in packages %}
    <div class="rows">
        <span class="item">
            <a href="{{ url_for('package', eggbasket=p.eggbasket, package_name=p.filepath.name) }}">{{ p.filepath.name }}</a>
        </span>
        <span class="item">
            {{ p.author }}
        </span>
        <span class="item">
            {% if p.current %}<a href="{{ url_for('package_get', eggbasket=p.eggbasket, package_name=p.filepath.name, filename=p.current.name) }}">{{ p.current.name }}{% endif %}</a>
        </span>
    </div>

    <div class="clear"></div>
    {% endfor %}
{% endif %}
{% endblock %}
