From b5d52682cab844a5ffdc1b1f2ee80de561e0e6aa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc=20Cornell=C3=A0?= Date: Tue, 19 Nov 2024 15:43:04 +0100 Subject: [PATCH] fix(dash): urlencode special parameters like `:` in query (#12811) In macOS, using queries such as `dash php:enum` does not open Dash.app, possibly due to colon character being interpreted as a port. URL-encoding the parameter (: -> %3A) makes this work again. Fixes https://discord.com/channels/642496866407284746/809850042575093760/1308076125456437300 --- plugins/dash/dash.plugin.zsh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/dash/dash.plugin.zsh b/plugins/dash/dash.plugin.zsh index f6801a870..9abd691c7 100644 --- a/plugins/dash/dash.plugin.zsh +++ b/plugins/dash/dash.plugin.zsh @@ -1,5 +1,5 @@ # Usage: dash [keyword:]query -dash() { open -a Dash.app dash://"$*" } +dash() { open -a Dash.app "dash://$(omz_urlencode -r $*)" } compdef _dash dash _dash() {