Creating a .desktop file to run console applications inside the terminal from the dock.
-
Hi,
With the 16.04 ubports version I used to be able to put a console application into the launcher menu by creating a .desktop file in
/home/phablet/.local/share/applications/
with this kind of Exec= hack:[Desktop Entry] Version=1.0 Type=Application Terminal=false Exec=env SHELL=/home/phablet/decrypt-home-run.sh aa-exec-click -p com.ubuntu.terminal_terminal_1.0.1 -- terminal %u Icon=/usr/share/icons/Humanity/status/32/locked.svg Name=Decrypt X-Ubuntu-Touch=true X-Ubuntu-Default-Department-ID=accessories Path=/usr/share/click/preinstalled/.click/users/@all/com.ubuntu.terminal
I use this on my phones to run a very experimental/hacky/dangerous script that decrypts my /home/phablet directory using cryptsetup/luks (ubports does not appear to support this in a proper and stable way).
However this .desktop file hack ceased to work on my Volla 22 with ubports 20.04. The .desktop files nowadays seem to reference a secondary .desktop file in the click package directory
X-Lomiri-Source-Desktop=/usr/share/click/preinstalled/.click/users/@all/terminal.ubports/lomiri-terminal-app.desktop
And it appears that just copying the terminal app's .desktop file in
.local/share/applications
is insufficient to create a customized launcher for the terminal.Any ideas of how to proceed here? I really have problems understanding how the ubports UI works on the technical side. Are there maybe other options to have a simple scripted qml UI-application in /home/phablet that can be executed via
Exec=qmlscene
(i.e. something that can be done without having to install any toolchain)?But then maybe a qml-only application won't have access to running shell commands?
cheers,
Dave
-
-
I don't know why you couldn't create a config file to run your console application, .
I have done this:
- (/bin/bash in terminal, libertine container)
fakeroot apt update fakeroot apt install sway
- use OpenStore tedit text editor app to write the desktop entry,
Version=1.0 Type=Application Terminal=false Exec=libertine-launch -i [container name] sway Name=Sway app window manager, i3 compatible WM X-Lomiri-Touch=true X-Lomiri-Default-Department-ID=accessories X-Ubuntu-Touch=true X-Ubuntu-Default-Department-ID=accessories
- then
cp -v ~/.local/share/tedit.danfro/libertine-application-container-sway.desktop.txt ~/.local/share/applications/libertine-application-container-sway.desktop