Skip to content

- Included applications to detect executable subsystem

Sławomir Lach requested to merge slawomirlach/kio:OSTATKI into master

Plasma5 (KIO) should allow to ran terminal windows and (especially) detect if application need this if user not sure.

I attach the fast prepared patch done in few weeks. I am not KIO/KDEFrameworks/Qt/C++ expert, so please be polite.

User may select behavior in ran executable dialog. That is current approach. Current dialog implementation(UI) could change. I think KIO could move open button, when it is
related to executable into combobox list (current implementation allow to select between GUI/ Console/GUESS, so additional I will add open (for displaying or editing). Another implementation could always decide to guess, except case user clicked on force ran application in terminal window checkbox.

When user decide to guess, we shown notification with open terminal window button.

Current implementation change command parameter given to ran function into konsole or special helper (for guess). Real command go to later parameters.

Current implementation are only for fileviews. Krunner not work with it and I do not known if this makes ever sense.

USE CASE: User download printer/scanner text installer. Click on it, KDE currently shown only dialog with question to execute, but when applying my patch, it will additionally to select guess, so user do not have to try to figure out what to do, when application was console.

User download browsh or some sud game. Case similar to above.

User download some script detecting distribution and install suitable package. It could be security problem, but it will makes things better/simpler.

IMPORTANT:

  1. We can choose solution, which do not preserve autodetection always works for GUI apps. User may omit notification app is console if app is GUI (in my opinion)
  2. Currently, some gui apps (especially X applications, which do not use Xlib/Xcb, but implement X11 by themselves) are wrong detected
  3. I will try to increase correct detection ration, but cannot promise anything. As far as I known, there is no way to detect app on other end of network stream. As far as I known, X11 (due to security reasons) force to use TCP network socket.
  4. There is probably a lot to do with UI I describe possible changes above
  5. Some console apps would not work, since my console server implementation is not implemented in 100%. curses app would not work. Making curses apps to work is not hard - only set term env and term size, I think.
  6. I must probably rewrite detector to C++/KFrameworks, but it could be hardest part.
Edited by Sławomir Lach

Merge request reports