Skip to content

Commit

Permalink
Merge pull request #74 from kenvandine/xdg-dirs
Browse files Browse the repository at this point in the history
Ensure XDG_CONFIG_HOME is set and run xdg-user-dirs-update
  • Loading branch information
kenvandine authored Oct 2, 2017
2 parents 9771994 + 275cc89 commit 1166119
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
9 changes: 9 additions & 0 deletions common/desktop-exports
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,15 @@ mkdir -p $XDG_DATA_HOME
export XDG_CACHE_HOME=$SNAP_USER_DATA/.cache
mkdir -p $XDG_CACHE_HOME

# Set config folder to local path
export XDG_CONFIG_HOME=$SNAP_USER_DATA/.config
mkdir -p $XDG_CONFIG_HOME

# Run xdg-user-dirs-update
if [ `which xdg-user-dirs-update` ]; then
xdg-user-dirs-update
fi

# Create $XDG_RUNTIME_DIR if not exists (to be removed when LP: #1656340 is fixed)
[ -n "$XDG_RUNTIME_DIR" ] && mkdir -p $XDG_RUNTIME_DIR -m 700

Expand Down
5 changes: 5 additions & 0 deletions snapcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,7 @@ parts:
- unity-gtk3-module
- libappindicator3-1
- locales-all
- xdg-user-dirs
qt4:
source: .
source-subdir: qt
Expand Down Expand Up @@ -171,6 +172,7 @@ parts:
- unity-gtk2-module
- locales-all
- libappindicator1
- xdg-user-dirs
desktop-gtk3:
source: .
source-subdir: gtk
Expand All @@ -193,6 +195,7 @@ parts:
- unity-gtk3-module
- libappindicator3-1
- locales-all
- xdg-user-dirs
desktop-qt4:
source: .
source-subdir: qt
Expand All @@ -215,6 +218,7 @@ parts:
- appmenu-qt
- locales-all
- sni-qt
- xdg-user-dirs
desktop-qt5:
source: .
source-subdir: qt
Expand All @@ -236,6 +240,7 @@ parts:
- libqt5svg5 # for loading icon themes which are svg
- appmenu-qt5
- locales-all
- xdg-user-dirs
desktop-glib-only:
source: .
source-subdir: glib-only
Expand Down

0 comments on commit 1166119

Please sign in to comment.