#
# Copyright (C) 2019-Present A-Team Digital Solutions
#

#
# DEFINE PROJECT SUMMARY
#
def build_project_summary(project):
    text = []
    text.append(
        f"Device: "
        f"{project.device_vars.get('DEVICE_DISPLAY_NAME', 'Unknown')}"
    )
    text.append(
        f"Device Codename: "
        f"{project.device_vars.get('DEVICE_DISPLAY_CODENAME', 'Unknown')}"
    )
    text.append(
        f"Device Model Number: "
        f"{project.device_vars.get('DEVICE_MODEL_NUMBER', 'Unknown')}"
    )
    text.append(
        f"ROM: "
        f"{project.rom_vars.get('ROM_DISPLAY_NAME', 'Unknown')}"
    )
    text.append(
        f"Branch: {project.rom_branch}"
    )
    text.append(
        f"Android: {project.android_version}"
    )
    text.append(
        f"Build Variant: {project.build_variant.capitalize()}"
    )
    text.append(
        f"ROM Source Path: {project.rom_path}"
    )
    text.append(
        f"Gapps Variant: "
        f"{project.gapps_variant.capitalize()}"
    )
    text.append(
        f"Clean Variant: "
        f"{project.clean_variant.capitalize()}"
    )
    text.append(
        f"Installer Variant: "
        f"{project.installer_variant.capitalize()}"
    )
    text.append(
        f"Build Jobs: "
        f"{project.build_jobs}"
    )
    text.append(
        f"Ccache: "
        f"{project.use_ccache}"
    )
    # DEBUG
    #print(project.device_vars)
    #print(project.rom_vars)
    #print(project.build_variant)
    return "\n".join(text)
