[Desktop Entry]
<%=
Object.entries({
    "Name": productName,
    "Comment": description,
    "GenericName": genericName,
    "Exec": name ? `${name} %U` : undefined,
    "Icon": name,
    "Type": "Application",
    "StartupNotify": "true",
    "StartupWMClass": productName,
    "Categories": categories?.length ? `${categories.join(";")};` : undefined,
    "MimeType": mimeType?.length ? `${mimeType.join(";")};` : undefined
})
.map(line => line[1] ? line.join("=") : undefined)
.filter(line => !!line)
.join("\n")%>