mirror of
https://github.com/kovidgoyal/kitty
synced 2026-07-05 23:51:29 +02:00
Restrict custom launch actions to be prefixed with kitty:///launch/
Preserve the kitty URL scheme for further use.
This commit is contained in:
@@ -259,6 +259,9 @@ def actions_for_url(url: str, actions_spec: Optional[str] = None) -> Iterator[Ke
|
||||
|
||||
|
||||
def actions_for_launch(url: str) -> Iterator[KeyAction]:
|
||||
# Custom launch actions using kitty URL scheme needs to be prefixed with `kitty:///launch/`
|
||||
if url.startswith('kitty://') and not url.startswith('kitty:///launch/'):
|
||||
return
|
||||
found = False
|
||||
for action in actions_for_url_from_list(url, load_launch_actions()):
|
||||
found = True
|
||||
|
||||
Reference in New Issue
Block a user