-
Notifications
You must be signed in to change notification settings - Fork 118
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
[wishlist] Support .desktop files #21
Comments
You means if [Desktop Entry]
Name=Neovim
GenericName=Text Editor
TryExec=nvim
Exec=nvim %F
Terminal=true
Type=Application
Keywords=Text;editor;
Icon=nvim
Categories=Utility;TextEditor;
StartupNotify=false
MimeType=text/english;text/plain;text/x-makefile;text/x-c++hdr;text/x-c++src;text/x-chdr;text/x-csrc;text/x-java;text/x-moc;text/x-pascal;text/x-tcl;text/x-tex;application/x-shellscript;text/x-c;text/x-c++; Termux-widget will provide a button which uses It looks good because it keep consistent with linux programs. However I have [Desktop Entry]
Version=1.0
Type=Application
Name=GNU Image Manipulation Program
Comment=Create images and edit photographs
Exec=gimp-2.10 %U
TryExec=gimp-2.10
Icon=gimp
Terminal=false
Categories=Graphics;2DGraphics;RasterGraphics;GTK;
StartupNotify=true
MimeType=image/bmp;image/g3fax;image/gif;image/x-fits;image/x-pcx;image/x-portable-anymap;image/x-portable-bitmap;image/x-portable-graymap;image/x-portable-pixmap;image/x-psd;image/x-sgi;image/x-tga;image/x-xbitmap;image/x-xwindowdump;image/x-xcf;image/x-compressed-xcf;image/x-gimp-gbr;image/x-gimp-pat;image/x-gimp-gih;image/x-sun-raster;image/tiff;image/jpeg;image/x-psp;application/postscript;image/png;image/x-icon;image/x-xpixmap;image/x-exr;image/webp;image/x-webp;image/heif;image/heic;image/avif;image/svg+xml;application/pdf;image/x-wmf;image/jp2;image/x-xcursor; When user press the button of gimp, should termux open vnc or a X11 server app (See |
Linux desktop files are not translatable to Android reqs, but anyways, |
Current shortcuts are typically command-line programs that use stdin/out and have a delimited life time. With git-annex coming to termux, the possibility of other webapp-style local apps following, as well as envisioning the consequenes of an SDL2 port to termux, those might be only a part of what we might want to launch from a desktop icon. Scripts that utilize
termux-toast
ortermux-dialog
likely would also prefer to indicate that they don't need the background terminal.I suggest that Linux desktop files be adopted for that purpose. termux-widget could not only look for executable files in
~/.shortcuts
, but also for .desktop files as$XDG_DATA_DIRS/applications/**/*.desktop
. Those files could state a localized name of the launcher, an icon, carry custom metadata (like for #20 / #10) and indicate whether a terminal window should be shown at all by setting theTerminal
key.(Alternatives are assuming that everything is shell script and putting metadata in comment lines after the shebang (a practice that has some spread but which I deplore), or Windows 3.1 style PIF files).
Games like
moria
already have appropriate .desktop files in their Debian packages, and could thus easily become launcher-enabled through termux-widget, complete with name and icon. (Or through a successor to termux-widget, if it turns out that .desktop files are the way to go but termux-widget should stay and there'd be another app that implements .desktop files).The text was updated successfully, but these errors were encountered: