Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Snaps: Fix symlinked XDG_SPECIAL_DIRS in HOME
When a user has one or several `XDG_SPECIAL_DIRS` folders symlinked in their real home folder to elsewhere in their real home folder `desktop-common.sh` will attempt to mv those folders to themselves. Because we are executing this script with `bash -e`, this prevents any Snap with the `home` interface built with these scripts from launching when the user has moved any of their Documents, Pictures, Music, etc. and replaced with a symlink. * guard `mv` calls with test for `is_subpath` to ensure that we're only moving symlinks we created. See related PRs on Snapcraft-desktop-helpers and Snapcraft: * ubuntu/snapcraft-desktop-helpers#220 * canonical/snapcraft#3435 Signed-off-by: Daniel Llewellyn <diddledan@ubuntu.com>
- Loading branch information