From ee4ce5ae5fe752bc0c841da7e150bbf7a8bb91d9 Mon Sep 17 00:00:00 2001 From: westor Date: Mon, 1 Feb 2021 17:35:38 -0800 Subject: [PATCH 1/2] Add /JSONHelp command This could be useful if you wanna search something fast (e.g: syntax or examples) If someone specify a /command or $identifier parameter it will open that specific page (if exists) Examples: /JSONHelp /JSONHelp /JSONOpen /JSONHelp $JSON - Thanks! --- src/JSON For mIRC.mrc | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/src/JSON For mIRC.mrc b/src/JSON For mIRC.mrc index 3c4479f..e7ab739 100644 --- a/src/JSON For mIRC.mrc +++ b/src/JSON For mIRC.mrc @@ -660,6 +660,22 @@ alias JSONShutDown { } } +; /JSONHelp @Param +;; Opening the online doc for help +;; +;; @Parm - string - Optional +;; The identifier or the command that you want help +alias JSONHelp { + ;; If the given parameter is /command + if ($1) && ($left($1,1) == $chr(47)) { url https://sreject.github.io/JSON-For-Mirc/reference#cmd/ $+ $right($1,-1) | return } + + ;; If the given parameter is $identifier + if ($1) && ($left($1,1) == $chr(36)) { url https://sreject.github.io/JSON-For-Mirc/reference#id/ $+ $right($1,-1) | return } + + ;; If no parameters opening the general reference page + url https://sreject.github.io/JSON-For-Mirc/reference +} + ;;======================================;; ;; ;; From dfcf02609ec169c52f7122310ab6ae3ca2a0b76a Mon Sep 17 00:00:00 2001 From: westor Date: Mon, 1 Feb 2021 17:37:38 -0800 Subject: [PATCH 2/2] Fix Typo --- src/JSON For mIRC.mrc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/JSON For mIRC.mrc b/src/JSON For mIRC.mrc index e7ab739..b14eedb 100644 --- a/src/JSON For mIRC.mrc +++ b/src/JSON For mIRC.mrc @@ -663,7 +663,7 @@ alias JSONShutDown { ; /JSONHelp @Param ;; Opening the online doc for help ;; -;; @Parm - string - Optional +;; @Param - string - Optional ;; The identifier or the command that you want help alias JSONHelp { ;; If the given parameter is /command