def _read_file_formatter(value, **context):
    """Reads a file and returns its content.
    takes a file path, reads the content and returns it.

    @read_file /abspath/path/to/file
    @read_file relative/path/to/file
    @read_file file
    @read_file file default_value

    @marker FILEPATH OPTIONAL_DEFAULT_VALUE

    The path can be absolute or relative to the current working directory,
    default_value can be set to return if the file does not exist.
    Raises error if file cannot be read.
    Sets empty string if file is empty.

    Can be composed with @get, @jinja and @format

    @read_file @jinja /path/to/{{this.FILENAME}}
    @read_file @format /path/to/{this.FILENAME}
    @read_file @get FILENAME
    """
    pattern = re.compile(
        r"(?P<path>[^ ]+)\s*"
        r'(?P<quote>["\']?)'
        r'\s*(?P<default>[^"\']*)\s*(?P=quote)?'
    )

    if isinstance(value, Lazy):
        value = value(context["this"], context["env"])

    if match := pattern.match(value.strip()):
        data = match.groupdict()
        path = data["path"]
        default = data["default"]
        if os.path.exists(path):
            with open(path) as file:
                return file.read()
        elif default:
            return default
        else:
            raise DynaconfFileNotFoundError(
                f"File {path} does not exist and no default value provided."
            )
    else:
        raise DynaconfFormatError(f"Error parsing {value} malformed syntax.")
Reads a file and returns its content.
    takes a file path, reads the content and returns it.

    @read_file /abspath/path/to/file
    @read_file relative/path/to/file
    @read_file file
    @read_file file default_value

    @marker FILEPATH OPTIONAL_DEFAULT_VALUE

    The path can be absolute or relative to the current working directory,
    default_value can be set to return if the file does not exist.
    Raises error if file cannot be read.
    Sets empty string if file is empty.

    Can be composed with @get, @jinja and @format

    @read_file @jinja /path/to/{{this.FILENAME}}
    @read_file @format /path/to/{this.FILENAME}
    @read_file @get FILENAME
    
dynaconf/utils/parse_conf.py