PK<-d59iˆ¿robotstxt/web_ui.pyfrom trac.core import * from trac.web.chrome import ITemplateProvider from trac.web.api import IRequestHandler from trac.wiki.model import WikiPage __all__ = ['RobotsTxtModule'] class RobotsTxtModule(Component): """Serve a robots.txt file from Trac.""" implements(ITemplateProvider, IRequestHandler) # IRequestHandler methods def match_request(self, req): return req.path_info == '/robots.txt' def process_request(self, req): page = WikiPage(self.env, 'RobotsTxt') data = '' if page.exists: data = page.text req.hdf['robotstxt.data'] = data return 'robotstxt.cs', 'text/plain' # ITemplateProvider methods def get_templates_dirs(self): from pkg_resources import resource_filename return [resource_filename(__name__, 'templates')] def get_htdocs_dirs(self): from pkg_resources import resource_filename #return [('robotstxt', resource_filename(__name__, 'htdocs'))] return [] PK<-d5robotstxt/__init__.pyPKq0d5X™ž[[robotstxt/web_ui.pyc;ò tnLEc@sQdkTdklZdklZdklZdgZdefd„ƒYZ dS((s*(sITemplateProvider(sIRequestHandler(sWikiPagesRobotsTxtModulecBs?tZdZeeeƒd„Zd„Zd„Zd„Z RS(s"Serve a robots.txt file from Trac.cCs|idjSdS(Ns /robots.txt(sreqs path_info(sselfsreq((s.build/bdist.linux-i686/egg/robotstxt/web_ui.pys match_requestscCsJt|idƒ}d}|io |i}n||id PKq0d5w>Ó}}EGG-INFO/PKG-INFOMetadata-Version: 1.0 Name: TracRobotsTxt Version: 1.0.1 Summary: Serve a robots.txt file from Trac. Home-page: http://trac-hacks.org/wiki/RobotsTxtPlugin Author: Noah Kantrowitz Author-email: coderanger@yahoo.com License: BSD Description: Allows simple management of a robots.txt file from within Trac. Keywords: trac plugin robots Platform: UNKNOWN Classifier: Framework :: Trac PKq0d5M±»dEGG-INFO/SOURCES.txtsetup.py TracRobotsTxt.egg-info/PKG-INFO TracRobotsTxt.egg-info/SOURCES.txt TracRobotsTxt.egg-info/dependency_links.txt TracRobotsTxt.egg-info/entry_points.txt TracRobotsTxt.egg-info/top_level.txt robotstxt/__init__.py robotstxt/web_ui.py robotstxt/templates/robotstxt.cs PKq0d5“×2EGG-INFO/dependency_links.txt PKq0d5 ÓzÇ44EGG-INFO/entry_points.txt[trac.plugins] robotstxt.web_ui = robotstxt.web_ui PKq0d5kf$F EGG-INFO/top_level.txtrobotstxt PKq0d5“×2EGG-INFO/zip-safe PK<-d59iˆ¿¤robotstxt/web_ui.pyPK<-d5¤Jrobotstxt/__init__.pyPKq0d5X™ž[[¤}robotstxt/web_ui.pycPKq0d5¢ïtt€€¤ robotstxt/__init__.pycPK<-d5òȈ ¤¾ robotstxt/templates/robotstxt.csPKq0d5w>Ó}}¤EGG-INFO/PKG-INFOPKq0d5M±»d¤ÃEGG-INFO/SOURCES.txtPKq0d5“×2¤EGG-INFO/dependency_links.txtPKq0d5 ÓzÇ44¤AEGG-INFO/entry_points.txtPKq0d5kf$F ¤¬EGG-INFO/top_level.txtPKq0d5“×2¤êEGG-INFO/zip-safePK î