@gen.engine
def Cat(args, callback):
 assert (len(args) == 1)
 filename = args[0]
 resolved = store_utils.ParseFullPath(filename)
 assert (resolved is not None), ('Cannot determine bucket from %s' % filename)
 (bucket, path) = resolved
 store = ObjectStore.GetInstance(bucket)
 contents = (yield gen.Task(store_utils.GetFileContents, store, path))
 print contents
 callback()

@ gen . engine def Cat ( args , callback ) : assert ( len ( args ) == 1 ) filename = args [ 0 ] resolved = store_utils . ParseFullPath ( filename ) assert ( resolved is not None ) , ( 'Cannot determine bucket from %s' % filename ) ( bucket , path ) = resolved store = ObjectStore . GetInstance ( bucket ) contents = ( yield gen . Task ( store_utils . GetFileContents , store , path ) ) print contents callback ( )
cat a single file .