diff --git a/modules/lang/json/config.el b/modules/lang/json/config.el index 62db538af..9c847c684 100644 --- a/modules/lang/json/config.el +++ b/modules/lang/json/config.el @@ -11,4 +11,13 @@ (map! :after json-mode :map json-mode-map :localleader - "s" #'jsons-print-path)) + "p" #'jsons-print-path)) + + +(use-package! counsel-jq + :defer t + :init + (map! :after json-mode + :map json-mode-map + :localleader + "s" #'counsel-jq)) diff --git a/modules/lang/json/doctor.el b/modules/lang/json/doctor.el new file mode 100644 index 000000000..5578829e2 --- /dev/null +++ b/modules/lang/json/doctor.el @@ -0,0 +1,4 @@ +;;; lang/json/doctor.el -*- lexical-binding: t; -*- + +(unless (executable-find "jq") + (warn! "Couldn't find jq. counsel-jq won't work.")) diff --git a/modules/lang/json/packages.el b/modules/lang/json/packages.el index 69d84fb8a..95f58186d 100644 --- a/modules/lang/json/packages.el +++ b/modules/lang/json/packages.el @@ -3,3 +3,4 @@ (package! json-mode :pin "0e819e519a") (package! json-snatcher :pin "c4cecc0a50") +(package! counsel-jq :pin "b14dfc5c18")