Bug 486193 - Activity overrides for kde-open
Summary: Activity overrides for kde-open
Status: REPORTED
Alias: None
Product: kde-cli-tools
Classification: Plasma
Component: general (other bugs)
Version First Reported In: 6.0.4
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: Aleix Pol
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-04-27 11:27 UTC by gudvinr+kde
Modified: 2024-04-27 11:27 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description gudvinr+kde 2024-04-27 11:27:39 UTC
SUMMARY

Sometimes different workflows require different sets of applications that do the same.
Probably notable example is web browser.
It's so notable that people create workarounds like activity aware firefox (https://matija.suklje.name/introducing-activity-aware-firefox) to solve this issue.

Possible use cases where differentiate by activity can help:
- work and personal e-mail, chat, browser apps
- guest workspace where browser and other apps have disabled history
- creation workspace open .STL in blender, production will use 3D printing software
- dev workspace will open Kate, all other workspaces will use kwrite
- etc

De-facto standard of resolving URIs is xdg-open, which in turn runs kde-open in case if it detects KDE.
Since KDE is in control of what's being opened when an app requests file association, it is also possible to handle overrides in centralized way.

Thus, I'd suggest to add per-activity overrides for default apps:
- If user adds override for web browser in activity settings for activity A and is currently using this activity, kde-open will resolve web browser to value from this setting
- In any other case, e.g. if activity B has different override or doesn't have an override at all, kde-open will either default value or corresponding override

For current users and ones who don't need that nothing will change.

Potential downside is that KIO might have an additional dependency to access activities, but since you can get current activity using d-bus I don't think it's a huge dealbreaker.

SOFTWARE/OS VERSIONS
Operating System: Arch Linux 
KDE Plasma Version: 6.0.4
KDE Frameworks Version: 6.1.0
Qt Version: 6.7.0
Kernel Version: 6.6.28-1-lts (64-bit)
Graphics Platform: X11