solenv/bin/assemble-flatpak.sh | 26 +++++++++++--------------- 1 file changed, 11 insertions(+), 15 deletions(-)
New commits: commit 35fc8885760030cb78b856a23ad02f5148268296 Author: Stephan Bergmann <sberg...@redhat.com> Date: Thu Sep 7 10:50:34 2017 +0200 Include all .desktop files in the Flatpak ...GNOME Software reportedly is fine with that now. Change-Id: I418fc60a3215078109d3d8e9f426f98fdf37322b (cherry picked from commit 1b85d725663a7d7546549e6b78ea43bea1cde7b9) Reviewed-on: https://gerrit.libreoffice.org/42051 Tested-by: Jenkins <c...@libreoffice.org> Reviewed-by: Michael Stahl <mst...@redhat.com> diff --git a/solenv/bin/assemble-flatpak.sh b/solenv/bin/assemble-flatpak.sh index e73848b6e050..d514c3ee41fc 100755 --- a/solenv/bin/assemble-flatpak.sh +++ b/solenv/bin/assemble-flatpak.sh @@ -15,29 +15,25 @@ set -e cp -r "${PREFIXDIR?}"/lib/libreoffice /app/ -## libreoffice-startcenter.desktop -> org.libreoffice.LibreOffice.desktop, -## combining all libreoffice-*.desktop MimeType= lines: +## libreoffice-*.desktop -> org.libreoffice.LibreOffice-*.desktop: mkdir /app/share mkdir /app/share/applications -my_mimetypes=$(awk -d 'BEGIN { FS="="; ORS=""; semi=0 }; \ - /^MimeType=/ && length($2) \ - { if (semi) print ";"; print $2; semi = match($2, ";$") == 0 }' \ - "${PREFIXDIR?}"/share/applications/libreoffice-*.desktop) -sed -e 's,^Exec=libreoffice,Exec=/app/libreoffice/program/soffice,' \ - -e 's/^Icon=libreoffice-/Icon=org.libreoffice.LibreOffice-/' \ - -e 's|^MimeType=.*$|MimeType='"$my_mimetypes"'|' \ - "${PREFIXDIR?}"/share/applications/libreoffice-startcenter.desktop \ - >/app/share/applications/org.libreoffice.LibreOffice.desktop +for i in "${PREFIXDIR?}"/share/applications/libreoffice-*.desktop +do + sed -e 's,^Exec=libreoffice,Exec=/app/libreoffice/program/soffice,' \ + -e 's/^Icon=libreoffice-/Icon=org.libreoffice.LibreOffice-/' "$i" \ + >/app/share/applications/org.libreoffice.LibreOffice-"${i#"${PREFIXDIR?}"/share/applications/libreoffice-}" +done -## icons/hicolor/*/apps/libreoffice-startcenter.* -> -## icons/hicolor/*/apps/org.libreoffice.LibreOffice-startcenter.*: +## icons/hicolor/*/apps/libreoffice-* -> +## icons/hicolor/*/apps/org.libreoffice.LibreOffice-*: mkdir /app/share/icons -for i in "${PREFIXDIR?}"/share/icons/hicolor/*/apps/libreoffice-startcenter.* +for i in "${PREFIXDIR?}"/share/icons/hicolor/*/apps/libreoffice-* do mkdir -p \ "$(dirname /app/share/icons/hicolor/"${i#"${PREFIXDIR?}"/share/icons/hicolor/}")" cp -a "$i" \ - "$(dirname /app/share/icons/hicolor/"${i#"${PREFIXDIR?}"/share/icons/hicolor/}")"/org.libreoffice.LibreOffice-startcenter."${i##*/apps/libreoffice-startcenter.}" + "$(dirname /app/share/icons/hicolor/"${i#"${PREFIXDIR?}"/share/icons/hicolor/}")"/org.libreoffice.LibreOffice-"${i##*/apps/libreoffice-}" done ## org.libreoffice.LibreOffice.appdata.xml is manually derived from the various _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits