summaryrefslogtreecommitdiff
path: root/fnl
diff options
context:
space:
mode:
authorGustaf Rydholm <gustaf.rydholm@gmail.com>2024-03-25 20:36:00 +0100
committerGustaf Rydholm <gustaf.rydholm@gmail.com>2024-03-25 20:36:00 +0100
commit3986ab171ff3e784932a87840e7e8463774f5b19 (patch)
treeaf20dd0d76a67a2aa89a4a6d110c7e8a912516f4 /fnl
parentadd2292efbed0be9ad5694c22ee9a3b12c1de726 (diff)
Add rest plugin
Diffstat (limited to 'fnl')
-rw-r--r--fnl/plugins/rest.fnl18
-rw-r--r--fnl/plugins/telescope.fnl8
-rw-r--r--fnl/plugins/treesitter.fnl4
3 files changed, 29 insertions, 1 deletions
diff --git a/fnl/plugins/rest.fnl b/fnl/plugins/rest.fnl
new file mode 100644
index 0000000..6d6f555
--- /dev/null
+++ b/fnl/plugins/rest.fnl
@@ -0,0 +1,18 @@
+;; Http client.
+
+(local keybinds [[:<localleader>rr
+ "<cmd>Rest run<cr>"
+ "Run request under the cursor"]
+ [:<localleader>rs
+ "<cmd>Rest run last<cr>"
+ "Re-run last request"]
+ [:<localleader>rt
+ "<cmd>Telescope rest select_env theme=dropdown<cr>"
+ "Select env"]])
+
+{1 :rest-nvim/rest.nvim
+ :ft :http
+ :dependencies [{1 :vhyrro/luarocks.nvim :priority 1000 :config true}]
+ :config (lambda []
+ (let [rest-nvim (require :rest-nvim)]
+ (rest-nvim.setup {: keybinds})))}
diff --git a/fnl/plugins/telescope.fnl b/fnl/plugins/telescope.fnl
index ef0054b..d45fefb 100644
--- a/fnl/plugins/telescope.fnl
+++ b/fnl/plugins/telescope.fnl
@@ -29,7 +29,13 @@
:nvim-telescope/telescope-frecency.nvim
:lyz-code/telescope-orgmode.nvim])
-(local extensions [:fzf :frecency :orgmode :projects :git_worktree :harpoon])
+(local extensions [:fzf
+ :frecency
+ :orgmode
+ :projects
+ :git_worktree
+ :harpoon
+ :rest])
(fn load-extensions [telescope]
(each [_ extension (ipairs extensions)]
diff --git a/fnl/plugins/treesitter.fnl b/fnl/plugins/treesitter.fnl
index 02b7a64..546abc7 100644
--- a/fnl/plugins/treesitter.fnl
+++ b/fnl/plugins/treesitter.fnl
@@ -7,9 +7,12 @@
:comment
:dockerfile
:fennel
+ :graphql
:haskell
:hcl
:html
+ :http
+ :json
:latex
:lua
:make
@@ -22,6 +25,7 @@
:toml
:vim
:vimdoc
+ :xml
:yaml]
:sync_install false
:ignore_install [""]