One idea I’ve been thinking off is to allow the snap to define a pattern that is matched against the command line.
Vaguely, something along the lines of:
command: bin/vim [<path>]
or, an analogous example with a configuration file:
command: mydaemon [--config <path>]
When the given application is run, the provided path is both unconfined and translated into the correct location for the snap to see it.
This is not a general solution, since the editor would not be able to observe paths that were never seen, but it solves a class of those issues elegantly and transparently for the user.
Not something we’ll work on today, but an interesting idea to evolve.