Unison-jz trying to create unneeded/unwanted symlinks

I am trying to use unison-jz in command-line-only mode – no X window.

I tried just running it with the -iu text option, but it insists on trying to create home dir links that I don’t need or want that I suspect are related to Gnome support.

$ unison-jz.unison -ui text
ln: failed to create symbolic link '/root/snap/unison-jz/19/snap/unison-jz/19': No such file or directory
ln: failed to create symbolic link '/root/snap/unison-jz/19/snap/unison-jz/19/Desktop': No such file or directory
ln: failed to create symbolic link '/root/snap/unison-jz/19/snap/unison-jz/19/Downloads': No such file or directory
ln: failed to create symbolic link '/root/snap/unison-jz/19/snap/unison-jz/19/Music': No such file or directory
ln: failed to create symbolic link '/root/snap/unison-jz/19/snap/unison-jz/19/Pictures': No such file or directory
ln: failed to create symbolic link '/root/snap/unison-jz/19/snap/unison-jz/19/Videos': No such file or directory
ln: failed to create symbolic link '/root/snap/unison-jz/19/snap/unison-jz/19/Templates': No such file or directory
Usage: unison [options]
    or unison root1 root2 [options]
    or unison profilename [options]

For a list of options, type "unison -help".
For a tutorial on basic usage, type "unison -doc tutorial".
For other documentation, type "unison -doc topics".

I tried unsetting the dir settings and changing them to /dev/null in:

/root/snap/unison-jz/19/.config/user-dirs.dirs

but unison-jz insists on changing things back:

$  unison-jz.unison
/dev/null was removed, reassigning DOCUMENTS to homedir
in: failed to create symbolic link '/root/snap/unison-jz/19/snap/unison-jz/19': No such file or directory
ln: failed to create symbolic link '/root/snap/unison-jz/19/snap/unison-jz/19/Desktop': No such file or directory
ln: failed to create symbolic link '/root/snap/unison-jz/19/snap/unison-jz/19/Downloads': No such file or directory
.
.

Is there a way to disable that behavior?

I installed unison-jz to have a look.

The content of /root/snap/unison-jz/19/:

$ ls -la /snap/unison-jz/19

total 18
drwxr-xr-x 9 root root   182 Jun  7  2018 .
drwxr-xr-x 3 root root  4096 Mar 10 12:00 ..
drwxr-xr-x 2 root root    56 Jun  7  2018 bin
-rw-r--r-- 1 root root 12840 Jun  7  2018 bindtextdomain.so
-rwxr-xr-x 1 root root   354 Jun  7  2018 command-unison.wrapper
drwxr-xr-x 9 root root   158 Jun  7  2018 etc
-rw-r--r-- 1 root root    14 Jun  7  2018 flavor-select
drwxr-xr-x 3 root root    39 Dec 10  2015 lib
drwxr-xr-x 3 root root    43 Jun  7  2018 meta
drwxr-xr-x 3 root root    69 Jun  7  2018 snap
drwxr-xr-x 6 root root    86 Nov  9  2015 usr
drwxr-xr-x 3 root root    26 Jun  7  2018 var

So there is NO location `/root/snap/unison-jz/19/snap/unison-jz.

And one can reproduce the problem by trying to create symlink to ‘/root/snap/unison-jz/19/snap/unison-jz/19’ from within the snap shell:

$ sudo snap run --shell unison-jz.unison
$ ln -s $SNAP_USER_DATA/link /root/snap/unison-jz/19/snap/unison-jz/19

ln: failed to create symbolic link '/root/snap/unison-jz/19/snap/unison-jz/19': No such file or directory

So to me this looks like application issue.

Furthermore, I tried the exact same command and do not get the problem. Perhaps try snap remove --purge unison-jz and reinstall.