anchor.diff:      Exec=${exec}
       Terminal=${terminal}
       Name=${desktopName}
  -    Categories=${categories}
       ${optionalEntriesString}
       ${if extraEntries == null then ''EOF'' else ''
       ${extraEntries}
  
positive.code:                          {k="Comment";       v=comment;}
                           {k="GenericName";   v=genericName;}
                           {k="MimeType";      v=mimeType;}
                           {k="StartupNotify"; v=startupNotify;}];
  
    valueNotNull = {k, v}: v != null;
  
negative.code: , desktopName
  , genericName ? null
  , mimeType ? null
  , categories ? null
  , startupNotify ? null
  , extraEntries ? null
  , fileValidation ? true # whether to validate resulting desktop file.
  