Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1)

Unified Diff: third_party/gsutil/20110627/cloudreader/cloudreader.py

Issue 10199002: Upgrade gsutil to 3.4 (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Addressed comments Created 8 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/gsutil/20110627/cloudreader/cloudreader.py
diff --git a/third_party/gsutil/20110627/cloudreader/cloudreader.py b/third_party/gsutil/20110627/cloudreader/cloudreader.py
deleted file mode 100755
index 83ee4551999e21da021ea4131b93ce346525af26..0000000000000000000000000000000000000000
--- a/third_party/gsutil/20110627/cloudreader/cloudreader.py
+++ /dev/null
@@ -1,51 +0,0 @@
-#!/usr/bin/env python
-#
-# Copyright 2010 Google Inc.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-"""Example Google App Engine application."""
-
-import os
-
-# Point to our boto.cfg before importing boto, because boto statically
-# initializes credentials when its loaded.
-os.environ['BOTO_CONFIG'] = 'boto.cfg'
-import boto
-
-from boto.exception import S3ResponseError
-from boto.pyami.config import Config
-from google.appengine.ext import webapp
-from google.appengine.ext.webapp.util import run_wsgi_app
-
-class MainPage(webapp.RequestHandler):
- def get(self):
- self.response.out.write('<html><body><pre>')
- try:
- uri = boto.storage_uri('gs://pub/shakespeare/rose.txt')
- poem = uri.get_contents_as_string()
- self.response.out.write('<pre>' + poem + '</pre>')
- self.response.out.write('</body></html>')
- except AttributeError, e:
- self.response.out.write('<b>Failure: %s</b>' % e)
- except S3ResponseError, e:
- self.response.out.write(
- '<b>Failure: status=%d, code=%s, reason=%s.</b>' %
- (e.status, e.code, e.reason))
-
-def main():
- application = webapp.WSGIApplication([('/', MainPage)], debug=True)
- run_wsgi_app(application)
-
-if __name__ == "__main__":
- main()
« no previous file with comments | « third_party/gsutil/20110627/cloudreader/boto.cfg ('k') | third_party/gsutil/20110627/cloudreader/index.yaml » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698