Returns the website location for projex software.
    
    :param      app  | <str> || None
                mode | <str> (home, docs, blog, dev)
    
    :return     <str>
344369
def website(app=None, mode='home', subcontext='UserGuide'):
    
    base_url = WEBSITES.get(mode, '')

    if app and base_url:
        opts = {'app': app, 'base_url': base_url}
        base_url = SUBCONTEXT_MAP.get((mode, subcontext), base_url)
        base_url %= opts

    return base_url
727739
def find_project_dir():
    
    frame = inspect.currentframe()

    while True:
        frame = frame.f_back
        fname = frame.f_globals['__file__']

        if os.path.basename(fname) == 'manage.py':
            break

    return os.path.dirname(fname)
717408
def location(self):
        
        try:
            lat, lng = self["metadata"]["latitude"], self["metadata"]["longitude"]
        except KeyError:
            return None

        if not lat or not lng:
            return None

        return lat, lng
1077029
def location_path(cls, project, location):
        """"""
        return google.api_core.path_template.expand(
            "projects/{project}/locations/{location}",
            project=project,
            location=location,
        )
1359169
def location(self):
        """"""
        location, _, revision = self.expression.partition('#')
        return location if location and revision else None
847087
def location_path(self):
        
        value = []
        for option in self.options:
            if option.number == defines.OptionRegistry.LOCATION_PATH.number:
                value.append(str(option.value))
        return "/".join(value)
484341
def getModulePath(project_path,module_name,verbose):
    ''''''
    if not module_name:
        return None
    sys.path.append(project_path)
    try:
        package = pkgutil.get_loader(module_name)
    except ImportError:
        if verbose:
            print("Parent module for "+module_name+" not found.")
        return None
    except:
        if verbose:
            print(module_name+" not loaded for bizarre reasons")
    try:
        if package: 
                if package.get_code(module_name):
                    filename = package.get_code(module_name).co_filename
                    return filename
                elif package.find_spec(module_name).has_location==False:
                    return None #built-in module such as itertools
                else:
                    pass #perhaps filename is in package.find_spec(module_name).origin?
                    pass #a good reference is https://www.python.org/dev/peps/pep-0302/
    except ImportError:
        if verbose:
            print("Code object unavailable for "+module_name)
        return None
    except AttributeError:
        if verbose:
            print(module_name+" is an ExtensionFileLoader object")
        return None
    except:
        if verbose:
            print(module_name+" not loaded for bizarre reasons")
        return None
    else:
        if verbose:
            print ("Module "+module_name+" not found.")
        return None
662406
def apps_location_show(self, id, **kwargs):
        ""
        api_path = "/api/v2/apps/locations/{id}.json"
        api_path = api_path.format(id=id)
        return self.call(api_path, **kwargs)
1239791
def _getAppStoreResource(self, ctx, name):
        
        offer = self.frontPageItem.store.findFirst(
            offering.InstalledOffering,
            offering.InstalledOffering.offeringName == unicode(name, 'ascii'))
        if offer is not None:
            pp = ixmantissa.IPublicPage(offer.application, None)
            if pp is not None:
                warn("Use the sharing system to provide public pages,"
                     " not IPublicPage",
                     category=DeprecationWarning,
                     stacklevel=2)
                return pp.getResource()
            return SharingIndex(offer.application.open(),
                                self.webViewer)
        return None
764916
def angularFrontendAppDir(self) -> str:
        
        relDir = self._packageCfg.config.plugin.title(require_string)
        dir = os.path.join(self._pluginRoot, relDir)
        if not os.path.isdir(dir): raise NotADirectoryError(dir)
        return dir
322613
def _get_home():
    
    try:
        if six.PY2 and sys.platform == 'win32':
            path = os.path.expanduser(b"~").decode(sys.getfilesystemencoding())
        else:
            path = os.path.expanduser("~")
    except ImportError:
        # This happens on Google App Engine (pwd module is not present).
        pass
    else:
        if os.path.isdir(path):
            return path
    for evar in ('HOME', 'USERPROFILE', 'TMP'):
        path = os.environ.get(evar)
        if path is not None and os.path.isdir(path):
            return path
    return None
1359898
def _get_app(self, appname):
        
        try:
            app = APPS.get_app_config(appname)
        except Exception as e:
            self.err(e)
            return
        return app
198147
def project_dir(self) -> str:
        
        dev_dir = self.dev_dir()
        project = self.random.choice(PROJECT_NAMES)
        return str(self._pathlib_home / dev_dir / project)
1172751
function getAppDir() {
    var fileRepo = args._[1] ? path.resolve(args._[1]) : undefined;
    return fileRepo && fs.existsSync(fileRepo) ? fileRepo : 0;
}
296756
private String buildApplicationUrl(final UIContext uic) {
		Environment env = uic.getEnvironment();
		return env.getPostPath();
	}
143268
def get_location(vm_=None):
    '''
    
    '''
    return __opts__.get(
        'location',
        config.get_cloud_config_value(
            'location',
            vm_ or get_configured_provider(),
            __opts__,
            default=DEFAULT_LOCATION,
            search_global=False
        )
    )
718544
def search_app_root():
        
        while True:

            current = os.getcwd()

            if pathlib.Path("apps.py").is_file():
                return current
            elif pathlib.Path.cwd() == "/":
                raise FileNotFoundError
            else:
                os.chdir("../")