示例#1
0
文件: gae.py 项目: rmistry/luci-py
 def parse_args(self, *args, **kwargs):
     gae_sdk_utils.app_sdk_options(self, self.app_dir)
     options, args = optparse.OptionParser.parse_args(self, *args, **kwargs)
     if not self.allow_positional_args and args:
         self.error('Unknown arguments: %s' % args)
     app = gae_sdk_utils.process_sdk_options(self, options, self.app_dir)
     return app, options, args
示例#2
0
文件: gae.py 项目: misscache/luci-py
 def parse_args(self, *args, **kwargs):
     gae_sdk_utils.app_sdk_options(self, self.app_dir)
     options, args = optparse.OptionParser.parse_args(self, *args, **kwargs)
     if not self.allow_positional_args and args:
         self.error("Unknown arguments: %s" % args)
     app = gae_sdk_utils.process_sdk_options(self, options, self.app_dir)
     return app, options, args
示例#3
0
文件: gae.py 项目: nodirt/luci-py
 def parse_args(self, *args, **kwargs):
   gae_sdk_utils.app_sdk_options(self, self.app_dir)
   self.add_option(
       '--no-oauth', action='store_true',
       help='Use password authentication instead of OAuth2')
   options, args = optparse.OptionParser.parse_args(self, *args, **kwargs)
   if not self.allow_positional_args and args:
     self.error('Unknown arguments: %s' % args)
   app = gae_sdk_utils.process_sdk_options(self, options, self.app_dir)
   if options.no_oauth:
     app.use_cookie_auth()
   return app, options, args
示例#4
0
 def parse_args(self, *args, **kwargs):
     gae_sdk_utils.app_sdk_options(self, self.app_dir)
     self.add_option('--no-oauth',
                     action='store_true',
                     help='Use password authentication instead of OAuth2')
     options, args = optparse.OptionParser.parse_args(self, *args, **kwargs)
     if not self.allow_positional_args and args:
         self.error('Unknown arguments: %s' % args)
     app = gae_sdk_utils.process_sdk_options(self, options, self.app_dir)
     if options.no_oauth:
         app.use_cookie_auth()
     return app, options, args