3 # Copyright (C) 2008 Google Inc.
5 # Licensed under the Apache License, Version 2.0 (the "License");
6 # you may not use this file except in compliance with the License.
7 # You may obtain a copy of the License at
9 # http://www.apache.org/licenses/LICENSE-2.0
11 # Unless required by applicable law or agreed to in writing, software
12 # distributed under the License is distributed on an "AS IS" BASIS,
13 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 # See the License for the specific language governing permissions and
15 # limitations under the License.
18 """Constants for the divide_and_compress script and DirectoryZipper class."""
20 __author__ = 'jmatt@google.com (Justin Mattson)'
22 file_preamble = """#!/usr/bin/env python
24 # Copyright 2008 Google Inc.
26 # Licensed under the Apache License, Version 2.0 (the "License");
27 # you may not use this file except in compliance with the License.
28 # You may obtain a copy of the License at
30 # http://www.apache.org/licenses/LICENSE-2.0
32 # Unless required by applicable law or agreed to in writing, software
33 # distributed under the License is distributed on an \"AS IS\" BASIS,
34 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
35 # See the License for the specific language governing permissions and
36 # limitations under the License.
39 import wsgiref.handlers\n'
40 from google.appengine.ext import zipserve\n'
41 from google.appengine.ext import webapp\n'
42 import memcache_zipserve\n\n\n'
43 class MainHandler(webapp.RequestHandler):
46 self.response.out.write('Hello world!')
49 application = webapp.WSGIApplication(['/(.*)',
50 memcache_zipserve.create_handler(["""
52 file_endpiece = """])),
55 wsgiref.handlers.CGIHandler().run(application)
57 if __name__ == __main__: