def main(): args = parseArguments() args_config = {} if args.update_dependencies: args_config["update_dependencies"] = args.update_dependencies loadConfiguration(args.config_file_path, args_config) if args.action == 'build': context = Context(directory=os.path.abspath(args.path)) for target in context.targets: target.process() target.build() else: print "Action not supported: %s" % (args.action)
def __init__(self, method=METHOD_GET, configFiles=None): """Class constructor """ # get settings config.loadConfiguration(configFiles) self.setLogFile() self.UUID = uuid.uuid1().__str__() self.languages = config.getConfigValue("wps","lang").split(",") DEFAULT_LANG = self.languages[0] # set default version self.versions = config.getConfigValue("wps","version").split(",") DEFAULT_VERSION = self.versions[0] # find out the request method self.method = method
def __init__(self, environ, configFiles=None): """Class constructor """ # get settings config.loadConfiguration(configFiles, environ) self.setLogFile() self.UUID = uuid.uuid1().__str__() self.languages = config.getConfigValue("wps", "lang").split(",") DEFAULT_LANG = self.languages[0] # set default version self.versions = config.getConfigValue("wps", "version").split(",") DEFAULT_VERSION = self.versions[0] # find out the request method self.method = environ["REQUEST_METHOD"]
def __init__(self, method=METHOD_GET, configFiles=None): """Class constructor """ # get settings, if not already loaded if not config.config: config.loadConfiguration(configFiles) self.setLogFile() self.UUID = uuid.uuid1().__str__() self.languages = config.getConfigValue("wps", "lang").split(",") DEFAULT_LANG = self.languages[0] # set default version self.versions = config.getConfigValue("wps", "version").split(",") DEFAULT_VERSION = self.versions[0] # find out the request method self.method = method # create configured output path if it does not exist and ensure it # is accessible try: outputPath = config.getConfigValue("server", "outputPath") os.makedirs(outputPath) except OSError: if not os.path.isdir(outputPath): raise # create configured temp path if it does not exist and ensure it # is accessible try: tempPath = config.getConfigValue("server", "tempPath") os.makedirs(tempPath) except OSError: if not os.path.isdir(tempPath): raise
def __init__(self, method=METHOD_GET, configFiles=None): """Class constructor """ # get settings, if not already loaded if not config.config: config.loadConfiguration(configFiles) self.setLogFile() self.UUID = uuid.uuid1().__str__() self.languages = config.getConfigValue("wps","lang").split(",") DEFAULT_LANG = self.languages[0] # set default version self.versions = config.getConfigValue("wps","version").split(",") DEFAULT_VERSION = self.versions[0] # find out the request method self.method = method # create configured output path if it does not exist and ensure it # is accessible try: outputPath = config.getConfigValue("server","outputPath") os.makedirs(outputPath) except OSError: if not os.path.isdir(outputPath): raise # create configured temp path if it does not exist and ensure it # is accessible try: tempPath = config.getConfigValue("server","tempPath") os.makedirs(tempPath) except OSError: if not os.path.isdir(tempPath): raise