Data and config file questions

just write a small wrapper shell script that cd’s into the $SNAP dir (make it executable and make sure it ends up in bin/ in your snap package):

#! /bin/sh

cd $SNAP
exec "$@"

and change your command entry:

apps: 
  gladupe:
    command: yourscript.sh $SNAP/path/to/gladupe

you can not write to hidden dirs in the actual homedir of the user with snaps (well, at least not without some special interface setup that requires manual review of your snap). this is why snap packages have per-snap homedirs (/home/<user>/snap/<snapname>/current) and $HOME (along with the $SNAP_USER_DATA variable) always points to this to make sure everyhting is writable. if your code properly uses getenv(“HOME”) everywhere and doesnt have any hardcoded /home/<user>/ anywhere it should all be fine.

see: