switched back to whoosh with haystack
[ebuildfind.git] / views.py
blob8ba9114b0ad7b9150e217fbf81a17a6c96bfd6f3
1 from django.shortcuts import render_to_response
2 from planet import Parser
4 from models import Ebuild
6 import re, string
8 PUNCTUATION_REGEX = re.compile('[' + re.escape(string.punctuation.replace("-", "").replace("+", "")) + ']')
10 def index(request):
11 GPlanet = Parser("http://planet.gentoo.org/atom.xml")
12 GOverlays = Parser("http://overlays.gentoo.org/rss20.xml")
13 GNews = Parser("http://www.gentoo.org/rdf/en/gentoo-news.rdf")
14 identica = Parser("https://identi.ca/api/laconica/groups/timeline/gentoo.atom")
16 response = dict()
18 response['identica'] = identica
19 response['GNews'] = GNews
20 response['GOverlays'] = GOverlays
21 response['GPlanet'] = GPlanet
23 return render_to_response("ebuildfind/index.html", response)