clean up handling of <app>

 make it consistent across output formats