Skip to content
Commit fdd7c47c authored by Ahmad Samir's avatar Ahmad Samir
Browse files

OpenUrlJob: handle all text scripts consistently

Previously we only handled application/x-shellscript, but there are other
scripts; a script is technically a file that inherits both text/plain and
application/x-executable, e.g. .sh, .csh, .py, perl scripts ...etc. Treat
all those mime types the way we handled shell scripts:
  - if it's not a local url, or isn't executable we open it in the preferred
    text editor
  - if it's executable either show the OpenOrExecute dialog or execute
    directly depending on how the job is configured

The mimetype world is a confusing one:
  - Executables, this includes .exe files (MS Windows); and "application/x-executable"
    and "application/x-sharedlib", this depends on various parameters (e.g.
    stripped executables are x-sharedlib, the same executable if not stripped
    is x-executable...)
  - Scripts: shell, python, perl... etc scripts, which are text files that
    can be executed or opened as text.

Adjust the unit test.

BUG: 425829
BUG: 425177
FIXED-IN: 5.75
parent ea621368
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment