Exposing ~/.config or ~/.<name>rc best practices

I’m working to package the GNU poke project right now, and I’m unsure of the best practices for how to expose the real user’s configuration files to the snap internals.

From what I understand I should use a personal-files plug to expose write access to the various configuration files, then (based upon XDG_CONFIG_HOME for classic snaps) I think I should use a command-chain to try to symlink the two files and one directory that the binary looks for in the user’s home directory, but it’s not clear how the rewriting would take place.

As I understand it this should be the following to allow r/w access to the files:
interface: personal-files
- $HOME/.config/poke
- $HOME/.pokerc
- $HOME/.poke_history

But I’m not sure how I should be robustly exposing the symlink targets to $SNAP_REAL_HOME from the fake $HOME defined inside the snap.

I’m tracking my attempt here: https://github.com/lrenaud/gnu-poke-snap/blob/master/snap/snapcraft.yaml