Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
snapcraft/wrappers/editor: do not export XDG_ vars
`lxc config edit` would generate some noise if `/root/.local` didn't exist: ``` Unable to create directory /root/.local/share//nano/: No such file or directory It is required for saving/loading search history or cursor positions. ``` Normally, `nano` would create the hiearchy `/root/.local/share/nano/` itself if XDG_DATA_HOME is not defined. This hiearchy creation logic is skipped if the variable is defined. The spec [1] contains this: > If $XDG_DATA_HOME is either not set or empty, a default equal to $HOME/.local/share should be used. > If $XDG_CONFIG_HOME is either not set or empty, a default equal to $HOME/.config should be used. > If $XDG_STATE_HOME is either not set or empty, a default equal to $HOME/.local/state should be used. So let's not export those as `nano` knows about those defaults and can then create the proper directories without warnings. [1]: https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html#variables Signed-off-by: Simon Deziel <[email protected]> (cherry picked from commit 7dcb188)
- Loading branch information