Implement Custom URL Protocol Handling#15378
Conversation
Review Summary by QodoImplement custom URL protocol handler for browser extension integration
WalkthroughsDescription• Implement custom jabref:// URL protocol handler registration across platforms • Filter protocol handler URLs from CLI arguments to prevent parsing errors • Add Focus UI command when protocol handler is invoked • Register platform-specific protocol handlers (macOS via Desktop API, Windows/Linux via installers) • Add comprehensive unit tests for protocol handler argument filtering Diagramflowchart LR
A["OS triggers jabref:// URL"] --> B["ArgumentProcessor filters protocol args"]
B --> C["protocolHandlerInvoked flag set"]
C --> D["Focus UI command added"]
A --> E["macOS Desktop API handler"]
E --> D
F["Windows Registry setup"] --> G["Protocol handler registered"]
H["Linux desktop file setup"] --> G
G --> A
File Changes1. jabgui/src/main/java/org/jabref/cli/ArgumentProcessor.java
|
Code Review by Qodo
1.
|
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
|
On Linux the .desktop file is: There is With these two changes it seems to work as intended |
|
Your pull request conflicts with the target branch. Please merge with your code. For a step-by-step guide to resolve merge conflicts, see https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/addressing-merge-conflicts/resolving-a-merge-conflict-using-the-command-line. |
✅ All tests passed ✅🏷️ Commit: a8d6298 Learn more about TestLens at testlens.app. |
Related issues and pull requests
Closes no direct related Issue in JabRef repository
Related JabRef/JabRef-Browser-Extension-fresh#17
Related to JabRef/JabRef-Browser-Extension-fresh#18
Related to #14884
Accidently closed old pr: #15294
PR Description
Implements Custom URL Protocol Handling so that the browser extension can open/focus the JabRef Desktop-App if its not running. More specifically, we register the custom URL protocol in the installation processes of the various operating systems and ensure that the application can handle the call by the OS.
This PR is part my bachelorthesis regarding the communication between the browser extension and the JabRef Desktop-App. The corresponding PR in the JabRef-Browser-Extension-fresh repository will follow shortly.
_Hint: This PR will follow another one which adds the MADR for it.
Steps to test
jabref://orjabref://openin browserChecklist
CHANGELOG.mdin a way that can be understood by the average user (if change is visible to the user)