Skip to content

Commit

Permalink
Don't modify the usr/share/applications .desktop instead write a new …
Browse files Browse the repository at this point in the history
…one in the appdir root.
  • Loading branch information
Alexis López Zubieta committed Feb 13, 2018
1 parent 8f47135 commit 306dc9a
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions build_scripts/appimage.create.wrapper.sh
Expand Up @@ -26,7 +26,6 @@ WRAPPER_PATH=appdir/usr/bin/${WRAPPER_NAME}

# Create file
mkdir -p appdir/usr/bin/

touch ${WRAPPER_PATH}
chmod +x ${WRAPPER_PATH}

Expand All @@ -40,9 +39,11 @@ echo "export XDG_DATA_DIRS=\${XDG_DATA_DIRS}:\${APPDIR}/usr/share/" | tee -a ${W

echo "\${APPDIR}/usr/bin/${RUNNABLE}" | tee -a ${WRAPPER_PATH}

# Replacing .desktop runnable
# cp ${DESKTOP_FILE} ${DESKTOP_FILE}.old
sed -i "s/Exec=${RUNNABLE}/Exec=${WRAPPER_NAME}/g" ${DESKTOP_FILE}
# Write appdir .desktop
DESKTOP_FILE_TARGET=appdir/`basename ${DESKTOP_FILE}`

cp ${DESKTOP_FILE} ${DESKTOP_FILE_TARGET}
sed -i "s/Exec=${RUNNABLE}/Exec=${WRAPPER_NAME}/g" ${DESKTOP_FILE_TARGET}

echo "Done"
echo ""

0 comments on commit 306dc9a

Please sign in to comment.