From c71ad57c3dba36e91b96f29e5607c6fe11d27799 Mon Sep 17 00:00:00 2001 From: EndrII Date: Thu, 8 Jun 2023 09:53:42 +0200 Subject: [PATCH 1/2] ref #755 fix a shortcuts array for debian pacakges --- src/Deploy/src/Distributions/idistribution.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Deploy/src/Distributions/idistribution.cpp b/src/Deploy/src/Distributions/idistribution.cpp index 2c29b2ca..52968ce8 100644 --- a/src/Deploy/src/Distributions/idistribution.cpp +++ b/src/Deploy/src/Distributions/idistribution.cpp @@ -252,7 +252,7 @@ bool iDistribution::collectInfo(const DistroModule& pkg, info.Custom["[\"array\", \"of\", \"shortcut\", \"cmds\"]"] = cmdShortCutsArray; info.Custom["$BASH_ARRAY_APPLICATIONS"] = bashArray; - info.Custom["$BASH_ARRAY_APPLICATIONS"] = bashArray; + info.Custom["$BASH_ARRAY_SHORTCUTS_APPLICATIONS"] = bashShortCutsArray; if (info.Name.isEmpty()) { info.Name = "Application"; From 2f0e4c4e98e9f4abd7711d4bcfb49202fd136539 Mon Sep 17 00:00:00 2001 From: EndrII Date: Tue, 13 Jun 2023 08:42:10 +0200 Subject: [PATCH 2/2] ref #755 fix debian shortcuts --- .../src/Distributions/Templates/deb/DEBIAN/postinst | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/src/Deploy/src/Distributions/Templates/deb/DEBIAN/postinst b/src/Deploy/src/Distributions/Templates/deb/DEBIAN/postinst index 75d600c5..0a89b211 100755 --- a/src/Deploy/src/Distributions/Templates/deb/DEBIAN/postinst +++ b/src/Deploy/src/Distributions/Templates/deb/DEBIAN/postinst @@ -21,7 +21,7 @@ function createShortCut { echo "Encoding=UTF-8" >> $DEST_FILE echo "Name=$DEST_NAME" >> $DEST_FILE echo "Type=Application" >> $DEST_FILE - echo "Icon=$CQT_INSTALL_DEB_DIR/icons/${SRC_FILE%%.*}.png" >> $DEST_FILE + echo "Icon=$TARGET_DIR/icons/${DEST_NAME}.png" >> $DEST_FILE echo "Terminal=false" >> $DEST_FILE echo "Exec=$SRC_FILE" >> $DEST_FILE @@ -34,8 +34,6 @@ echo "Available commands:" for app in "${APPS[@]}" do - DEST_NAME=$app - if [ ! -e /usr/bin/"${app,,}" ]; then ln -s "$TARGET_DIR/$app.sh" /usr/bin/"${app,,}" echo "${app,,}" @@ -45,10 +43,10 @@ done for app in "${APPS_SHORTCUTS[@]}" do - DEST_NAME=$app + DEST_NAME=${app%.*} SRC_FILE="$TARGET_DIR/$app" - DEST_FILE="/usr/share/applications/${app%.*}.desktop" + DEST_FILE="/usr/share/applications/${DEST_NAME}.desktop" createShortCut done