Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Install icons in icon theme to allow them being accessible from confined processes #6

Open
wants to merge 1 commit into
base: stable
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions snapcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -62,15 +62,14 @@ parts:
override-pull: |
craftctl default
craftctl set version=$(git describe --tags --abbrev=10)
sed -i.bak -e 's|Icon=@app_id@$|Icon=snap.gnome-calculator.icon|g' data/org.gnome.Calculator.desktop.in
override-build: |
# valadoc fails, but we don't need it in the snap anyway
sed -i.bak -e "s|subdir('doc')||g" $CRAFT_PART_SRC/meson.build
# Don't symlink media it leaves dangling symlinks in the snap
sed -i.bak -e 's|media: gnome_calculator_help_media|media: gnome_calculator_help_media, symlink_media: false|g' $CRAFT_PART_SRC/help/meson.build
# Use bundled icon rather than themed icon, needed for 18.04
sed -i.bak -e 's|Icon=org.gnome.Calculator$|Icon=${SNAP}/meta/gui/org.gnome.Calculator.svg|g' $CRAFT_PART_SRC/data/org.gnome.Calculator.desktop.in
mkdir -p $CRAFT_PART_INSTALL/meta/gui/
cp $CRAFT_PART_SRC/data/icons/hicolor/scalable/apps/org.gnome.Calculator.svg $CRAFT_PART_INSTALL/meta/gui/
mkdir -p ${CRAFT_PART_INSTALL}/meta/gui/icons/hicolor/scalable/apps
cp ../src/data/icons/hicolor/scalable/apps/org.gnome.Calculator.svg ${CRAFT_PART_INSTALL}/meta/gui/icons/hicolor/scalable/apps/snap.gnome-calculator.icon.svg
craftctl default

# Find files provided by the base and platform snap and ensure they aren't
Expand Down