Diffusion KIO 2bb58858c8f6

Added dialog to set execute permission for executable file when trying to run…

Authored by mdlubakowski on Sep 3 2019, 10:05 AM.

Description

Added dialog to set execute permission for executable file when trying to run it.

Summary:
Currently if you try to run executable file for which you don't have execute permission, KRun will either open it in some default program, or prompt user to choose one. It would make sense that, if a file can be normally run with +x permission, user should be asked if he likes to automatically make it executable and run it. If user chooses "Open" option, KRun falls back to default behavior.
This QoL change makes it easier to just download & run things like AppImage files.
Obviously, running executables downloaded from the internet may not be safe, so a warning is included in the prompt.

Here is how it looks:

Test Plan:

  1. Obtain two executable files (e.g. AppImage), set +x on one and -x on another.
  2. Try to run both files. The one with +x will run normally, the other one will show the prompt.

Reviewers: Frameworks, dfaure, cfeck, pino

Reviewed By: dfaure

Subscribers: broulik, ngraham, probono, kde-frameworks-devel

Tags: Frameworks

Differential Revision: https://phabricator.kde.org/D22510