def validStart(): if not os.path.exists(RESOURCES): __runProcess__('mkdir %s' % __formatSpaces__(RESOURCES)) if not os.path.exists(OAUTH_JSON): __runProcess__('touch %s' % __formatSpaces__(OAUTH_JSON)) if not os.path.exists('%s/webdrivers' % RESOURCES): __runProcess__('mkdir %s' % __formatSpaces__('%s/webdrivers' % RESOURCES)) if not os.path.exists(SUBSCRIPTIONS): __runProcess__('mkdir %s' % __formatSpaces__(SUBSCRIPTIONS)) requiredInstalls = [] for i in DEPENDENCIES: if not 'True' in __runProcess__( '%s --is-installed %s %s' % (PKG_MANAGER, i['title'], i['dest'])).split('\n')[0]: requiredInstalls.append(i) if len(requiredInstalls) > 0: newDependencies = '' newDestinations = '' for i in requiredInstalls: newDependencies = '%s %s' % (newDependencies, i['title']) newDestinations = '%s %s' % (newDestinations, i['dest']) __runProcess__('%s -i%s -o%s' % (PKG_MANAGER, newDependencies, newDestinations)) __runProcess__('%s -light -light -dark -dark --suppress' % GLYPHMANAGER) import OmniAuth OmniAuth.validStart()
def validStart(): if not os.path.exists(RESOURCES): __runProcess__('mkdir %s' % __formatSpaces__(RESOURCES)) if not os.path.exists(OAUTH_JSON): __runProcess__('touch %s' % __formatSpaces__(OAUTH_JSON)) if not os.path.exists('%s/webdrivers' % RESOURCES): __runProcess__('mkdir %s' % __formatSpaces__('%s/webdrivers' % RESOURCES)) if not os.path.exists(SUBSCRIPTIONS): __runProcess__('mkdir %s' % __formatSpaces__(SUBSCRIPTIONS)) requiredInstalls = [] for i in DEPENDENCIES: if not 'True' in __runProcess__('%s --is-installed %s %s' % (PKG_MANAGER, i['title'], i['dest'])).split('\n')[0]: requiredInstalls.append(i) if len(requiredInstalls) > 0: newDependencies = '' newDestinations = '' for i in requiredInstalls: newDependencies = '%s %s' % (newDependencies, i['title']) newDestinations = '%s %s' % (newDestinations, i['dest']) __runProcess__('%s -i%s -o%s' % (PKG_MANAGER, newDependencies, newDestinations)) __runProcess__('%s -light -light -dark -dark --suppress' % GLYPHMANAGER) import OmniAuth OmniAuth.validStart()