executing xdg-open doesn't work when used in a shortcut
- Dominant language
- C++
- Stars
- 12.3k
- Forks
- 593
- Avg merge
- 2d 8h
- Merged PRs (30d)
- 9
Description
**Describe the bug**
executing xdg-open doesn't work when used in a shortcut, when trying to open
* a pitcure with gwenview (default binding) or
* a pdf with okular (default binding)
although some apps work like opening a folder in dolphin (default binding)
using this script always works:
```
[Command]
Command="
/usr/bin/xdg-open %1"
Icon=
InMenu=true
Input=text/plain
Name=xdg-open
```
but using xdg open with a shortcut, doesn't work, although it shows the app getting opened (in the task manager) but nothing happens afterwards, when trying to
* open a pitcure with gwenview (default binding) or
* a pdf with okular (default binding)
although some apps work like dolphin (default binding)
```
[Command]
Command="
copyq:
select(0)
execute('/usr/bin/xdg-open', clipboard())
"
GlobalShortcut=meta+shift+r
Icon=
IsGlobalShortcut=true
Name=xdg-open shortcut
OutputTab=&clipboard
```
Maybe it has something to do witht the fact, that xdg-open exits directly after getting called and starting the app in the background?
**To Reproduce**
put a filepath (that exists) in the copyq clipboard (like a pdf, jpg, ...) and start the shortcut with meta+shift+r
```
[Command]
Command="
copyq:
select(0)
execute('/usr/bin/xdg-open', clipboard())
"
GlobalShortcut=meta+shift+r
Icon=
IsGlobalShortcut=true
Name=xdg-open shortcut
OutputTab=&clipboard
```
**Expected behavior**
the associated app opens the file
**Version, OS and Environment**
CopyQ Clipboard Manager 10.0.0
Qt: 6.8.3
Compiler: GCC
Arch: x86_64-little_endian-lp64
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.