summaryrefslogtreecommitdiff
path: root/templates
diff options
context:
space:
mode:
authorDan McGee <dan@archlinux.org>2012-07-23 09:45:44 -0500
committerDan McGee <dan@archlinux.org>2012-07-23 09:55:46 -0500
commit946d90d08f29094153142056a1778cd595e568a3 (patch)
treea01ce81fd31d617aec5d4f962e976fe44a3462cf /templates
parent872d4bcaa2ce85d2d319a1146e0fc05ab6808eb9 (diff)
Add '410 Gone' support for packages moved out of repositories
This allows us to do better than a generic 404 handler when we know a package previously existed in a given repository, and should also make things a bit nicer when getting sent in from a search engine to a page that no longer exists. Signed-off-by: Dan McGee <dan@archlinux.org>
Diffstat (limited to 'templates')
-rw-r--r--templates/packages/removed.html28
1 files changed, 28 insertions, 0 deletions
diff --git a/templates/packages/removed.html b/templates/packages/removed.html
new file mode 100644
index 00000000..17b1f989
--- /dev/null
+++ b/templates/packages/removed.html
@@ -0,0 +1,28 @@
+{% extends "base.html" %}
+{% load url from future %}
+{% load package_extras %}
+
+{% block title %}Arch Linux - Not Available - {{ update.pkgname }} {{ update.old_version }} ({{ update.arch.name }}){% endblock %}
+{% block navbarclass %}anb-packages{% endblock %}
+
+{% block content %}
+<div id="pkg-gone" class="box">
+ <h2>{{ update.pkgname }} {{ update.old_version }} is no longer available</h2>
+
+ <p>{{ update.pkgname }} {{ update.old_version }} has been removed from the [{{ update.repo.name|lower }}] repository.</p>
+
+ {% with update.elsewhere as elsewhere %}{% if elsewhere %}
+ <p>However, this package is available in other repositories:</p>
+ <ul>
+ {% for pkg in elsewhere %}
+ <li>{% pkg_details_link pkg %} {{ pkg.full_version }} [{{ pkg.repo.name|lower }}] ({{ pkg.arch.name }})</li>
+ {% endfor %}
+ </ul>
+ {% else %}
+ <p>Unfortunately, this package cannot be found in any other repositories.
+ Try using the <a href="{% url 'packages-search' %}?name={{ update.pkgname|urlencode }}">package search page</a>,
+ or try <a href="https://aur.archlinux.org/packages.php?K={{ update.pkgname|urlencode }}">searching the AUR</a>
+ to see if the package can be found there.</p>
+ {% endif %}{% endwith %}
+</div>
+{% endblock %}