def project_code(request): code = '\n'.join( make_ver.make_ver( constants.project_filename_dict.format(**request.matchdict), ver_name=request.matchdict['version'], lang=request.matchdict['selected_lang'])) request.response.text = code # TODO: cache this response with beaker/dogpile? request.response.content_type = "text/plain" return request.response
def ver_string(project_type, project, lang, ver_name, ver_path=None): return '\n'.join( make_ver.make_ver(constants.project_filename % (project_type, project, lang), ver_name=ver_name, ver_path=ver_path) )
def ver_string(project_type, project, lang, ver_name, ver_path=None): return '\n'.join( make_ver.make_ver(constants.project_filename % (project_type, project, lang), ver_name=ver_name, ver_path=ver_path))
def project_code(request): code = '\n'.join( make_ver.make_ver(constants.project_filename_dict.format(**request.matchdict), ver_name=request.matchdict['version'], lang=request.matchdict['selected_lang'] ) ) request.response.text = code # TODO: cache this response with beaker/dogpile? request.response.content_type = "text/plain" return request.response