code: def get_local_config_file(cls, filename):
          
          if os.path.isfile(filename):
              # Local has priority
              return filename
          else:
              try:
                  # Project. If not in a git repo, this will not exist.
                  config_repo = _get_repo()
                  if len(config_repo) == 0:
                      raise Exception()
                  config_repo = os.path.join(config_repo, filename)
                  if os.path.isfile(config_repo):
                      return config_repo
                  else:
                      raise Exception()
              except Exception:
                  home = os.getenv("HOME", os.path.expanduser("~"))
                  config_home = os.path.join(home, filename)
                  if os.path.isfile(config_home):
                      return config_home
          return None
docs: Find local file to setup default values.
  
          There is a pre-fixed logic on how the search of the configuration
          file is performed. If the highes priority configuration file is found,
          there is no need to search for the next. From highest to lowest
          priority:
  
          1. **Local:** Configuration file found in the current working
             directory.
          2. **Project:** Configuration file found in the root of the current
             working ``git`` repository.
          3. **User:** Configuration file found in the user's ``$HOME``.
  
          :param str filename: Raw name of the configuration file.
  
          :return: Union[:class:`.str`, :data:`None`] - Configuration file with
              the highest priority, :data:`None` if no config file is found.