def parse_config_line(line: str) -> RemoteConfig:
    (entry, *env_items) = line.split(maxsplit=1)
    (shell, shell_options) = _extract_shell_info(line, env_items)
    parts = entry.split(':')
    if (len(parts) != 2):
        raise ConfigurationError(f'The configuration string is malformed: {parts}. Please use host-name:remote_dir format')
    (host, directory) = parts
    return RemoteConfig(host=host, directory=Path(directory), shell=shell, shell_options=shell_options)
def parse_config_line(line: str) -> RemoteConfig:
    (entry, *env_items) = line.split(maxsplit=1)
    (shell, shell_options) = _extract_shell_info(line, env_items)
    parts = entry.split(':')
    if (len(parts) != 2):
        raise ConfigurationError(f'The configuration string is malformed: {parts}. Please use host-name:remote_dir format')
    (host, directory) = parts
    return RemoteConfig(host=host, directory=Path(directory), shell=shell, shell_options=shell_options)