def build_globals(debug): from pychron.initialization_parser import InitializationParser ip = InitializationParser() from pychron.globals import globalv globalv.build(ip) globalv.debug = debug
def build_globals(user, debug): try: from pychron.envisage.initialization.initialization_parser import InitializationParser except ImportError as e: from pyface.message_dialog import warning warning(None, str(e)) ip = InitializationParser() from pychron.globals import globalv globalv.build(ip) globalv.debug = debug globalv.username = user
def add_eggs(root): egg_path = os.path.join(root, 'pychron.pth') if os.path.isfile(egg_path): # use a pychron.pth to get additional egg paths with open(egg_path, 'r') as rfile: eggs = [ei.strip() for ei in rfile.read().split('\n')] eggs = [ei for ei in eggs if ei] for egg_name in eggs: # sys.path.insert(0, os.path.join(root, egg_name)) sys.path.append(os.path.join(root, egg_name)) print os.path.join(root, egg_name) def build_globals(debug): try: from pychron.envisage.initialization.initialization_parser import InitializationParser except ImportError, e: from pyface.message_dialog import warning warning(None, str(e)) ip = InitializationParser() from pychron.globals import globalv globalv.build(ip) globalv.debug = debug # ============= EOF =============================================
egg_path = os.path.join(root, "pychron.pth") if os.path.isfile(egg_path): # use a pychron.pth to get additional egg paths with open(egg_path, "r") as rfile: eggs = [ei.strip() for ei in rfile.read().split("\n")] eggs = [ei for ei in eggs if ei] for egg_name in eggs: # sys.path.insert(0, os.path.join(root, egg_name)) sys.path.append(os.path.join(root, egg_name)) print os.path.join(root, egg_name) def build_globals(debug): try: from pychron.envisage.initialization.initialization_parser import InitializationParser except ImportError, e: from pyface.message_dialog import warning warning(None, str(e)) ip = InitializationParser() from pychron.globals import globalv globalv.build(ip) globalv.debug = debug # ============= EOF =============================================