Add support for generating `.flatpakref`'s on-the-fly for apps, similar to what is done for `.flatpakrepo` files.