mirror of
https://github.com/elkowar/dots-of-war.git
synced 2024-11-06 03:12:24 +00:00
Move to new structure of lazy.vim
This commit is contained in:
parent
d308c62308
commit
f3111fdcaa
38 changed files with 1256 additions and 1191 deletions
1
nvim/.config/nvim/.gitignore
vendored
1
nvim/.config/nvim/.gitignore
vendored
|
@ -1,2 +1,3 @@
|
||||||
lua
|
lua
|
||||||
plugin
|
plugin
|
||||||
|
lua-old
|
||||||
|
|
2
nvim/.config/nvim/.nfnl.fnl
Normal file
2
nvim/.config/nvim/.nfnl.fnl
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
{}
|
||||||
|
|
|
@ -1,6 +1,4 @@
|
||||||
(module dots.colors
|
{:bg_main (if (= "epix" (vim.fn.hostname)) "#1d2021" "#282828")
|
||||||
{}
|
|
||||||
{:bg_main (if (= "epix" (vim.fn.hostname)) "#1d2021" "#282828")
|
|
||||||
:bg_second (if (= "epix" (vim.fn.hostname)) "#181A1B" "#1d2021")
|
:bg_second (if (= "epix" (vim.fn.hostname)) "#181A1B" "#1d2021")
|
||||||
:dark0_hard "#1d2021"
|
:dark0_hard "#1d2021"
|
||||||
:dark0 "#282828"
|
:dark0 "#282828"
|
||||||
|
@ -37,4 +35,4 @@
|
||||||
:faded_purple "#8f3f71"
|
:faded_purple "#8f3f71"
|
||||||
:faded_aqua "#427b58"
|
:faded_aqua "#427b58"
|
||||||
:faded_orange "#af3a03"
|
:faded_orange "#af3a03"
|
||||||
:gray "#928374"})
|
:gray "#928374"}
|
||||||
|
|
|
@ -1,12 +1,12 @@
|
||||||
(module dots.help-thingy
|
(fn help-thingy-kram []
|
||||||
{autoload {utils dots.utils
|
(local {: autoload} (require :nfnl.module))
|
||||||
a aniseed.core
|
(local utils (autoload :dots.utils))
|
||||||
str aniseed.string
|
(local a (autoload :aniseed.core))
|
||||||
popup popup
|
(local str (autoload :aniseed.string))
|
||||||
ts nvim-treesitter}
|
(local popup (autoload :popup))
|
||||||
require-macros [macros]})
|
(local ts (autoload :nvim-treesitter))
|
||||||
|
|
||||||
(defn pop [text ft]
|
(defn pop [text ft]
|
||||||
"Open a popup with the given text and filetype"
|
"Open a popup with the given text and filetype"
|
||||||
(var width 20)
|
(var width 20)
|
||||||
(each [_ line (ipairs text)]
|
(each [_ line (ipairs text)]
|
||||||
|
@ -18,23 +18,23 @@
|
||||||
(popup.create bufnr {:padding [1 1 1 1] :width width})))
|
(popup.create bufnr {:padding [1 1 1 1] :width width})))
|
||||||
|
|
||||||
|
|
||||||
(defn get-current-word []
|
(defn get-current-word []
|
||||||
"Return the word the cursor is currently hovering over"
|
"Return the word the cursor is currently hovering over"
|
||||||
(let [col (. (vim.api.nvim_win_get_cursor 0) 2)
|
(let [col (. (vim.api.nvim_win_get_cursor 0) 2)
|
||||||
line (vim.api.nvim_get_current_line)]
|
line (vim.api.nvim_get_current_line)]
|
||||||
(.. (vim.fn.matchstr (line:sub 1 (+ col 1)) "\\k*$")
|
(.. (vim.fn.matchstr (line:sub 1 (+ col 1)) "\\k*$")
|
||||||
(string.sub (vim.fn.matchstr (line:sub (+ col 1)) "^\\k*")
|
(string.sub (vim.fn.matchstr (line:sub (+ col 1)) "^\\k*")
|
||||||
2))))
|
2))))
|
||||||
(def helpfiles-path (str.join "/" (a.butlast (str.split vim.o.helpfile "/"))))
|
(def helpfiles-path (str.join "/" (a.butlast (str.split vim.o.helpfile "/"))))
|
||||||
|
|
||||||
(def tags
|
(def tags
|
||||||
(var entries {})
|
(var entries {})
|
||||||
(each [line _ (io.lines (.. helpfiles-path "/tags"))]
|
(each [line _ (io.lines (.. helpfiles-path "/tags"))]
|
||||||
(let [[key file address] (str.split line "\t")]
|
(let [[key file address] (str.split line "\t")]
|
||||||
(tset entries key {:file (.. helpfiles-path "/" file) :address address})))
|
(tset entries key {:file (.. helpfiles-path "/" file) :address address})))
|
||||||
entries)
|
entries)
|
||||||
|
|
||||||
(defn find-help-tag-for [topic]
|
(defn find-help-tag-for [topic]
|
||||||
(or (. tags topic)
|
(or (. tags topic)
|
||||||
(. tags (.. topic "()"))
|
(. tags (.. topic "()"))
|
||||||
(. tags (.. (string.gsub topic "vim%.api%." "") "()"))
|
(. tags (.. (string.gsub topic "vim%.api%." "") "()"))
|
||||||
|
@ -45,7 +45,7 @@
|
||||||
(. tags (.. (string.gsub topic "vim%.g%." "") "()"))))
|
(. tags (.. (string.gsub topic "vim%.g%." "") "()"))))
|
||||||
|
|
||||||
|
|
||||||
(defn help-for-tag [tag]
|
(defn help-for-tag [tag]
|
||||||
(var data nil)
|
(var data nil)
|
||||||
(each [line _ (io.lines tag.file)]
|
(each [line _ (io.lines tag.file)]
|
||||||
(if (= nil data)
|
(if (= nil data)
|
||||||
|
@ -59,9 +59,10 @@
|
||||||
(table.insert data line)
|
(table.insert data line)
|
||||||
(lua "return data")))))
|
(lua "return data")))))
|
||||||
|
|
||||||
(fn _G.get_help []
|
(fn _G.get_help []
|
||||||
(if-let [help-tag (find-help-tag-for (get-current-word))]
|
(if-let [help-tag (find-help-tag-for (get-current-word))]
|
||||||
(pop (help-for-tag help-tag) :help)))
|
(pop (help-for-tag help-tag) :help)))
|
||||||
|
|
||||||
(utils.keymap :n :ML ":call v:lua.get_help()<CR>")
|
(utils.keymap :n :ML ":call v:lua.get_help()<CR>"))
|
||||||
|
|
||||||
|
[]
|
||||||
|
|
|
@ -1,14 +1,12 @@
|
||||||
(module dots.keybinds
|
(import-macros {: al} :macros)
|
||||||
{autoload {a aniseed.core
|
(al a nfnl.core)
|
||||||
str aniseed.string
|
(al str nfnl.string)
|
||||||
nvim aniseed.nvim
|
(al utils dots.utils)
|
||||||
utils dots.utils
|
(al wk which-key)
|
||||||
wk which-key
|
; (al treesitter-selection nvim-treesitter.incremental_selection)
|
||||||
treesitter-selection nvim-treesitter.incremental_selection
|
(al lspactions lspactions)
|
||||||
lspactions lspactions
|
(al glance glance)
|
||||||
glance glance
|
(al crates crates)
|
||||||
crates crates}
|
|
||||||
require-macros [macros]})
|
|
||||||
|
|
||||||
; undo autopairs fuckup
|
; undo autopairs fuckup
|
||||||
(set vim.g.AutoPairsShortcutBackInsert "<M-b>")
|
(set vim.g.AutoPairsShortcutBackInsert "<M-b>")
|
||||||
|
@ -52,7 +50,7 @@
|
||||||
;(utils.keymap [:n] :j "gj")
|
;(utils.keymap [:n] :j "gj")
|
||||||
;(utils.keymap [:n] :k "gk")
|
;(utils.keymap [:n] :k "gk")
|
||||||
|
|
||||||
(defn open-selection-zotero []
|
(fn open-selection-zotero []
|
||||||
(let [(_ _ sel) (utils.get-selection)]
|
(let [(_ _ sel) (utils.get-selection)]
|
||||||
(vim.cmd (.. "silent !xdg-open zotero://select/items/@" (str.join sel)))))
|
(vim.cmd (.. "silent !xdg-open zotero://select/items/@" (str.join sel)))))
|
||||||
|
|
||||||
|
@ -62,21 +60,21 @@
|
||||||
(fn rebind [s desc] [s desc])
|
(fn rebind [s desc] [s desc])
|
||||||
|
|
||||||
|
|
||||||
(defn format []
|
(fn format []
|
||||||
(if (a.some #$1.server_capabilities.documentFormattingProvider (vim.lsp.get_active_clients))
|
(if (a.some #$1.server_capabilities.documentFormattingProvider (vim.lsp.get_active_clients))
|
||||||
(vim.lsp.buf.format {:async true})
|
(vim.lsp.buf.format {:async true})
|
||||||
(vim.cmd "Neoformat")))
|
(vim.cmd "Neoformat")))
|
||||||
|
|
||||||
(defn open-rename []
|
(fn open-rename []
|
||||||
(vim.api.nvim_feedkeys (.. ":IncRename " (vim.fn.expand "<cword>")) "n" ""))
|
(vim.api.nvim_feedkeys (.. ":IncRename " (vim.fn.expand "<cword>")) "n" ""))
|
||||||
|
|
||||||
(defn toggle-lsp-lines []
|
(fn toggle-lsp-lines []
|
||||||
(let [lsp-lines (require "lsp_lines")]
|
(let [lsp-lines (require "lsp_lines")]
|
||||||
(vim.diagnostic.config {:virtual_lines (not (. (vim.diagnostic.config) :virtual_lines))})
|
(vim.diagnostic.config {:virtual_lines (not (. (vim.diagnostic.config) :virtual_lines))})
|
||||||
; TODO: this doesn't seem to work...
|
; TODO: this doesn't seem to work...
|
||||||
(vim.diagnostic.config {:virtual_text (not (. (vim.diagnostic.config) :virtual_lines))})))
|
(vim.diagnostic.config {:virtual_text (not (. (vim.diagnostic.config) :virtual_lines))})))
|
||||||
|
|
||||||
(defn toggle-lsp-lines-current []
|
(fn toggle-lsp-lines-current []
|
||||||
(let [lsp-lines (require "lsp_lines")]
|
(let [lsp-lines (require "lsp_lines")]
|
||||||
(vim.diagnostic.config {:virtual_lines {:only_current_line true}})))
|
(vim.diagnostic.config {:virtual_lines {:only_current_line true}})))
|
||||||
|
|
||||||
|
@ -191,5 +189,5 @@
|
||||||
:mode "v"})
|
:mode "v"})
|
||||||
|
|
||||||
|
|
||||||
(set nvim.o.timeoutlen 200)
|
(set vim.o.timeoutlen 200)
|
||||||
|
|
||||||
|
|
|
@ -1,267 +0,0 @@
|
||||||
(module dots.plugins
|
|
||||||
{autoload {a aniseed.core
|
|
||||||
lazy lazy}
|
|
||||||
require-macros [macros]})
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
(defn- safe-req-conf [name]
|
|
||||||
"safely require a plugins configuration module, prepending 'dots.plugins.' to the given module name"
|
|
||||||
(let [(ok? val-or-err) (pcall require (.. "dots.plugins." name))]
|
|
||||||
(when (not ok?)
|
|
||||||
(print (.. "Plugin config error: " val-or-err)))))
|
|
||||||
|
|
||||||
(defn setup-lazy [...]
|
|
||||||
(let [pkgs [...]]
|
|
||||||
(local args [])
|
|
||||||
(for [i 1 (a.count pkgs) 2]
|
|
||||||
(let [name (. pkgs i)
|
|
||||||
opts (. pkgs (+ i 1))]
|
|
||||||
(table.insert args (a.assoc opts 1 name))))
|
|
||||||
(lazy.setup args {:colorscheme "gruvbox8"})))
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
(macro cfg [config-mod opts]
|
|
||||||
(let [a (require "aniseed.core")]
|
|
||||||
(a.assoc (or opts {})
|
|
||||||
:opt `false
|
|
||||||
:config `#(require ,config-mod))))
|
|
||||||
|
|
||||||
(macro setup [name opts]
|
|
||||||
`((. (require ,name) :setup) ,opts))
|
|
||||||
|
|
||||||
(setup-lazy
|
|
||||||
; TODO sort me pls
|
|
||||||
|
|
||||||
; sorted from here!
|
|
||||||
:Olical/aniseed {:branch "develop"}
|
|
||||||
; :lewis6991/impatient.nvim {}
|
|
||||||
:nvim-lua/plenary.nvim {}
|
|
||||||
:norcalli/nvim.lua {}
|
|
||||||
:lifepillar/vim-gruvbox8 {:lazy false :priority 1000 :config #(require "dots.plugins.gruvbox8")}
|
|
||||||
:kyazdani42/nvim-web-devicons {}
|
|
||||||
:folke/which-key.nvim {}
|
|
||||||
:folke/todo-comments.nvim {:lazy true
|
|
||||||
:event "VeryLazy"
|
|
||||||
:config #(require "dots.plugins.todo-comments")}
|
|
||||||
|
|
||||||
:Famiu/feline.nvim {:config #(require "dots.plugins.feline")}
|
|
||||||
:akinsho/nvim-bufferline.lua {:config #(require "dots.plugins.bufferline")
|
|
||||||
:tag "v1.1.1"}
|
|
||||||
:ckipp01/nvim-jenkinsfile-linter {:dependencies ["nvim-lua/plenary.nvim"]}
|
|
||||||
|
|
||||||
:psliwka/vim-smoothie {}
|
|
||||||
:norcalli/nvim-colorizer.lua {:event "VeryLazy"
|
|
||||||
:lazy true
|
|
||||||
:config #(require "dots.plugins.nvim-colorizer")}
|
|
||||||
:nathanaelkane/vim-indent-guides {:cmd ["IndentGuidesToggle"]}
|
|
||||||
:luukvbaal/stabilize.nvim {:config #(setup :stabilize)}
|
|
||||||
|
|
||||||
:stevearc/dressing.nvim {:config #(setup :dressing)}
|
|
||||||
|
|
||||||
:tweekmonster/startuptime.vim {:cmd ["StartupTime"]}
|
|
||||||
:folke/noice.nvim {:config #(require "dots.plugins.noice")
|
|
||||||
:dependencies [:MunifTanjim/nui.nvim]}
|
|
||||||
:folke/persistence.nvim {:config #(require "dots.plugins.persistence")}
|
|
||||||
:folke/zen-mode.nvim {:config #(require "dots.plugins.zen-mode")
|
|
||||||
:cmd ["ZenMode"]}
|
|
||||||
:folke/twilight.nvim {:config #(require "dots.plugins.twilight")}
|
|
||||||
:moll/vim-bbye {:lazy true :cmd [:Bdelete :Bwipeout]}
|
|
||||||
:nvim-telescope/telescope.nvim {:config #(require "dots.plugins.telescope")
|
|
||||||
:cmd ["Telescope"]
|
|
||||||
:dependencies [:nvim-lua/popup.nvim
|
|
||||||
:nvim-lua/plenary.nvim]}
|
|
||||||
|
|
||||||
:petertriho/nvim-scrollbar {:event "VeryLazy"
|
|
||||||
:lazy true
|
|
||||||
:config #(setup :scrollbar)}
|
|
||||||
|
|
||||||
"https://git.sr.ht/~whynothugo/lsp_lines.nvim" {:config #(do (setup :lsp_lines)
|
|
||||||
(vim.diagnostic.config {:virtual_lines false}))}
|
|
||||||
|
|
||||||
|
|
||||||
; editing and movement <<<
|
|
||||||
:jiangmiao/auto-pairs {}
|
|
||||||
:tpope/vim-repeat {}
|
|
||||||
:preservim/nerdcommenter {:event "VeryLazy"
|
|
||||||
:lazy true
|
|
||||||
:priority 1000}
|
|
||||||
:godlygeek/tabular {:cmd ["Tabularize"]}
|
|
||||||
:tpope/vim-surround {}
|
|
||||||
:hauleth/sad.vim {}
|
|
||||||
:wellle/targets.vim {} ; more text objects. IE: cin (change in next parens). generally better handling of surrounding objects.
|
|
||||||
:mg979/vim-visual-multi {:lazy true :event "VeryLazy"}
|
|
||||||
:tommcdo/vim-exchange {}
|
|
||||||
:phaazon/hop.nvim {:lazy true
|
|
||||||
:event "VeryLazy"
|
|
||||||
:config #(setup "hop" {:keys "jfkdls;amvieurow"})}
|
|
||||||
;:justinmk/vim-sneak {:lazy true}
|
|
||||||
;:config #(require "dots.plugins.sneak")}
|
|
||||||
; >>>
|
|
||||||
|
|
||||||
; treesitter <<<
|
|
||||||
:nvim-treesitter/nvim-treesitter {:config #(require "dots.plugins.treesitter")
|
|
||||||
:lazy true
|
|
||||||
:event ["VeryLazy"]
|
|
||||||
:build ":TSUpdate"}
|
|
||||||
:RRethy/nvim-treesitter-textsubjects {:dependencies [:nvim-treesitter/nvim-treesitter]
|
|
||||||
:lazy true
|
|
||||||
:event ["VeryLazy"]}
|
|
||||||
|
|
||||||
:JoosepAlviste/nvim-ts-context-commentstring {:event ["VeryLazy"]
|
|
||||||
:lazy true
|
|
||||||
:dependencies [:nvim-treesitter/nvim-treesitter]}
|
|
||||||
|
|
||||||
:nvim-treesitter/playground {:event ["VeryLazy"]
|
|
||||||
:lazy true
|
|
||||||
:dependencies [:nvim-treesitter/nvim-treesitter]}
|
|
||||||
; >>>
|
|
||||||
|
|
||||||
; debugger <<<
|
|
||||||
:rcarriga/nvim-dap-ui {:lazy true
|
|
||||||
:config #(setup :dapui)
|
|
||||||
:dependencies [:mfussenegger/nvim-dap]}
|
|
||||||
:mfussenegger/nvim-dap {:lazy true}
|
|
||||||
:nvim-telescope/telescope-dap.nvim {:lazy true
|
|
||||||
:dependencies [:nvim-telescope/telescope.nvim
|
|
||||||
:mfussenegger/nvim-dap]}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
; >>>
|
|
||||||
|
|
||||||
; git stuff <<<
|
|
||||||
:ldelossa/gh.nvim {:lazy true
|
|
||||||
:config #(do ((. (require "litee.lib") :setup))
|
|
||||||
((. (require "litee.gh") :setup)))
|
|
||||||
:dependencies [:ldelossa/litee.nvim]}
|
|
||||||
:pwntester/octo.nvim {:lazy true
|
|
||||||
:dependencies [:nvim-lua/plenary.nvim
|
|
||||||
:nvim-telescope/telescope.nvim
|
|
||||||
:kyazdani42/nvim-web-devicons]
|
|
||||||
:config #(setup :octo)}
|
|
||||||
:sindrets/diffview.nvim {:cmd ["DiffviewOpen" "DiffviewToggleFiles"]
|
|
||||||
:config #(require "dots.plugins.diffview")}
|
|
||||||
|
|
||||||
:lewis6991/gitsigns.nvim {:dependencies [:vim-gruvbox8
|
|
||||||
:petertriho/nvim-scrollbar]
|
|
||||||
:config #(require "dots.plugins.gitsigns")}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
:ruanyl/vim-gh-line {}
|
|
||||||
:rhysd/conflict-marker.vim {}
|
|
||||||
:tpope/vim-fugitive {:lazy true :event "VeryLazy"}
|
|
||||||
:TimUntersberger/neogit {:config #(require "dots.plugins.neogit")
|
|
||||||
:cmd ["Neogit"]}
|
|
||||||
|
|
||||||
; >>>
|
|
||||||
|
|
||||||
; lsp <<<
|
|
||||||
:ray-x/lsp_signature.nvim {:event :BufEnter}
|
|
||||||
:weilbith/nvim-code-action-menu {:cmd "CodeActionMenu"
|
|
||||||
:config #(set vim.g.code_action_menu_show_details false)}
|
|
||||||
|
|
||||||
:folke/trouble.nvim {:lazy true
|
|
||||||
:config #(require "dots.plugins.trouble")
|
|
||||||
:cmd ["Trouble" "TroubleClose" "TroubleRefresh" "TroubleToggle"]}
|
|
||||||
|
|
||||||
; :elkowar/trouble.nvim {:branch "fix_error_on_nil_window"
|
|
||||||
; :config #(require "dots.plugins.trouble")
|
|
||||||
; :cmd ["Trouble" "TroubleClose" "TroubleRefresh" "TroubleToggle"]}
|
|
||||||
|
|
||||||
:simrat39/symbols-outline.nvim {:lazy true
|
|
||||||
:cmd ["SymbolsOutline" "SymbolsOutlineClose" "SymbolsOutlineOpen"]
|
|
||||||
:config #(require "dots.plugins.symbols-outline")}
|
|
||||||
|
|
||||||
:neovim/nvim-lspconfig {:event "VeryLazy"
|
|
||||||
:lazy true}
|
|
||||||
|
|
||||||
:smjonas/inc-rename.nvim {:config #(setup :inc_rename {:input_buffer_type "dressing"})}
|
|
||||||
:dnlhc/glance.nvim {:lazy true :config #(require "dots.plugins.glance")}
|
|
||||||
; >>>
|
|
||||||
|
|
||||||
; cmp <<<
|
|
||||||
:hrsh7th/vim-vsnip {:lazy true :event ["VeryLazy"]}
|
|
||||||
:hrsh7th/vim-vsnip-integ {:lazy true :event ["VeryLazy"]}
|
|
||||||
:rafamadriz/friendly-snippets {}
|
|
||||||
|
|
||||||
:hrsh7th/nvim-cmp {:lazy true
|
|
||||||
:event ["VeryLazy"]
|
|
||||||
:dependencies [[:hrsh7th/cmp-nvim-lsp]
|
|
||||||
[:hrsh7th/cmp-buffer]
|
|
||||||
[:hrsh7th/cmp-vsnip]
|
|
||||||
[:hrsh7th/cmp-nvim-lua]
|
|
||||||
[:hrsh7th/cmp-calc]
|
|
||||||
[:hrsh7th/cmp-path]
|
|
||||||
[:hrsh7th/cmp-nvim-lsp-signature-help]
|
|
||||||
[:davidsierradz/cmp-conventionalcommits]
|
|
||||||
[:hrsh7th/cmp-omni]]
|
|
||||||
:config #(require "dots.plugins.cmp")}
|
|
||||||
; >>>
|
|
||||||
|
|
||||||
; code-related ----------------------------------------- <<<
|
|
||||||
;:github/copilot.vim {:cmd ["Copilot"]}
|
|
||||||
:zbirenbaum/copilot.lua {:cmd "Copilot"
|
|
||||||
:event "InsertEnter"
|
|
||||||
:config #(require "dots.plugins.copilot")}
|
|
||||||
|
|
||||||
:monkoose/nvlime {:ft ["lisp"] :dependencies [:monkoose/parsley]}
|
|
||||||
|
|
||||||
:tpope/vim-sleuth {}
|
|
||||||
:editorconfig/editorconfig-vim {}
|
|
||||||
:pechorin/any-jump.vim {}
|
|
||||||
:sbdchd/neoformat {}
|
|
||||||
:elkowar/antifennel-nvim {:config #(set vim.g.antifennel_executable "/home/leon/tmp/antifennel/antifennel")}
|
|
||||||
:Olical/conjure {:ft ["fennel"]}
|
|
||||||
:eraserhd/parinfer-rust {:build "cargo build --release"}
|
|
||||||
|
|
||||||
:lervag/vimtex {:ft ["latex" "tex"]
|
|
||||||
:config #(require :dots.plugins.vimtex)}
|
|
||||||
:kmonad/kmonad-vim {}
|
|
||||||
:elkowar/yuck.vim {:ft ["yuck"]}
|
|
||||||
:cespare/vim-toml {:ft ["toml"]}
|
|
||||||
:bduggan/vim-raku {:ft ["raku"]}
|
|
||||||
:LnL7/vim-nix {:ft ["nix"]}
|
|
||||||
:kevinoid/vim-jsonc {}
|
|
||||||
:pangloss/vim-javascript {:ft ["javascript"]} ; syntax highlighting JS
|
|
||||||
:ianks/vim-tsx {:ft ["typescript-react"]}
|
|
||||||
:leafgarland/typescript-vim {:ft ["typescript" "typescript-react" "javascript"]}
|
|
||||||
:HerringtonDarkholme/yats.vim {} ; typescript syntax highlighting
|
|
||||||
:mxw/vim-jsx {}
|
|
||||||
:mattn/emmet-vim {:lazy true
|
|
||||||
:config #(require "dots.plugins.emmet")}
|
|
||||||
:purescript-contrib/purescript-vim {:ft ["purescript"]}
|
|
||||||
:derekelkins/agda-vim {:ft ["agda"]}
|
|
||||||
:neovimhaskell/haskell-vim { :ft ["haskell"]}
|
|
||||||
:monkoose/nvlime {:ft ["lisp"] :dependencies ["monkoose/parsley"] :config #(set vim.g.vlime_overlay "slimv")}
|
|
||||||
|
|
||||||
|
|
||||||
:rust-lang/rust.vim {:ft ["rust"]
|
|
||||||
:dependencies ["mattn/webapi-vim"]
|
|
||||||
:config #(do (set vim.g.rustfmt_fail_silently 1))}
|
|
||||||
|
|
||||||
:simrat39/rust-tools.nvim {:ft ["rust" "toml"]
|
|
||||||
:dependencies ["nvim-lua/popup.nvim" "nvim-lua/plenary.nvim"]}
|
|
||||||
|
|
||||||
:Saecki/crates.nvim {:dependencies ["nvim-lua/plenary.nvim"]
|
|
||||||
:dir "/Users/leon/tmp/crates.nvim"
|
|
||||||
:event ["BufRead Cargo.toml"]
|
|
||||||
:lazy true
|
|
||||||
:config #(require :dots.plugins.crates)}
|
|
||||||
|
|
||||||
:qnighy/lalrpop.vim {}
|
|
||||||
:edwinb/idris2-vim {:ft ["idris2"]}
|
|
||||||
:vmchale/ats-vim {:ft ["ats" "dats" "sats"]}
|
|
||||||
:bakpakin/fennel.vim {:ft ["fennel"]}
|
|
||||||
:evanleck/vim-svelte {})
|
|
||||||
|
|
||||||
|
|
||||||
; >>>
|
|
||||||
|
|
||||||
;(require "packer_compiled")
|
|
||||||
|
|
||||||
; vim:foldmarker=<<<,>>>
|
|
||||||
|
|
||||||
|
|
|
@ -1,13 +1,12 @@
|
||||||
(module dots.plugins.bufferline
|
(import-macros {: al} :macros)
|
||||||
{autoload {a aniseed.core
|
(al a nfnl.core)
|
||||||
nvim aniseed.nvim
|
(al utils dots.utils)
|
||||||
utils dots.utils
|
(al colors dots.colors)
|
||||||
colors dots.colors
|
(al bufferline bufferline)
|
||||||
bufferline bufferline}
|
|
||||||
require-macros [macros]})
|
|
||||||
|
|
||||||
; :h bufferline-lua-highlights
|
(fn setup []
|
||||||
(let [selected {:guibg colors.neutral_aqua :guifg colors.bg_main :gui "NONE"}
|
; :h bufferline-lua-highlights
|
||||||
|
(let [selected {:guibg colors.neutral_aqua :guifg colors.bg_main :gui "NONE"}
|
||||||
visible {:guibg colors.dark1 :guifg colors.neutral_aqua}]
|
visible {:guibg colors.dark1 :guifg colors.neutral_aqua}]
|
||||||
(bufferline.setup
|
(bufferline.setup
|
||||||
{:options
|
{:options
|
||||||
|
@ -54,4 +53,7 @@
|
||||||
; stuff I've never seen before :thonk:
|
; stuff I've never seen before :thonk:
|
||||||
:pick_selected {:guibg colors.bright_red :guifg colors.bright_red}
|
:pick_selected {:guibg colors.bright_red :guifg colors.bright_red}
|
||||||
:tab_selected {:guibg colors.bright_green :guifg colors.bright_green}
|
:tab_selected {:guibg colors.bright_green :guifg colors.bright_green}
|
||||||
:tab {:guibg colors.bright_yellow :guifg colors.bright_yellow}}}))
|
:tab {:guibg colors.bright_yellow :guifg colors.bright_yellow}}})))
|
||||||
|
|
||||||
|
[(utils.plugin :akinsho/nvim-bufferline.lua
|
||||||
|
{:config setup :tag "v1.1.1"})]
|
||||||
|
|
|
@ -1,10 +1,13 @@
|
||||||
(module dots.plugins.cmp
|
(import-macros {: al} :macros)
|
||||||
{autoload {a aniseed.core
|
(al a nfnl.core)
|
||||||
cmp cmp}})
|
(al cmp cmp)
|
||||||
|
(al utils dots.utils)
|
||||||
|
|
||||||
; check this for coloring maybe
|
|
||||||
; https://github.com/hrsh7th/nvim-cmp/blob/ada9ddeff71e82ad0e52c9a280a1e315a8810b9a/lua/cmp/entry.lua#L199
|
(fn setup []
|
||||||
(defn item-formatter [item vim-item]
|
; check this for coloring maybe
|
||||||
|
; https://github.com/hrsh7th/nvim-cmp/blob/ada9ddeff71e82ad0e52c9a280a1e315a8810b9a/lua/cmp/entry.lua#L199
|
||||||
|
(fn item-formatter [item vim-item]
|
||||||
(let [padding (string.rep " " (- 10 (vim.fn.strwidth vim-item.abbr)))
|
(let [padding (string.rep " " (- 10 (vim.fn.strwidth vim-item.abbr)))
|
||||||
details (?. item :completion_item :detail)]
|
details (?. item :completion_item :detail)]
|
||||||
(when details
|
(when details
|
||||||
|
@ -12,7 +15,7 @@
|
||||||
vim-item)
|
vim-item)
|
||||||
|
|
||||||
|
|
||||||
(cmp.setup
|
(cmp.setup
|
||||||
{:snippet {:expand (fn [args] ((. vim.fn :vsnip#anonymous) args.body))}
|
{:snippet {:expand (fn [args] ((. vim.fn :vsnip#anonymous) args.body))}
|
||||||
|
|
||||||
:completion {:autocomplete false}
|
:completion {:autocomplete false}
|
||||||
|
@ -52,6 +55,20 @@
|
||||||
cmp.config.compare.length
|
cmp.config.compare.length
|
||||||
cmp.config.compare.order]}})
|
cmp.config.compare.order]}})
|
||||||
|
|
||||||
(cmp.setup.cmdline "/" {:sources [{:name :buffer}]})
|
(cmp.setup.cmdline "/" {:sources [{:name :buffer}]}))
|
||||||
|
|
||||||
|
|
||||||
|
[(utils.plugin :hrsh7th/vim-vsnip {:lazy true :event ["VeryLazy"]})
|
||||||
|
(utils.plugin :hrsh7th/vim-vsnip-integ {:lazy true :event ["VeryLazy"]})
|
||||||
|
(utils.plugin :rafamadriz/friendly-snippets)
|
||||||
|
(utils.plugin :hrsh7th/nvim-cmp {:lazy true
|
||||||
|
:event ["VeryLazy"]
|
||||||
|
:dependencies [[:hrsh7th/cmp-nvim-lsp]
|
||||||
|
[:hrsh7th/cmp-buffer]
|
||||||
|
[:hrsh7th/cmp-vsnip]
|
||||||
|
[:hrsh7th/cmp-nvim-lua]
|
||||||
|
[:hrsh7th/cmp-calc]
|
||||||
|
[:hrsh7th/cmp-path]
|
||||||
|
[:hrsh7th/cmp-nvim-lsp-signature-help]
|
||||||
|
[:davidsierradz/cmp-conventionalcommits]
|
||||||
|
[:hrsh7th/cmp-omni]]
|
||||||
|
:config setup})]
|
||||||
|
|
|
@ -1,11 +1,18 @@
|
||||||
(module dots.plugins.copilot
|
(import-macros {: al} :macros)
|
||||||
{autoload {copilot copilot}
|
(al copilot copilot)
|
||||||
require-macros [macros]})
|
(al utils dots.utils)
|
||||||
|
|
||||||
(copilot.setup
|
(fn setup []
|
||||||
|
(copilot.setup
|
||||||
{:panel {:enabled false}
|
{:panel {:enabled false}
|
||||||
:suggestion {:enabled true
|
:suggestion {:enabled true
|
||||||
:auto_trigger :true
|
:auto_trigger :true
|
||||||
:keymap {:accept "<tab>"
|
:keymap {:accept "<tab>"
|
||||||
:next "<C-l><C-n>"}}})
|
:next "<C-l><C-n>"}}}))
|
||||||
|
|
||||||
|
;:github/copilot.vim {:cmd ["Copilot"]}
|
||||||
|
;[(utils.plugin :zbirenbaum/copilot.lua
|
||||||
|
; {:cmd "Copilot"
|
||||||
|
; :event "InsertEnter"
|
||||||
|
; :config setup}}))
|
||||||
|
[]
|
||||||
|
|
|
@ -1,7 +1,18 @@
|
||||||
(module dots.plugins.crates
|
(import-macros {: al} :macros)
|
||||||
{autoload {a aniseed.core
|
|
||||||
crates crates}})
|
(al utils dots.utils)
|
||||||
|
(al crates crates)
|
||||||
|
|
||||||
|
(fn setup []
|
||||||
|
(crates.setup {:disable_invalid_feature_diagnostic true
|
||||||
|
:enable_update_available_warning false}))
|
||||||
|
|
||||||
|
|
||||||
(crates.setup {:disable_invalid_feature_diagnostic true
|
|
||||||
:enable_update_available_warning false})
|
[(utils.plugin :Saecki/crates.nvim
|
||||||
|
{:dependencies ["nvim-lua/plenary.nvim"]
|
||||||
|
:dir "/Users/leon/tmp/crates.nvim"
|
||||||
|
:event ["BufRead Cargo.toml"]
|
||||||
|
:lazy true
|
||||||
|
:config setup})]
|
||||||
|
|
||||||
|
|
|
@ -1,11 +1,18 @@
|
||||||
(module dots.plugins.diffview
|
(import-macros m :macros)
|
||||||
{autoload {diffview diffview
|
(m.al diffview diffview)
|
||||||
cb diffview.config}})
|
(m.al cb diffview.config)
|
||||||
|
(m.al utils dots.utils)
|
||||||
|
|
||||||
(diffview.setup
|
(fn setup []
|
||||||
|
(diffview.setup
|
||||||
{:diff_binaries false
|
{:diff_binaries false
|
||||||
:file_panel {:width 35
|
:file_panel {:width 35
|
||||||
:use_icons false}
|
:use_icons false}
|
||||||
:key_bindings {:view {:<leader>dn (cb.diffview_callback "select_next_entry")
|
:key_bindings {:view {:<leader>dn (cb.diffview_callback "select_next_entry")
|
||||||
:<leader>dp (cb.diffview_callback "select_prev_entry")
|
:<leader>dp (cb.diffview_callback "select_prev_entry")
|
||||||
:<leader>dd (cb.diffview_callback "toggle_files")}}})
|
:<leader>dd (cb.diffview_callback "toggle_files")}}}))
|
||||||
|
[(utils.plugin
|
||||||
|
:sindrets/diffview.nvim
|
||||||
|
{:cmd ["DiffviewOpen" "DiffviewToggleFiles"]
|
||||||
|
:config #setup})]
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,8 @@
|
||||||
(module dots.plugins.emmet {})
|
(import-macros m :macros)
|
||||||
|
|
||||||
(set vim.g.user_emmet_mode "n")
|
(set vim.g.user_emmet_mode "n")
|
||||||
(set vim.g.user_emmet_leader_key "<leader>e")
|
(set vim.g.user_emmet_leader_key "<leader>e")
|
||||||
(set vim.g.user_emmet_settings {:javascript.jsx {:extends "jsx"}
|
(set vim.g.user_emmet_settings {:javascript.jsx {:extends "jsx"}
|
||||||
:typescript.jsx {:extends "jsx"}})
|
:typescript.jsx {:extends "jsx"}})
|
||||||
|
|
||||||
|
[]
|
||||||
|
|
|
@ -1,15 +1,13 @@
|
||||||
(module dots.plugins.feline
|
(import-macros m :macros)
|
||||||
{autoload {a aniseed.core
|
(m.al a nfnl.core)
|
||||||
nvim aniseed.nvim
|
(m.al utils dots.utils)
|
||||||
utils dots.utils
|
(m.al str nfnl.string)
|
||||||
str aniseed.string
|
(m.al colors dots.colors)
|
||||||
colors dots.colors
|
(m.al feline feline)
|
||||||
view aniseed.view
|
(m.al feline-git feline.providers.git)
|
||||||
feline feline
|
(m.al feline-lsp feline.providers.lsp)
|
||||||
feline-git feline.providers.git
|
|
||||||
feline-lsp feline.providers.lsp}
|
|
||||||
require-macros [macros]})
|
|
||||||
|
|
||||||
|
(fn setup [])
|
||||||
(set vim.opt.termguicolors true)
|
(set vim.opt.termguicolors true)
|
||||||
|
|
||||||
(local modes
|
(local modes
|
||||||
|
@ -31,31 +29,31 @@
|
||||||
:V {:text "VISUAL LINE" :color colors.neutral_blue}
|
:V {:text "VISUAL LINE" :color colors.neutral_blue}
|
||||||
"" {:text "VISUAL BLOCK" :color colors.neutral_blue}})
|
"" {:text "VISUAL BLOCK" :color colors.neutral_blue}})
|
||||||
|
|
||||||
(def bar-bg colors.bg_main)
|
(local bar-bg colors.bg_main)
|
||||||
(def horiz-separator-color colors.light1)
|
(local horiz-separator-color colors.light1)
|
||||||
|
|
||||||
(defn or-empty [x] (or x ""))
|
(fn or-empty [x] (or x ""))
|
||||||
(defn spaces [x] (if x (.. " " x " ") ""))
|
(fn spaces [x] (if x (.. " " x " ") ""))
|
||||||
|
|
||||||
(defn get-current-filepath []
|
(fn get-current-filepath []
|
||||||
(let [file (utils.shorten-path (vim.fn.bufname) 30 30)]
|
(let [file (utils.shorten-path (vim.fn.bufname) 30 30)]
|
||||||
(if (a.empty? file) ""
|
(if (a.empty? file) ""
|
||||||
nvim.bo.readonly (.. "RO " file)
|
vim.bo.readonly (.. "RO " file)
|
||||||
(and nvim.bo.modifiable nvim.bo.modified) (.. file " ●")
|
(and vim.bo.modifiable vim.bo.modified) (.. file " ●")
|
||||||
(.. file " "))))
|
(.. file " "))))
|
||||||
|
|
||||||
(defn vim-mode-hl [use-as-fg?]
|
(fn vim-mode-hl [use-as-fg?]
|
||||||
(let [color (. modes (vim.fn.mode) :color)]
|
(let [color (. modes (vim.fn.mode) :color)]
|
||||||
(if use-as-fg? {:bg bar-bg :fg color} {:bg color :fg bar-bg})))
|
(if use-as-fg? {:bg bar-bg :fg color} {:bg color :fg bar-bg})))
|
||||||
|
|
||||||
(defn git-status-provider []
|
(fn git-status-provider []
|
||||||
(or-empty (utils.keep-if #(~= "master" $1)
|
(or-empty (utils.keep-if #(~= "master" $1)
|
||||||
(?. vim.b :gitsigns_status_dict :head))))
|
(?. vim.b :gitsigns_status_dict :head))))
|
||||||
|
|
||||||
(defn vim-mode []
|
(fn vim-mode []
|
||||||
(.. " " (or (. modes (vim.fn.mode) :text) vim.fn.mode) " "))
|
(.. " " (or (. modes (vim.fn.mode) :text) vim.fn.mode) " "))
|
||||||
|
|
||||||
(defn lsp-progress-provider []
|
(fn lsp-progress-provider []
|
||||||
(let [msgs (vim.lsp.util.get_progress_messages)
|
(let [msgs (vim.lsp.util.get_progress_messages)
|
||||||
s (icollect [_ msg (ipairs msgs)]
|
s (icollect [_ msg (ipairs msgs)]
|
||||||
(when msg.message
|
(when msg.message
|
||||||
|
@ -64,25 +62,25 @@
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
(defn lsp-diagnostic-component [kind color]
|
(fn lsp-diagnostic-component [kind color]
|
||||||
{:enabled #(~= 0 (length (vim.diagnostic.get 0 {:severity kind})))
|
{:enabled #(~= 0 (length (vim.diagnostic.get 0 {:severity kind})))
|
||||||
:provider #(spaces (length (vim.diagnostic.get 0 {:severity kind})))
|
:provider #(spaces (length (vim.diagnostic.get 0 {:severity kind})))
|
||||||
:left_sep ""
|
:left_sep ""
|
||||||
:right_sep ""
|
:right_sep ""
|
||||||
:hl {:fg bar-bg :bg color}})
|
:hl {:fg bar-bg :bg color}})
|
||||||
|
|
||||||
(defn coordinates []
|
(fn coordinates []
|
||||||
(let [[line col] (vim.api.nvim_win_get_cursor 0)]
|
(let [[line col] (vim.api.nvim_win_get_cursor 0)]
|
||||||
(.. " " line " ")))
|
(.. " " line " ")))
|
||||||
|
|
||||||
|
|
||||||
; Fills the bar with an horizontal line
|
; Fills the bar with an horizontal line
|
||||||
(defn inactive-separator-provider []
|
(fn inactive-separator-provider []
|
||||||
(if (not= (vim.fn.winnr) (vim.fn.winnr :j))
|
(if (not= (vim.fn.winnr) (vim.fn.winnr :j))
|
||||||
(string.rep "─" (vim.api.nvim_win_get_width 0))
|
(string.rep "─" (vim.api.nvim_win_get_width 0))
|
||||||
""))
|
""))
|
||||||
|
|
||||||
(def components {:active {} :inactive {}})
|
(local components {:active {} :inactive {}})
|
||||||
|
|
||||||
(tset components.active 1
|
(tset components.active 1
|
||||||
[{:provider vim-mode :hl #(vim-mode-hl false)}
|
[{:provider vim-mode :hl #(vim-mode-hl false)}
|
||||||
|
@ -114,3 +112,4 @@
|
||||||
(feline.setup {:theme {:fg colors.light1 :bg colors.bg_main}
|
(feline.setup {:theme {:fg colors.light1 :bg colors.bg_main}
|
||||||
:components components})
|
:components components})
|
||||||
|
|
||||||
|
[(utils.plugin :Famiu/feline.nvim {:config setup})]
|
||||||
|
|
|
@ -1,20 +1,27 @@
|
||||||
(module dots.plugins.gitsigns
|
(import-macros m :macros)
|
||||||
{autoload {utils dots.utils
|
(m.al utils dots.utils)
|
||||||
colors dots.colors
|
(m.al colors dots.colors)
|
||||||
gitsigns gitsigns}})
|
(m.al gitsigns gitsigns)
|
||||||
|
|
||||||
; https://github.com/lewis6991/gitsigns.nvim
|
(fn setup []
|
||||||
(gitsigns.setup
|
(gitsigns.setup
|
||||||
{:signs {:add {:text "▍"}
|
{:signs {:add {:text "▍"}
|
||||||
:change {:text "▍"}
|
:change {:text "▍"}
|
||||||
:delete {:text "▍"}
|
:delete {:text "▍"}
|
||||||
:topdelete {:text "▍"}
|
:topdelete {:text "▍"}
|
||||||
:changedelete {:text "▍"}}
|
:changedelete {:text "▍"}}
|
||||||
:keymaps {:noremap true
|
; :keymaps {:noremap true
|
||||||
:buffer true}
|
; :buffer true}
|
||||||
:current_line_blame false
|
:current_line_blame false
|
||||||
:update_debounce 100})
|
:update_debounce 100})
|
||||||
|
|
||||||
(let [scrollbar-gitsigns (require "scrollbar.handlers.gitsigns")]
|
(let [scrollbar-gitsigns (require "scrollbar.handlers.gitsigns")]
|
||||||
(scrollbar-gitsigns.setup))
|
(scrollbar-gitsigns.setup)))
|
||||||
|
|
||||||
|
[(utils.plugin
|
||||||
|
:lewis6991/gitsigns.nvim
|
||||||
|
{:dependencies [:vim-gruvbox8
|
||||||
|
:petertriho/nvim-scrollbar]
|
||||||
|
:config setup})]
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,8 @@
|
||||||
(module dots.plugins.glance
|
(import-macros m :macros)
|
||||||
{autoload {a aniseed.core
|
(m.al a aniseed.core)
|
||||||
glance glance}})
|
(m.al glance glance)
|
||||||
|
(m.al utils dots.utils)
|
||||||
|
|
||||||
(glance.setup)
|
[(utils.plugin
|
||||||
|
:dnlhc/glance.nvim
|
||||||
|
{:lazy true :config #(glance.setup)})]
|
||||||
|
|
|
@ -1,16 +1,17 @@
|
||||||
(module dots.plugins.gruvbox8
|
(import-macros {: al} :macros)
|
||||||
{autoload {utils dots.utils
|
(al utils dots.utils)
|
||||||
colors dots.colors}
|
(al colors dots.colors)
|
||||||
require-macros [macros]})
|
|
||||||
|
|
||||||
(set vim.g.gruvbox_italics 0)
|
|
||||||
(set vim.g.gruvbox_italicise_strings 0)
|
(fn setup []
|
||||||
(set vim.g.gruvbox_filetype_hi_groups 1)
|
(set vim.g.gruvbox_italics 0)
|
||||||
(set vim.g.gruvbox_plugin_hi_groups 1)
|
(set vim.g.gruvbox_italicise_strings 0)
|
||||||
|
(set vim.g.gruvbox_filetype_hi_groups 1)
|
||||||
|
(set vim.g.gruvbox_plugin_hi_groups 1)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
(defn- setup-colors []
|
(fn setup-colors []
|
||||||
(utils.highlight-add
|
(utils.highlight-add
|
||||||
["GruvboxBlueSign" "GruvboxAquaSign" "GruvboxRedSign" "GruvboxYellowSign" "GruvboxGreenSign" "GruvboxOrangeSign" "GruvboxPurpleSign"]
|
["GruvboxBlueSign" "GruvboxAquaSign" "GruvboxRedSign" "GruvboxYellowSign" "GruvboxGreenSign" "GruvboxOrangeSign" "GruvboxPurpleSign"]
|
||||||
{:bg "NONE"})
|
{:bg "NONE"})
|
||||||
|
@ -46,10 +47,10 @@
|
||||||
|
|
||||||
(utils.highlight :LspDiagnosticsUnderlineError {:gui "undercurl"})
|
(utils.highlight :LspDiagnosticsUnderlineError {:gui "undercurl"})
|
||||||
|
|
||||||
(vim.fn.sign_define :LspDiagnosticsSignError {:text "◆"})
|
;(vim.fn.sign_localine :LspDiagnosticsSignError {:text "◆"})
|
||||||
(vim.fn.sign_define :LspDiagnosticsSignWarning {:text "◆"})
|
;(vim.fn.sign_localine :LspDiagnosticsSignWarning {:text "◆"})
|
||||||
(vim.fn.sign_define :LspDiagnosticsSignHint {:text "◆"})
|
;(vim.fn.sign_localine :LspDiagnosticsSignHint {:text "◆"})
|
||||||
(vim.fn.sign_define :LspDiagnosticsSignInformation {:text "◆"})
|
;(vim.fn.sign_localine :LspDiagnosticsSignInformation {:text "◆"})
|
||||||
|
|
||||||
|
|
||||||
(utils.highlight :StatusLine {:bg colors.dark1 :fg colors.light0})
|
(utils.highlight :StatusLine {:bg colors.dark1 :fg colors.light0})
|
||||||
|
@ -57,8 +58,8 @@
|
||||||
(vim.cmd "highlight link Function GruvboxGreen")
|
(vim.cmd "highlight link Function GruvboxGreen")
|
||||||
(utils.highlight-add :Function {:gui "NONE"}))
|
(utils.highlight-add :Function {:gui "NONE"}))
|
||||||
|
|
||||||
(defn setup-telescope-theme []
|
(fn setup-telescope-theme []
|
||||||
(def prompt "blacker")
|
(local prompt "blacker")
|
||||||
(if
|
(if
|
||||||
(= prompt "bright")
|
(= prompt "bright")
|
||||||
(let [promptbg "#689d6a"]
|
(let [promptbg "#689d6a"]
|
||||||
|
@ -87,7 +88,7 @@
|
||||||
(utils.highlight-add :TelescopePromptPrefix {:bg promptbg :fg colors.neutral_aqua})
|
(utils.highlight-add :TelescopePromptPrefix {:bg promptbg :fg colors.neutral_aqua})
|
||||||
(utils.highlight-add :TelescopePromptTitle {:bg colors.neutral_blue :fg colors.dark1})))
|
(utils.highlight-add :TelescopePromptTitle {:bg colors.neutral_blue :fg colors.dark1})))
|
||||||
|
|
||||||
(def side "darker")
|
(local side "darker")
|
||||||
(if
|
(if
|
||||||
(= side "brighter")
|
(= side "brighter")
|
||||||
(let [previewbg "#1f2324"]
|
(let [previewbg "#1f2324"]
|
||||||
|
@ -99,14 +100,13 @@
|
||||||
(utils.highlight-add :TelescopePreviewNormal {:bg previewbg})
|
(utils.highlight-add :TelescopePreviewNormal {:bg previewbg})
|
||||||
(utils.highlight-add :TelescopePreviewBorder {:bg previewbg :fg previewbg})))
|
(utils.highlight-add :TelescopePreviewBorder {:bg previewbg :fg previewbg})))
|
||||||
|
|
||||||
(utils.highlight-add :TelescopeBorder {:bg colors.bg_second :fg colors.bg_second})
|
(utils.highlight-add :TelescopeBorder {:bg colors.bg_second :fg colors.bg_second}) (utils.highlight-add :TelescopeNormal {:bg colors.bg_second})
|
||||||
(utils.highlight-add :TelescopeNormal {:bg colors.bg_second})
|
|
||||||
(utils.highlight-add :TelescopePreviewTitle {:bg colors.neutral_green :fg colors.dark1})
|
(utils.highlight-add :TelescopePreviewTitle {:bg colors.neutral_green :fg colors.dark1})
|
||||||
(utils.highlight-add :TelescopeResultsTitle {:bg colors.neutral_aqua :fg colors.dark1})
|
(utils.highlight-add :TelescopeResultsTitle {:bg colors.neutral_aqua :fg colors.dark1})
|
||||||
|
|
||||||
(utils.highlight-add :TelescopeSelection {:bg colors.neutral_aqua :fg colors.dark1}))
|
(utils.highlight-add :TelescopeSelection {:bg colors.neutral_aqua :fg colors.dark1}))
|
||||||
|
|
||||||
(defn- setup-noice-theme []
|
(fn setup-noice-theme []
|
||||||
(utils.highlight-add :NoicePopupmenu {:bg colors.bg_second})
|
(utils.highlight-add :NoicePopupmenu {:bg colors.bg_second})
|
||||||
(utils.highlight-add :NoiceCmdline {:bg "#1f2324"})
|
(utils.highlight-add :NoiceCmdline {:bg "#1f2324"})
|
||||||
(utils.highlight-add :NoiceCmdlinePopup {:bg "#1f2324"})
|
(utils.highlight-add :NoiceCmdlinePopup {:bg "#1f2324"})
|
||||||
|
@ -114,14 +114,14 @@
|
||||||
(utils.highlight-add :NoiceCmdlinePopupBorder {:fg colors.bright_aqua})
|
(utils.highlight-add :NoiceCmdlinePopupBorder {:fg colors.bright_aqua})
|
||||||
(utils.highlight-add :NoiceCmdlineIcon {:fg colors.bright_aqua}))
|
(utils.highlight-add :NoiceCmdlineIcon {:fg colors.bright_aqua}))
|
||||||
|
|
||||||
(vim.api.nvim_create_autocmd "ColorScheme" {:pattern "*" :callback setup-colors})
|
(vim.api.nvim_create_autocmd "ColorScheme" {:pattern "*" :callback setup-colors})
|
||||||
(setup-colors)
|
(setup-colors)
|
||||||
(vim.api.nvim_create_autocmd "ColorScheme" {:pattern "*" :callback setup-telescope-theme})
|
(vim.api.nvim_create_autocmd "ColorScheme" {:pattern "*" :callback setup-telescope-theme})
|
||||||
(setup-telescope-theme)
|
(setup-telescope-theme)
|
||||||
(vim.api.nvim_create_autocmd "ColorScheme" {:pattern "*" :callback setup-noice-theme})
|
(vim.api.nvim_create_autocmd "ColorScheme" {:pattern "*" :callback setup-noice-theme})
|
||||||
(setup-noice-theme)
|
(setup-noice-theme)
|
||||||
|
|
||||||
(vim.api.nvim_create_autocmd
|
(vim.api.nvim_create_autocmd
|
||||||
"ColorScheme"
|
"ColorScheme"
|
||||||
{:pattern "*"
|
{:pattern "*"
|
||||||
:callback
|
:callback
|
||||||
|
@ -138,7 +138,8 @@
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
(if (= "epix" (vim.fn.hostname))
|
(if (= "epix" (vim.fn.hostname))
|
||||||
(vim.cmd "colorscheme gruvbox8_hard")
|
(vim.cmd "colorscheme gruvbox8_hard")
|
||||||
(vim.cmd "colorscheme gruvbox8"))
|
(vim.cmd "colorscheme gruvbox8")))
|
||||||
|
|
||||||
|
[(utils.plugin :lifepillar/vim-gruvbox8 {:lazy false :priority 1000 :config setup})]
|
||||||
|
|
|
@ -1,17 +1,16 @@
|
||||||
(module dots.plugins.lsp
|
(import-macros {: al} :macros)
|
||||||
{autoload {a aniseed.core
|
(al a aniseed.core)
|
||||||
str aniseed.string
|
(al str aniseed.string)
|
||||||
lsp lspconfig
|
(al lsp lspconfig)
|
||||||
lsp-configs lspconfig/configs
|
(al lsp-configs lspconfig/configs)
|
||||||
utils dots.utils
|
(al utils dots.utils)
|
||||||
ltex-ls dots.plugins.ltex-ls
|
(al ltex-ls dots.plugins.ltex-ls)
|
||||||
cmp_nvim_lsp cmp_nvim_lsp}
|
(al cmp_nvim_lsp cmp_nvim_lsp)
|
||||||
|
|
||||||
require-macros [macros]})
|
(fn setup []
|
||||||
|
; TODO check https://github.com/neovim/nvim-lspconfig/blob/master/ADVANCED_README.md for default config for all of them
|
||||||
|
|
||||||
; TODO check https://github.com/neovim/nvim-lspconfig/blob/master/ADVANCED_README.md for default config for all of them
|
(tset vim.lsp.handlers :textDocument/publishDiagnostics
|
||||||
|
|
||||||
(tset vim.lsp.handlers :textDocument/publishDiagnostics
|
|
||||||
(vim.lsp.with vim.lsp.diagnostic.on_publish_diagnostics
|
(vim.lsp.with vim.lsp.diagnostic.on_publish_diagnostics
|
||||||
{:update_in_insert false
|
{:update_in_insert false
|
||||||
:virtual_text {:prefix "◆"}
|
:virtual_text {:prefix "◆"}
|
||||||
|
@ -20,7 +19,7 @@
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
(fn on_attach [client bufnr]
|
(fn on_attach [client bufnr]
|
||||||
;(pkg lsp_signature.nvim [lsp_signature (require "lsp_signature")]
|
;(pkg lsp_signature.nvim [lsp_signature (require "lsp_signature")]
|
||||||
;(lsp_signature.on_attach {:bind true
|
;(lsp_signature.on_attach {:bind true
|
||||||
;:hint_scheme "String"
|
;:hint_scheme "String"
|
||||||
|
@ -44,71 +43,70 @@
|
||||||
false))))
|
false))))
|
||||||
|
|
||||||
|
|
||||||
(fn better_root_pattern [patterns except-patterns]
|
(fn better_root_pattern [patterns except-patterns]
|
||||||
"match path if one of the given patterns is matched, EXCEPT if one of the except-patterns is matched"
|
"match path if one of the given patterns is matched, EXCEPT if one of the except-patterns is matched"
|
||||||
(fn [path]
|
(fn [path]
|
||||||
(when (not ((lsp.util.root_pattern except-patterns) path))
|
(when (not ((lsp.util.root_pattern except-patterns) path))
|
||||||
((lsp.util.root_pattern patterns) path))))
|
((lsp.util.root_pattern patterns) path))))
|
||||||
|
|
||||||
; advertise snippet support
|
; advertise snippet support
|
||||||
(def default-capabilities
|
(def default-capabilities
|
||||||
(let [capabilities (vim.lsp.protocol.make_client_capabilities)]
|
(let [capabilities (vim.lsp.protocol.make_client_capabilities)]
|
||||||
(set capabilities.textDocument.completion.completionItem.snippetSupport true)
|
(set capabilities.textDocument.completion.completionItem.snippetSupport true)
|
||||||
(cmp_nvim_lsp.default_capabilities capabilities)))
|
(cmp_nvim_lsp.default_capabilities capabilities)))
|
||||||
|
|
||||||
(fn init-lsp [lsp-name ?opts]
|
(fn init-lsp [lsp-name ?opts]
|
||||||
"initialize a language server with defaults"
|
"initialize a language server with defaults"
|
||||||
(let [merged-opts (a.merge {:on_attach on_attach :capabilities default-capabilities} (or ?opts {}))]
|
(let [merged-opts (a.merge {:on_attach on_attach :capabilities default-capabilities} (or ?opts {}))]
|
||||||
((. lsp lsp-name :setup) merged-opts)))
|
((. lsp lsp-name :setup) merged-opts)))
|
||||||
|
|
||||||
(init-lsp :jsonls {:commands {:Format [ #(vim.lsp.buf.range_formatting [] [0 0] [(vim.fn.line "$") 0])]}})
|
(init-lsp :jsonls {:commands {:Format [ #(vim.lsp.buf.range_formatting [] [0 0] [(vim.fn.line "$") 0])]}})
|
||||||
(init-lsp :denols {:root_dir (better_root_pattern [".git"] ["package.json"])})
|
(init-lsp :denols {:root_dir (better_root_pattern [".git"] ["package.json"])})
|
||||||
(init-lsp :hls {:settings {:languageServerHaskell {:formattingProvider "stylish-haskell"}}})
|
(init-lsp :hls {:settings {:languageServerHaskell {:formattingProvider "stylish-haskell"}}})
|
||||||
(init-lsp :ocamllsp)
|
(init-lsp :ocamllsp)
|
||||||
(init-lsp :vimls)
|
(init-lsp :vimls)
|
||||||
(init-lsp :gopls)
|
(init-lsp :gopls)
|
||||||
(init-lsp :bashls)
|
(init-lsp :bashls)
|
||||||
(init-lsp :erlangls)
|
(init-lsp :erlangls)
|
||||||
(init-lsp :yamlls)
|
(init-lsp :yamlls)
|
||||||
(init-lsp :html)
|
(init-lsp :html)
|
||||||
(init-lsp :svelte)
|
(init-lsp :svelte)
|
||||||
(init-lsp :elmls)
|
(init-lsp :elmls)
|
||||||
(init-lsp :texlab)
|
(init-lsp :texlab)
|
||||||
(init-lsp :pyright)
|
(init-lsp :pyright)
|
||||||
;(init-lsp :ltex {:settings {:ltex {:dictionary {:de-DE [":~/.config/ltex-ls/dictionary.txt"]}
|
;(init-lsp :ltex {:settings {:ltex {:dictionary {:de-DE [":~/.config/ltex-ls/dictionary.txt"]}
|
||||||
;:disabledRules {:de-DE [":~/.config/ltex-ls/disabledRules.txt"]}
|
;:disabledRules {:de-DE [":~/.config/ltex-ls/disabledRules.txt"]}
|
||||||
;:hiddenFalsePositives {:de-DE [":~/.config/ltex-ls/hiddenFalsePositives.txt"]}
|
;:hiddenFalsePositives {:de-DE [":~/.config/ltex-ls/hiddenFalsePositives.txt"]}
|
||||||
;:additionalRules {:motherTongue "de-DE"}}}})
|
;:additionalRules {:motherTongue "de-DE"}}}})
|
||||||
(init-lsp :vls)
|
(init-lsp :vls)
|
||||||
;(init-lsp :clangd)
|
;(init-lsp :clangd)
|
||||||
;(init-lsp :ccls)
|
;(init-lsp :ccls)
|
||||||
|
|
||||||
(init-lsp :perlls)
|
(init-lsp :perlls)
|
||||||
|
|
||||||
|
(init-lsp :powershell_es {:bundle_path "/home/leon/powershell"})
|
||||||
(init-lsp :powershell_es {:bundle_path "/home/leon/powershell"})
|
;(ltex-ls.init)
|
||||||
;(ltex-ls.init)
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
(init-lsp :clangd)
|
(init-lsp :clangd)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
(init-lsp :cssls {:filestypes ["css" "scss" "less" "stylus"]
|
(init-lsp :cssls {:filestypes ["css" "scss" "less" "stylus"]
|
||||||
:root_dir (lsp.util.root_pattern ["package.json" ".git"])
|
:root_dir (lsp.util.root_pattern ["package.json" ".git"])
|
||||||
:settings {:css {:validate true}
|
:settings {:css {:validate true}
|
||||||
:less {:validate true}
|
:less {:validate true}
|
||||||
:scss {:validate true}}})
|
:scss {:validate true}}})
|
||||||
|
|
||||||
(lsp.tsserver.setup {:root_dir (lsp.util.root_pattern "package.json")
|
(lsp.tsserver.setup {:root_dir (lsp.util.root_pattern "package.json")
|
||||||
:on_attach (fn [client bufnr]
|
:on_attach (fn [client bufnr]
|
||||||
(set client.resolved_capabilities.document_formatting false)
|
(set client.resolved_capabilities.document_formatting false)
|
||||||
(on_attach client bufnr))})
|
(on_attach client bufnr))})
|
||||||
|
|
||||||
(let [rust-tools (require "rust-tools")
|
(let [rust-tools (require "rust-tools")
|
||||||
rust-tools-dap (require "rust-tools.dap")
|
rust-tools-dap (require "rust-tools.dap")
|
||||||
extension-path "/home/leon/.vscode/extensions/vadimcn.vscode-lldb-1.6.8/"
|
extension-path "/home/leon/.vscode/extensions/vadimcn.vscode-lldb-1.6.8/"
|
||||||
codelldb-path (.. extension-path "adapter/codelldb")
|
codelldb-path (.. extension-path "adapter/codelldb")
|
||||||
|
@ -130,20 +128,33 @@
|
||||||
|
|
||||||
;:cmd ["/home/leon/coding/prs/rust-analyzer/target/release/rust-analyzer"]}}))
|
;:cmd ["/home/leon/coding/prs/rust-analyzer/target/release/rust-analyzer"]}}))
|
||||||
|
|
||||||
|
(when (not lsp.fennel_language_server)
|
||||||
|
(tset lsp-configs :fennel_language_server
|
||||||
|
{:default_config {:cmd "/Users/leon/.cargo/bin/fennel-language-server"
|
||||||
|
:filetypes [:fennel]
|
||||||
|
:single_file_support true
|
||||||
|
:root_dir (lsp.util.root_pattern "fnl")
|
||||||
|
:settings {:fennel {:workspace {:library (vim.api.nvim_list_runtime_paths)}
|
||||||
|
:diagnostics {:globals [:vim]}}}}}))
|
||||||
|
|
||||||
; (let [sumneko_root_path (.. vim.env.HOME "/.local/share/lua-language-server")
|
(init-lsp :fennel_language_server)
|
||||||
; sumneko_binary (.. sumneko_root_path "/bin/Linux/lua-language-server"))
|
;
|
||||||
; (init-lsp
|
;
|
||||||
; :lua_ls
|
|
||||||
; {:cmd [sumneko_binary "-E" (.. sumneko_root_path "/main.lua")]
|
|
||||||
; :settings {:Lua {:runtime {:version "LuaJIT"
|
|
||||||
; :path (vim.split package.path ";")}
|
|
||||||
; :diagnostics {:globals ["vim"]}
|
|
||||||
; :workspace {:library {(vim.fn.expand "$VIMRUNTIME/lua") true
|
|
||||||
; (vim.fn.expand "$VIMRUNTIME/lua/vim/lsp") true}}
|
|
||||||
; :telemetry false}}}))
|
|
||||||
|
|
||||||
(comment
|
|
||||||
|
; (let [sumneko_root_path (.. vim.env.HOME "/.local/share/lua-language-server")
|
||||||
|
; sumneko_binary (.. sumneko_root_path "/bin/Linux/lua-language-server"))
|
||||||
|
; (init-lsp
|
||||||
|
; :lua_ls
|
||||||
|
; {:cmd [sumneko_binary "-E" (.. sumneko_root_path "/main.lua")]
|
||||||
|
; :settings {:Lua {:runtime {:version "LuaJIT"
|
||||||
|
; :path (vim.split package.path ";")}
|
||||||
|
; :diagnostics {:globals ["vim"]}
|
||||||
|
; :workspace {:library {(vim.fn.expand "$VIMRUNTIME/lua") true
|
||||||
|
; (vim.fn.expand "$VIMRUNTIME/lua/vim/lsp") true}}
|
||||||
|
; :telemetry false}}}))
|
||||||
|
|
||||||
|
(comment
|
||||||
(when (not lsp.prolog_lsp)
|
(when (not lsp.prolog_lsp)
|
||||||
(tset lsp-configs :prolog_lsp
|
(tset lsp-configs :prolog_lsp
|
||||||
{:default_config {:cmd ["swipl" "-g" "use_module(library(lsp_server))." "-g" "lsp_server:main" "-t" "halt" "--" "stdio"]
|
{:default_config {:cmd ["swipl" "-g" "use_module(library(lsp_server))." "-g" "lsp_server:main" "-t" "halt" "--" "stdio"]
|
||||||
|
@ -154,7 +165,7 @@
|
||||||
(lsp.prolog_lsp.setup {}))
|
(lsp.prolog_lsp.setup {}))
|
||||||
|
|
||||||
|
|
||||||
(comment
|
(comment
|
||||||
(let [ewwls-path "/home/leon/coding/projects/ls-eww/crates/ewwls/target/debug/ewwls"]
|
(let [ewwls-path "/home/leon/coding/projects/ls-eww/crates/ewwls/target/debug/ewwls"]
|
||||||
(when (vim.fn.filereadable ewwls-path)
|
(when (vim.fn.filereadable ewwls-path)
|
||||||
(when (not lsp.ewwls)
|
(when (not lsp.ewwls)
|
||||||
|
@ -167,10 +178,10 @@
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
; Idris2 ----------------------------------------------------------- <<<<<
|
; Idris2 ----------------------------------------------------------- <<<<<
|
||||||
|
|
||||||
(def autostart-semantic-highlighting true)
|
(def autostart-semantic-highlighting true)
|
||||||
(defn refresh-semantic-highlighting []
|
(fn refresh-semantic-highlighting []
|
||||||
(when autostart-semantic-highlighting
|
(when autostart-semantic-highlighting
|
||||||
(vim.lsp.buf_request 0
|
(vim.lsp.buf_request 0
|
||||||
:textDocument/semanticTokens/full
|
:textDocument/semanticTokens/full
|
||||||
|
@ -178,7 +189,7 @@
|
||||||
nil)
|
nil)
|
||||||
vim.NIL))
|
vim.NIL))
|
||||||
|
|
||||||
(when (not lsp.idris2_lsp)
|
(when (not lsp.idris2_lsp)
|
||||||
(set lsp-configs.idris2_lsp
|
(set lsp-configs.idris2_lsp
|
||||||
{:default_config
|
{:default_config
|
||||||
{:cmd [:idris2-lsp]
|
{:cmd [:idris2-lsp]
|
||||||
|
@ -199,7 +210,7 @@
|
||||||
(lsp.util.find_git_ancestor fname))
|
(lsp.util.find_git_ancestor fname))
|
||||||
(vim.loop.os_homedir)))
|
(vim.loop.os_homedir)))
|
||||||
:settings {}}}))
|
:settings {}}}))
|
||||||
(lsp.idris2_lsp.setup
|
(lsp.idris2_lsp.setup
|
||||||
{:on_attach refresh-semantic-highlighting
|
{:on_attach refresh-semantic-highlighting
|
||||||
:autostart true
|
:autostart true
|
||||||
:handlers {:workspace/semanticTokens/refresh refresh-semantic-highlighting
|
:handlers {:workspace/semanticTokens/refresh refresh-semantic-highlighting
|
||||||
|
@ -229,31 +240,30 @@
|
||||||
prev-start
|
prev-start
|
||||||
(+ prev-start (. data (+ i 2)))))))}})
|
(+ prev-start (. data (+ i 2)))))))}})
|
||||||
|
|
||||||
(vim.cmd "highlight link LspSemantic_type Include")
|
(vim.cmd "highlight link LspSemantic_type Include")
|
||||||
(vim.cmd "highlight link LspSemantic_function Identifier")
|
(vim.cmd "highlight link LspSemantic_function Identifier")
|
||||||
(vim.cmd "highlight link LspSemantic_struct Number")
|
(vim.cmd "highlight link LspSemantic_struct Number")
|
||||||
(vim.cmd "highlight LspSemantic_variable guifg=gray")
|
(vim.cmd "highlight LspSemantic_variable guifg=gray")
|
||||||
(vim.cmd "highlight link LspSemantic_keyword Structure")
|
(vim.cmd "highlight link LspSemantic_keyword Structure")
|
||||||
|
|
||||||
; --------------------------------- >>>>>
|
; --------------------------------- >>>>>
|
||||||
|
|
||||||
(set vim.opt.signcolumn "yes")
|
(set vim.opt.signcolumn "yes")
|
||||||
|
|
||||||
; Cleanup links in markdown documentation
|
; Cleanup links in markdown documentation
|
||||||
(defn- cleanup-markdown [contents]
|
(fn cleanup-markdown [contents]
|
||||||
(if (= contents.kind "markdown")
|
(if (= contents.kind "markdown")
|
||||||
(tset contents :value (string.gsub contents.value "%[([^%]]+)%]%(([^%)]+)%)" "[%1]")))
|
(tset contents :value (string.gsub contents.value "%[([^%]]+)%]%(([^%)]+)%)" "[%1]")))
|
||||||
contents)
|
contents)
|
||||||
|
|
||||||
(let [previous-handler (. vim.lsp.handlers :textDocument/hover)]
|
(let [previous-handler (. vim.lsp.handlers :textDocument/hover)]
|
||||||
(tset vim.lsp.handlers :textDocument/hover
|
(tset vim.lsp.handlers :textDocument/hover
|
||||||
(fn [a result b c]
|
(fn [a result b c]
|
||||||
(if (not (and result result.contents))
|
(if (not (and result result.contents))
|
||||||
(previous-handler a result b c)
|
(previous-handler a result b c)
|
||||||
(let [new-contents (cleanup-markdown result.contents)]
|
(let [new-contents (cleanup-markdown result.contents)]
|
||||||
(tset result :contents new-contents)
|
(tset result :contents new-contents)
|
||||||
(previous-handler a result b c))))))
|
(previous-handler a result b c)))))))
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
[(utils.plugin :neovim/nvim-lspconfig {:event "VeryLazy" :lazy true})]
|
||||||
; vim:foldmarker=<<<<<,>>>>>
|
; vim:foldmarker=<<<<<,>>>>>
|
||||||
|
|
|
@ -1,29 +1,29 @@
|
||||||
(module dots.plugins.ltex-ls
|
(import-macros m :macros)
|
||||||
{autoload {a aniseed.core
|
(m.al a aniseed.core)
|
||||||
str aniseed.string
|
(m.al str aniseed.string)
|
||||||
lsp lspconfig
|
(m.al lsp lspconfig)
|
||||||
configs lspconfig/configs
|
(m.al configs lspconfig/configs)
|
||||||
lsputil lspconfig/util
|
(m.al lsputil lspconfig/util)
|
||||||
utils dots.utils
|
(m.al utils dots.utils)
|
||||||
cmp_nvim_lsp cmp_nvim_lsp}})
|
(m.al cmp_nvim_lsp cmp_nvim_lsp)
|
||||||
|
|
||||||
|
|
||||||
(defn cmds [xs]
|
(fn cmds [xs]
|
||||||
(icollect [_ x (ipairs xs)]
|
(icollect [_ x (ipairs xs)]
|
||||||
(.. "\\" x "{}")))
|
(.. "\\" x "{}")))
|
||||||
|
|
||||||
(def latex-command-settings
|
(local latex-command-settings
|
||||||
{:dummy (cmds ["texttt" "scripture" "lstref" "figref" "tblref" "secref" "personaltextcite" "personalparencite" "textcite" "parencite" "parencite[]" "game" "acsu" "enquote" "name" "item" "reqref" "gamebtn" "fs" "cs" "appref" "sorty"])
|
{:dummy (cmds ["texttt" "scripture" "lstref" "figref" "tblref" "secref" "personaltextcite" "personalparencite" "textcite" "parencite" "parencite[]" "game" "acsu" "enquote" "name" "item" "reqref" "gamebtn" "fs" "cs" "appref" "sorty"])
|
||||||
:ignore (cmds ["urlfootnote" "caption" "todo"])})
|
:ignore (cmds ["urlfootnote" "caption" "todo"])})
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
(def Dictionary-file {:de-DE [(.. (vim.fn.getenv "HOME") "/.config/ltex-ls/dictionary.txt")]})
|
(local Dictionary-file {:de-DE [(.. (vim.fn.getenv "HOME") "/.config/ltex-ls/dictionary.txt")]})
|
||||||
(def Disabled-rules-file {:de-DE [(.. (vim.fn.getenv "HOME") "/.config/ltex-ls/disable.txt")]})
|
(local Disabled-rules-file {:de-DE [(.. (vim.fn.getenv "HOME") "/.config/ltex-ls/disable.txt")]})
|
||||||
(def False-positives-file {:de-DE [(.. (vim.fn.getenv "HOME") "/.config/ltex-ls/false.txt")]})
|
(local False-positives-file {:de-DE [(.. (vim.fn.getenv "HOME") "/.config/ltex-ls/false.txt")]})
|
||||||
|
|
||||||
|
|
||||||
(def latex-command-settings-formatted
|
(local latex-command-settings-formatted
|
||||||
(let [tbl {}]
|
(let [tbl {}]
|
||||||
(each [option commands (pairs latex-command-settings)]
|
(each [option commands (pairs latex-command-settings)]
|
||||||
(each [_ command (ipairs commands)]
|
(each [_ command (ipairs commands)]
|
||||||
|
@ -107,7 +107,7 @@
|
||||||
(add-to-file filetype lang file value)))
|
(add-to-file filetype lang file value)))
|
||||||
|
|
||||||
|
|
||||||
(defn init []
|
(fn init []
|
||||||
(set configs.ltex
|
(set configs.ltex
|
||||||
{:default_config {:cmd [:ltex-ls]
|
{:default_config {:cmd [:ltex-ls]
|
||||||
:filetypes [:tex :latex :bib]
|
:filetypes [:tex :latex :bib]
|
||||||
|
@ -153,4 +153,4 @@
|
||||||
(orig-execute-command command)))))
|
(orig-execute-command command)))))
|
||||||
|
|
||||||
|
|
||||||
|
[]
|
||||||
|
|
|
@ -1,6 +1,9 @@
|
||||||
(module dots.plugins.neogit
|
(import-macros m :macros)
|
||||||
{autoload {a aniseed.core
|
(m.al neogit neogit)
|
||||||
neogit neogit}})
|
(m.al utils dots.utils)
|
||||||
|
|
||||||
|
[(utils.plugin :TimUntersberger/neogit
|
||||||
|
{:config #(neogit.setup {:integrations {:diffview true}})
|
||||||
|
:cmd ["Neogit"]})]
|
||||||
|
|
||||||
|
|
||||||
(neogit.setup
|
|
||||||
{:integrations {:diffview true}})
|
|
||||||
|
|
|
@ -1,14 +1,12 @@
|
||||||
(module dots.plugins.noice
|
(import-macros m :macros)
|
||||||
{autoload {a aniseed.core
|
(m.al utils dots.utils)
|
||||||
lazy lazy
|
|
||||||
noice noice
|
|
||||||
colors dots.colors
|
|
||||||
utils dots.utils}
|
|
||||||
|
|
||||||
|
(fn setup []
|
||||||
require-macros [macros]})
|
(m.al a nfnl.core)
|
||||||
|
(m.al lazy lazy)
|
||||||
(noice.setup
|
(m.al noice noice)
|
||||||
|
(m.al colors dots.colors)
|
||||||
|
(noice.setup
|
||||||
{:presets {:inc_rename true
|
{:presets {:inc_rename true
|
||||||
:long_message_to_split true
|
:long_message_to_split true
|
||||||
:bottom_search true}
|
:bottom_search true}
|
||||||
|
@ -24,7 +22,7 @@
|
||||||
:position {:row 8 :col "50%"}
|
:position {:row 8 :col "50%"}
|
||||||
:size {:width 60 :height 10}}
|
:size {:width 60 :height 10}}
|
||||||
:mini {:max_height 5}}
|
:mini {:max_height 5}}
|
||||||
:cmdline {:view "cmdline_popup" ; change to cmdline
|
:cmdline {:view "cmdline" ; change to cmdline_popup
|
||||||
:format {:cmdline {:icon ":"}
|
:format {:cmdline {:icon ":"}
|
||||||
:lua false
|
:lua false
|
||||||
:help false}}
|
:help false}}
|
||||||
|
@ -37,4 +35,9 @@
|
||||||
{:view "mini"
|
{:view "mini"
|
||||||
:filter {:error true :max_height 5}}
|
:filter {:error true :max_height 5}}
|
||||||
{:view "cmdline_output"
|
{:view "cmdline_output"
|
||||||
:filter {:error true :min_height 6}}]})
|
:filter {:error true :min_height 6}}]}))
|
||||||
|
|
||||||
|
;[(utils.plugin :folke/noice.nvim
|
||||||
|
; {:config setup
|
||||||
|
; :dependencies [:MunifTanjim/nui.nvim]}}]}))
|
||||||
|
[]
|
||||||
|
|
|
@ -1,11 +1,13 @@
|
||||||
(module dots.plugins.nvim-colorizer
|
(import-macros m :macros)
|
||||||
{autoload {colorizer colorizer}})
|
(m.al colorizer colorizer)
|
||||||
|
(m.al utils dots.utils)
|
||||||
|
|
||||||
|
|
||||||
; this really shouldn't be necessary,.. but it is
|
(fn setup []
|
||||||
(set vim.o.termguicolors true)
|
; this really shouldn't be necessary,.. but it is
|
||||||
|
(set vim.o.termguicolors true)
|
||||||
|
|
||||||
(colorizer.setup
|
(colorizer.setup
|
||||||
["*"]
|
["*"]
|
||||||
{:RGB true
|
{:RGB true
|
||||||
:RRGGBB true
|
:RRGGBB true
|
||||||
|
@ -13,4 +15,9 @@
|
||||||
:RRGGBBAA true
|
:RRGGBBAA true
|
||||||
:rgb_fn true
|
:rgb_fn true
|
||||||
:hsl_fn true
|
:hsl_fn true
|
||||||
:mode "background"})
|
:mode "background"}))
|
||||||
|
|
||||||
|
[(utils.plugin :norcalli/nvim-colorizer.lua
|
||||||
|
{:event "VeryLazy"
|
||||||
|
:lazy true
|
||||||
|
:config setup})]
|
||||||
|
|
|
@ -1,5 +1,11 @@
|
||||||
(module dots.plugins.persistence
|
(import-macros m :macros)
|
||||||
{autoload {persistence persistence}})
|
(m.al persistence persistence)
|
||||||
|
(m.al utils dots.utils)
|
||||||
|
|
||||||
(persistence.setup
|
|
||||||
{:dir (vim.fn.expand (.. (vim.fn.stdpath "cache") "/sessions/"))})
|
(fn setup []
|
||||||
|
(persistence.setup
|
||||||
|
{:dir (vim.fn.expand (.. (vim.fn.stdpath "cache") "/sessions/"))}))
|
||||||
|
|
||||||
|
[(utils.plugin :folke/persistence.nvim
|
||||||
|
{:config setup})]
|
||||||
|
|
197
nvim/.config/nvim/fnl/dots/plugins/plugins.fnl
Normal file
197
nvim/.config/nvim/fnl/dots/plugins/plugins.fnl
Normal file
|
@ -0,0 +1,197 @@
|
||||||
|
(import-macros {: al} :macros)
|
||||||
|
(al a nfnl.core)
|
||||||
|
(al lazy lazy)
|
||||||
|
|
||||||
|
|
||||||
|
(macro setup [name opts]
|
||||||
|
`((. (require ,name) :setup) ,opts))
|
||||||
|
|
||||||
|
(macro plugin [name ?opts]
|
||||||
|
(if (= nil ?opts)
|
||||||
|
name
|
||||||
|
(do (tset ?opts 1 name) ?opts)))
|
||||||
|
|
||||||
|
[(plugin :Olical/aniseed)
|
||||||
|
(plugin :Olical/nfnl)
|
||||||
|
(plugin :nvim-lua/plenary.nvim)
|
||||||
|
(plugin :norcalli/nvim.lua)
|
||||||
|
(plugin :kyazdani42/nvim-web-devicons)
|
||||||
|
(plugin :folke/which-key.nvim)
|
||||||
|
(plugin :folke/todo-comments.nvim
|
||||||
|
{:lazy true
|
||||||
|
:event "VeryLazy"
|
||||||
|
:config #(require "dots.plugins.todo-comments")})
|
||||||
|
(plugin :ckipp01/nvim-jenkinsfile-linter
|
||||||
|
{:dependencies ["nvim-lua/plenary.nvim"]})
|
||||||
|
(plugin :psliwka/vim-smoothie)
|
||||||
|
(plugin :nathanaelkane/vim-indent-guides
|
||||||
|
{:cmd ["IndentGuidesToggle"]})
|
||||||
|
(plugin :luukvbaal/stabilize.nvim
|
||||||
|
{:config #(setup :stabilize)})
|
||||||
|
|
||||||
|
(plugin :stevearc/dressing.nvim
|
||||||
|
{:config #(setup :dressing)})
|
||||||
|
|
||||||
|
(plugin :tweekmonster/startuptime.vim
|
||||||
|
{:cmd ["StartupTime"]})
|
||||||
|
(plugin :folke/zen-mode.nvim
|
||||||
|
{:config #(require "dots.plugins.zen-mode")
|
||||||
|
:cmd ["ZenMode"]})
|
||||||
|
(plugin :folke/twilight.nvim
|
||||||
|
{:config #(require "dots.plugins.twilight")})
|
||||||
|
(plugin :moll/vim-bbye
|
||||||
|
{:lazy true :cmd [:Bdelete :Bwipeout]})
|
||||||
|
(plugin :petertriho/nvim-scrollbar
|
||||||
|
{:event "VeryLazy"
|
||||||
|
:lazy true
|
||||||
|
:config #(setup :scrollbar)})
|
||||||
|
|
||||||
|
(plugin "https://git.sr.ht/~whynothugo/lsp_lines.nvim"
|
||||||
|
{:config #(do (setup :lsp_lines)
|
||||||
|
(vim.diagnostic.config {:virtual_lines false}))})
|
||||||
|
|
||||||
|
; editing and movement <<<
|
||||||
|
(plugin :jiangmiao/auto-pairs)
|
||||||
|
(plugin :tpope/vim-repeat)
|
||||||
|
(plugin :preservim/nerdcommenter
|
||||||
|
{:event "VeryLazy"
|
||||||
|
:lazy true
|
||||||
|
:priority 1000})
|
||||||
|
(plugin :godlygeek/tabular
|
||||||
|
{:cmd ["Tabularize"]})
|
||||||
|
(plugin :tpope/vim-surround)
|
||||||
|
(plugin :hauleth/sad.vim)
|
||||||
|
(plugin :wellle/targets.vim) ; more text objects. IE: cin (change in next parens). generally better handling of surrounding objects.
|
||||||
|
(plugin :mg979/vim-visual-multi
|
||||||
|
{:lazy true :event "VeryLazy"})
|
||||||
|
(plugin :tommcdo/vim-exchange)
|
||||||
|
(plugin :phaazon/hop.nvim
|
||||||
|
{:lazy true
|
||||||
|
:event "VeryLazy"
|
||||||
|
:config #(setup "hop" {:keys "jfkdls;amvieurow"})})
|
||||||
|
; >>>
|
||||||
|
|
||||||
|
; debugger <<<
|
||||||
|
(plugin :rcarriga/nvim-dap-ui
|
||||||
|
{:lazy true
|
||||||
|
:config #(setup :dapui)
|
||||||
|
:dependencies [:mfussenegger/nvim-dap]})
|
||||||
|
(plugin :mfussenegger/nvim-dap
|
||||||
|
{:lazy true})
|
||||||
|
(plugin :nvim-telescope/telescope-dap.nvim
|
||||||
|
{:lazy true
|
||||||
|
:dependencies [:nvim-telescope/telescope.nvim
|
||||||
|
:mfussenegger/nvim-dap]})
|
||||||
|
|
||||||
|
; >>>
|
||||||
|
|
||||||
|
; git stuff <<<
|
||||||
|
(plugin :ldelossa/gh.nvim
|
||||||
|
{:lazy true
|
||||||
|
:config #(do ((. (require "litee.lib") :setup))
|
||||||
|
((. (require "litee.gh") :setup)))
|
||||||
|
:dependencies [:ldelossa/litee.nvim]})
|
||||||
|
(plugin :pwntester/octo.nvim
|
||||||
|
{:lazy true
|
||||||
|
:dependencies [:nvim-lua/plenary.nvim
|
||||||
|
:nvim-telescope/telescope.nvim
|
||||||
|
:kyazdani42/nvim-web-devicons]
|
||||||
|
:config #(setup :octo)})
|
||||||
|
|
||||||
|
(plugin :ruanyl/vim-gh-line)
|
||||||
|
(plugin :rhysd/conflict-marker.vim)
|
||||||
|
(plugin :tpope/vim-fugitive
|
||||||
|
{:lazy true :event "VeryLazy"})
|
||||||
|
; >>>
|
||||||
|
|
||||||
|
; lsp <<<
|
||||||
|
(plugin :ray-x/lsp_signature.nvim
|
||||||
|
{:event :BufEnter})
|
||||||
|
(plugin :weilbith/nvim-code-action-menu
|
||||||
|
{:cmd "CodeActionMenu"
|
||||||
|
:config #(set vim.g.code_action_menu_show_details false)})
|
||||||
|
|
||||||
|
(plugin :folke/trouble.nvim
|
||||||
|
{:lazy true
|
||||||
|
:config #(require "dots.plugins.trouble")
|
||||||
|
:cmd ["Trouble" "TroubleClose" "TroubleRefresh" "TroubleToggle"]})
|
||||||
|
|
||||||
|
; :elkowar/trouble.nvim {:branch "fix_error_on_nil_window"
|
||||||
|
; :config #(require "dots.plugins.trouble")
|
||||||
|
; :cmd ["Trouble" "TroubleClose" "TroubleRefresh" "TroubleToggle"]}
|
||||||
|
|
||||||
|
(plugin :simrat39/symbols-outline.nvim
|
||||||
|
{:lazy true
|
||||||
|
:cmd ["SymbolsOutline" "SymbolsOutlineClose" "SymbolsOutlineOpen"]
|
||||||
|
:config #(require "dots.plugins.symbols-outline")})
|
||||||
|
|
||||||
|
|
||||||
|
(plugin :smjonas/inc-rename.nvim
|
||||||
|
{:config #(setup :inc_rename {:input_buffer_type "dressing"})})
|
||||||
|
; >>>
|
||||||
|
|
||||||
|
; cmp <<<
|
||||||
|
; >>>
|
||||||
|
|
||||||
|
; code-related ----------------------------------------- <<<
|
||||||
|
|
||||||
|
(plugin :monkoose/nvlime
|
||||||
|
{:ft ["lisp"] :dependencies [:monkoose/parsley]})
|
||||||
|
|
||||||
|
(plugin :tpope/vim-sleuth)
|
||||||
|
(plugin :editorconfig/editorconfig-vim)
|
||||||
|
(plugin :pechorin/any-jump.vim)
|
||||||
|
(plugin :sbdchd/neoformat)
|
||||||
|
(plugin :elkowar/antifennel-nvim
|
||||||
|
{:config #(set vim.g.antifennel_executable "/home/leon/tmp/antifennel/antifennel")})
|
||||||
|
(plugin :Olical/conjure {:ft ["fennel"]})
|
||||||
|
(plugin :eraserhd/parinfer-rust {:build "cargo build --release"})
|
||||||
|
|
||||||
|
(plugin :lervag/vimtex
|
||||||
|
{:ft ["latex" "tex"]
|
||||||
|
:config #(require :dots.plugins.vimtex)})
|
||||||
|
(plugin :kmonad/kmonad-vim)
|
||||||
|
(plugin :elkowar/yuck.vim {:ft ["yuck"]})
|
||||||
|
(plugin :cespare/vim-toml {:ft ["toml"]})
|
||||||
|
(plugin :bduggan/vim-raku {:ft ["raku"]})
|
||||||
|
(plugin :LnL7/vim-nix {:ft ["nix"]})
|
||||||
|
(plugin :kevinoid/vim-jsonc {})
|
||||||
|
(plugin :pangloss/vim-javascript {:ft ["javascript"]}) ; syntax highlighting JS
|
||||||
|
(plugin :ianks/vim-tsx {:ft ["typescript-react"]})
|
||||||
|
(plugin :leafgarland/typescript-vim {:ft ["typescript" "typescript-react" "javascript"]})
|
||||||
|
(plugin :HerringtonDarkholme/yats.vim {}) ; typescript syntax highlighting
|
||||||
|
(plugin :mxw/vim-jsx {})
|
||||||
|
(plugin :mattn/emmet-vim
|
||||||
|
{:lazy true
|
||||||
|
:config #(require "dots.plugins.emmet")})
|
||||||
|
(plugin :purescript-contrib/purescript-vim {:ft ["purescript"]})
|
||||||
|
(plugin :derekelkins/agda-vim {:ft ["agda"]})
|
||||||
|
(plugin :neovimhaskell/haskell-vim { :ft ["haskell"]})
|
||||||
|
(plugin :monkoose/nvlime
|
||||||
|
{:ft ["lisp"]
|
||||||
|
:dependencies ["monkoose/parsley"]
|
||||||
|
:config #(set vim.g.vlime_overlay "slimv")})
|
||||||
|
|
||||||
|
|
||||||
|
(plugin :rust-lang/rust.vim
|
||||||
|
{:ft ["rust"]
|
||||||
|
:dependencies ["mattn/webapi-vim"]
|
||||||
|
:config #(do (set vim.g.rustfmt_fail_silently 1))})
|
||||||
|
|
||||||
|
(plugin :simrat39/rust-tools.nvim
|
||||||
|
{:ft ["rust" "toml"]
|
||||||
|
:dependencies ["nvim-lua/popup.nvim" "nvim-lua/plenary.nvim"]})
|
||||||
|
|
||||||
|
|
||||||
|
(plugin :qnighy/lalrpop.vim {})
|
||||||
|
(plugin :edwinb/idris2-vim {:ft ["idris2"]})
|
||||||
|
(plugin :vmchale/ats-vim {:ft ["ats" "dats" "sats"]})
|
||||||
|
(plugin :bakpakin/fennel.vim {:ft ["fennel"]})
|
||||||
|
(plugin :evanleck/vim-svelte {})]
|
||||||
|
|
||||||
|
|
||||||
|
; >>>
|
||||||
|
|
||||||
|
; vim:foldmarker=<<<,>>>
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,9 @@
|
||||||
(module dots.plugins.sneak
|
(import-macros m :macros)
|
||||||
{autoload {utils dots.utils}})
|
(m.al utils dots.utils)
|
||||||
|
|
||||||
|
|
||||||
(set vim.g.sneak#label 1)
|
(set vim.g.sneak#label 1)
|
||||||
(utils.keymap [:n :o] :<DEL> "<Plug>Sneak_s" {:noremap false})
|
(utils.keymap [:n :o] :<DEL> "<Plug>Sneak_s" {:noremap false})
|
||||||
(utils.keymap [:n :o] :<S-DEL> "<Plug>Sneak_S" {:noremap false})
|
(utils.keymap [:n :o] :<S-DEL> "<Plug>Sneak_S" {:noremap false})
|
||||||
|
|
||||||
|
[]
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
(module dots.plugins.symbols-outline
|
(import-macros m :macros)
|
||||||
{require {symbols-outline symbols-outline}})
|
(local symbols-outline (require :symbols-outline))
|
||||||
|
|
||||||
(symbols-outline.setup {:highlight_hovered_item true :show_guides true})
|
; (symbols-outline.setup {:highlight_hovered_item true :show_guides true})
|
||||||
|
[]
|
||||||
|
|
|
@ -1,16 +1,23 @@
|
||||||
(module dots.plugins.telescope
|
(import-macros {: al} :macros)
|
||||||
{autoload {utils dots.utils
|
(al utils dots.utils)
|
||||||
telescope telescope
|
(al telescope telescope)
|
||||||
actions telescope.actions
|
(al actions telescope.actions)
|
||||||
colors dots.colors}})
|
(al colors dots.colors)
|
||||||
|
|
||||||
(telescope.setup
|
(fn setup []
|
||||||
|
(telescope.setup
|
||||||
{:defaults {:mappings {:i {:<esc> actions.close}}
|
{:defaults {:mappings {:i {:<esc> actions.close}}
|
||||||
:file_ignore_patterns ["Cargo.lock" ".*.snap" "docs/theme/.*" "node%_modules/.*" "target/.*"]}
|
:file_ignore_patterns ["Cargo.lock" ".*.snap" "docs/theme/.*" "node%_modules/.*" "target/.*"]}
|
||||||
:extensions {:ui-select [((. (require "telescope.themes") :get_dropdown))]}})
|
:extensions {:ui-select [((. (require "telescope.themes") :get_dropdown))]}})
|
||||||
|
|
||||||
(telescope.load_extension "dap")
|
(telescope.load_extension "dap")
|
||||||
;(telescope.load_extension "ui-select")
|
;(telescope.load_extension "ui-select")
|
||||||
|
|
||||||
(utils.keymap :n :<C-p> ":Telescope find_files<CR>")
|
(utils.keymap :n :<C-p> ":Telescope find_files<CR>"))
|
||||||
|
|
||||||
|
[(utils.plugin :nvim-telescope/telescope.nvim
|
||||||
|
{:config setup
|
||||||
|
:cmd ["Telescope"]
|
||||||
|
:dependencies [:nvim-lua/popup.nvim
|
||||||
|
:nvim-lua/plenary.nvim]})]
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
(module dots.plugins.todo-comments
|
(import-macros m :macros)
|
||||||
{autoload {a aniseed.core
|
(m.al a aniseed.core)
|
||||||
todo-comments todo-comments}})
|
(m.al todo-comments todo-comments)
|
||||||
|
|
||||||
(todo-comments.setup
|
(todo-comments.setup
|
||||||
{:keywords {:TODO {:icon " "}
|
{:keywords {:TODO {:icon " "}
|
||||||
|
@ -9,3 +9,4 @@
|
||||||
:FIX {:icon " " :alt [:FIXME :BUG :FIXIT :ISSUE :PHIX]}
|
:FIX {:icon " " :alt [:FIXME :BUG :FIXIT :ISSUE :PHIX]}
|
||||||
:PERF {:icon " " :alt [:OPTIM :PERFORMANCE :OPTIMIZE]}
|
:PERF {:icon " " :alt [:OPTIM :PERFORMANCE :OPTIMIZE]}
|
||||||
:HACK {:icon " "}}})
|
:HACK {:icon " "}}})
|
||||||
|
[]
|
||||||
|
|
|
@ -1,10 +1,12 @@
|
||||||
(module dots.plugins.treesitter
|
(import-macros m :macros)
|
||||||
{autoload {utils dots.utils
|
(m.al utils dots.utils)
|
||||||
a aniseed.core}
|
(m.al a nfnl.core)
|
||||||
require {configs nvim-treesitter.configs}
|
|
||||||
require-macros [macros]})
|
|
||||||
|
|
||||||
(configs.setup
|
(fn setup [])
|
||||||
|
|
||||||
|
(fn setup1 []
|
||||||
|
(local configs (require :nvim-treesitter.configs))
|
||||||
|
(configs.setup
|
||||||
{:ensure_installed ["rust" "fennel" "commonlisp" "vim" "regex" "lua" "bash" "markdown" "markdown_inline"]
|
{:ensure_installed ["rust" "fennel" "commonlisp" "vim" "regex" "lua" "bash" "markdown" "markdown_inline"]
|
||||||
; :ensure_installed "maintained"
|
; :ensure_installed "maintained"
|
||||||
:highlight {:enable false
|
:highlight {:enable false
|
||||||
|
@ -41,11 +43,22 @@
|
||||||
:unfocus_language "F"
|
:unfocus_language "F"
|
||||||
:update "R"
|
:update "R"
|
||||||
:goto_node "<cr>"
|
:goto_node "<cr>"
|
||||||
:show_help "?"}}})
|
:show_help "?"}}}))
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
;:indent {:enable true}
|
|
||||||
;:disable ["lua"]
|
|
||||||
|
|
||||||
|
|
||||||
|
[(utils.plugin :nvim-treesitter/nvim-treesitter
|
||||||
|
{:config setup
|
||||||
|
:lazy true
|
||||||
|
:event ["VeryLazy"]
|
||||||
|
:build ":TSUpdate"})
|
||||||
|
(utils.plugin :RRethy/nvim-treesitter-textsubjects
|
||||||
|
{:dependencies [:nvim-treesitter/nvim-treesitter]
|
||||||
|
:lazy true
|
||||||
|
:event ["VeryLazy"]})
|
||||||
|
(utils.plugin :JoosepAlviste/nvim-ts-context-commentstring
|
||||||
|
{:event ["VeryLazy"]
|
||||||
|
:lazy true
|
||||||
|
:dependencies [:nvim-treesitter/nvim-treesitter]})
|
||||||
|
(utils.plugin :nvim-treesitter/playground
|
||||||
|
{:event ["VeryLazy"]
|
||||||
|
:lazy true
|
||||||
|
:dependencies [:nvim-treesitter/nvim-treesitter]})]
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
(module dots.plugins.trouble
|
(import-macros m :macros)
|
||||||
{autoload {utils dots.utils
|
(m.al utils dots.utils)
|
||||||
colors dots.colors}
|
(m.al colors dots.colors)
|
||||||
require {trouble trouble}})
|
(local trouble (require :trouble))
|
||||||
|
|
||||||
(trouble.setup
|
(trouble.setup
|
||||||
{:icons false
|
{:icons false
|
||||||
|
@ -25,3 +25,4 @@
|
||||||
(utils.highlight "TroubleSignWarning" {:bg "NONE" :fg colors.bright_yellow})
|
(utils.highlight "TroubleSignWarning" {:bg "NONE" :fg colors.bright_yellow})
|
||||||
(utils.highlight "TroubleSignInformation" {:bg "NONE" :fg colors.bright_aqua})
|
(utils.highlight "TroubleSignInformation" {:bg "NONE" :fg colors.bright_aqua})
|
||||||
(utils.highlight "TroubleSignHint" {:bg "NONE" :fg colors.bright_blue})
|
(utils.highlight "TroubleSignHint" {:bg "NONE" :fg colors.bright_blue})
|
||||||
|
[]
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
|
(import-macros m :macros)
|
||||||
(module dots.plugins.twilight
|
(m.al twilight twilight)
|
||||||
{autoload {twilight twilight}})
|
|
||||||
|
|
||||||
(twilight.setup)
|
(twilight.setup)
|
||||||
|
[]
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
(module dots.plugins.vimtex)
|
|
||||||
|
|
||||||
|
|
||||||
;(set vim.g.vimtex_quickfix_enabled 0)
|
;(set vim.g.vimtex_quickfix_enabled 0)
|
||||||
|
@ -40,3 +39,4 @@
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
[]
|
||||||
|
|
|
@ -1,7 +1,8 @@
|
||||||
(module dots.plugins
|
(import-macros m :macros)
|
||||||
{autoload {zen-mode zen-mode}})
|
(m.al zen-mode zen-mode)
|
||||||
|
|
||||||
|
|
||||||
(zen-mode.setup
|
(zen-mode.setup
|
||||||
{:window {:options {:wrap true}}})
|
{:window {:options {:wrap true}}})
|
||||||
|
|
||||||
|
[]
|
||||||
|
|
|
@ -1,27 +1,24 @@
|
||||||
(module dots.smart-compe-conjure
|
(al utils dots.utils)
|
||||||
{autoload {utils dots.utils
|
(al a aniseed.core)
|
||||||
a aniseed.core
|
(al str aniseed.string)
|
||||||
str aniseed.string
|
(al view aniseed.view)
|
||||||
view aniseed.view
|
(al popup popup)
|
||||||
popup popup
|
(al compe compe)
|
||||||
compe compe}
|
|
||||||
;help dots.help-thingy}
|
(defn setup []
|
||||||
require-macros [macros]})
|
(def fuck (require "compe_conjure"))
|
||||||
|
|
||||||
|
|
||||||
(def fuck (require "compe_conjure"))
|
(def my_source {})
|
||||||
|
(set my_source.new
|
||||||
|
|
||||||
(def my_source {})
|
|
||||||
(set my_source.new
|
|
||||||
(fn []
|
(fn []
|
||||||
(setmetatable {} {:__index my_source})))
|
(setmetatable {} {:__index my_source})))
|
||||||
|
|
||||||
(set my_source.determine fuck.determine)
|
(set my_source.determine fuck.determine)
|
||||||
(set my_source.get_metadata fuck.get_metadata)
|
(set my_source.get_metadata fuck.get_metadata)
|
||||||
(set my_source.complete fuck.complete)
|
(set my_source.complete fuck.complete)
|
||||||
(set my_source.abort fuck.abort)
|
(set my_source.abort fuck.abort)
|
||||||
(set my_source.documentation
|
(set my_source.documentation
|
||||||
(fn [self args]
|
(fn [self args]
|
||||||
(a.println (view.serialise args))
|
(a.println (view.serialise args))
|
||||||
(args.callback
|
(args.callback
|
||||||
|
@ -33,10 +30,10 @@
|
||||||
(table.insert lines "```")
|
(table.insert lines "```")
|
||||||
lines)))))
|
lines)))))
|
||||||
|
|
||||||
(compe.register_source :epic (my_source.new))
|
(compe.register_source :epic (my_source.new))
|
||||||
|
|
||||||
|
|
||||||
(compe.setup
|
(compe.setup
|
||||||
{:enabled true
|
{:enabled true
|
||||||
:autocomplete false
|
:autocomplete false
|
||||||
:debug false
|
:debug false
|
||||||
|
@ -55,7 +52,7 @@
|
||||||
:nvim_lsp true
|
:nvim_lsp true
|
||||||
:nvim_lua true
|
:nvim_lua true
|
||||||
:vsnip false
|
:vsnip false
|
||||||
:epic true}})
|
:epic true}}))
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
[]
|
||||||
|
|
|
@ -1,29 +1,31 @@
|
||||||
(module dots.utils
|
(import-macros {: al} :macros)
|
||||||
{autoload {a aniseed.core
|
(al a nfnl.core)
|
||||||
nvim aniseed.nvim
|
(al str nfnl.string)
|
||||||
str aniseed.string}
|
|
||||||
require-macros [macros]})
|
|
||||||
|
|
||||||
(defn plugin-installed? [name]
|
(fn plugin [name ?opts]
|
||||||
(~= nil (. packer_plugins name)))
|
(if (= nil ?opts)
|
||||||
|
name
|
||||||
|
(do
|
||||||
|
(tset ?opts 1 name)
|
||||||
|
?opts)))
|
||||||
|
|
||||||
(defn all [f xs]
|
(fn all [f xs]
|
||||||
(not (a.some #(not (f $1)))))
|
(not (a.some #(not (f $1)))))
|
||||||
|
|
||||||
(defn single-to-list [x]
|
(fn single-to-list [x]
|
||||||
"Returns the list given to it. If given a single value, wraps it in a list"
|
"Returns the list given to it. If given a single value, wraps it in a list"
|
||||||
(if (a.table? x) x [x]))
|
(if (a.table? x) x [x]))
|
||||||
|
|
||||||
(defn contains? [list elem]
|
(fn contains? [list elem]
|
||||||
(or (a.some #(= elem $1) list)) false)
|
(or (a.some #(= elem $1) list)) false)
|
||||||
|
|
||||||
(defn filter-table [f t]
|
(fn filter-table [f t]
|
||||||
(collect [k v (pairs t)]
|
(collect [k v (pairs t)]
|
||||||
(when (f k v)
|
(when (f k v)
|
||||||
(values k v))))
|
(values k v))))
|
||||||
|
|
||||||
|
|
||||||
(defn split-last [s sep]
|
(fn split-last [s sep]
|
||||||
"split a string at the last occurrence of a separator"
|
"split a string at the last occurrence of a separator"
|
||||||
(for [i (length s) 1 -1]
|
(for [i (length s) 1 -1]
|
||||||
(let [c (s:sub i i)]
|
(let [c (s:sub i i)]
|
||||||
|
@ -33,21 +35,21 @@
|
||||||
(lua "return { left, right }")))))
|
(lua "return { left, right }")))))
|
||||||
[s])
|
[s])
|
||||||
|
|
||||||
(defn find-where [pred xs]
|
(fn find-where [pred xs]
|
||||||
(each [_ x (ipairs xs)]
|
(each [_ x (ipairs xs)]
|
||||||
(when (pred x)
|
(when (pred x)
|
||||||
(lua "return x"))))
|
(lua "return x"))))
|
||||||
|
|
||||||
(defn find-map [f xs]
|
(fn find-map [f xs]
|
||||||
(each [_ x (ipairs xs)]
|
(each [_ x (ipairs xs)]
|
||||||
(let [res (f x)]
|
(let [res (f x)]
|
||||||
(when (~= nil res)
|
(when (~= nil res)
|
||||||
(lua "return res")))))
|
(lua "return res")))))
|
||||||
|
|
||||||
(defn keep-if [f x]
|
(fn keep-if [f x]
|
||||||
(when (f x) x))
|
(when (f x) x))
|
||||||
|
|
||||||
(defn map-values [f t]
|
(fn map-values [f t]
|
||||||
"Map over the values of a table, keeping the keys intact"
|
"Map over the values of a table, keeping the keys intact"
|
||||||
(let [tbl {}]
|
(let [tbl {}]
|
||||||
(each [k v (pairs t)] (tset tbl k (f v)))
|
(each [k v (pairs t)] (tset tbl k (f v)))
|
||||||
|
@ -55,27 +57,25 @@
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
(defn without-keys [keys t]
|
(fn without-keys [keys t]
|
||||||
(filter-table #(not (contains? keys $1)) t))
|
(filter-table #(not (contains? keys $1)) t))
|
||||||
|
|
||||||
(defn keymap [modes from to ?opts]
|
(fn keymap [modes from to ?opts]
|
||||||
"Set a mapping in the given modes, and some optional parameters, defaulting to {:noremap true :silent true}.
|
"Set a mapping in the given modes, and some optional parameters, defaulting to {:noremap true :silent true}.
|
||||||
If :buffer is set, uses buf_set_keymap rather than set_keymap"
|
If :buffer is set, uses buf_set_keymap rather than set_keymap"
|
||||||
(let [full-opts (->> (or ?opts {})
|
(let [full-opts (->> (or ?opts {})
|
||||||
(a.merge {:noremap true :silent true})
|
(a.merge {:noremap true :silent true})
|
||||||
(without-keys [:buffer]))]
|
(without-keys [:buffer]))]
|
||||||
(each [_ mode (ipairs (single-to-list modes))]
|
(each [_ mode (ipairs (single-to-list modes))]
|
||||||
(if (-?> ?opts (. :buffer))
|
(let [keymap-opts (if (-?> ?opts (. :buffer)) (a.assoc full-opts :buffer 0) full-opts)]
|
||||||
(nvim.buf_set_keymap 0 mode from to full-opts)
|
(vim.keymap.set mode from to keymap-opts)))))
|
||||||
(nvim.set_keymap mode from to full-opts)))))
|
|
||||||
|
|
||||||
(defn del-keymap [mode from ?buf-local]
|
(fn del-keymap [mode from ?buf-local]
|
||||||
"Remove a keymap. Arguments: mode, mapping, bool if mapping should be buffer-local."
|
"Remove a keymap. Arguments: mode, mapping, bool if mapping should be buffer-local."
|
||||||
(if ?buf-local
|
(vim.keymap.del mode from
|
||||||
(nvim.buf_del_keymap 0 mode from)
|
(if ?buf-local {:buffer 0} {})))
|
||||||
(nvim.del_keymap mode from)))
|
|
||||||
|
|
||||||
(defn safe-require [name]
|
(fn safe-require [name]
|
||||||
(xpcall
|
(xpcall
|
||||||
#(
|
#(
|
||||||
;do
|
;do
|
||||||
|
@ -86,24 +86,24 @@
|
||||||
(a.println (.. "Error sourcing " name ":\n" (fennel.traceback $1))))))
|
(a.println (.. "Error sourcing " name ":\n" (fennel.traceback $1))))))
|
||||||
|
|
||||||
|
|
||||||
(defn buffer-content [bufnr]
|
(fn buffer-content [bufnr]
|
||||||
"Returns a table of lines in the given buffer"
|
"Returns a table of lines in the given buffer"
|
||||||
(vim.api.nvim_buf_get_lines bufnr 0 -1 false))
|
(vim.api.nvim_buf_get_lines bufnr 0 -1 false))
|
||||||
|
|
||||||
(defn surround-if-present [a mid b]
|
(fn surround-if-present [a mid b]
|
||||||
(if mid
|
(if mid
|
||||||
(.. a mid b)
|
(.. a mid b)
|
||||||
""))
|
""))
|
||||||
|
|
||||||
(defn highlight [group-arg colset]
|
(fn highlight [group-arg colset]
|
||||||
(let [default { :fg "NONE" :bg "NONE" :gui "NONE"}
|
(let [default { :fg "NONE" :bg "NONE" :gui "NONE"}
|
||||||
opts (a.merge default colset)]
|
opts (a.merge default colset)]
|
||||||
(each [_ group (ipairs (single-to-list group-arg))]
|
(each [_ group (ipairs (single-to-list group-arg))]
|
||||||
(nvim.command (.. "hi! "group" guifg='"opts.fg"' guibg='"opts.bg"' gui='"opts.gui"'")))))
|
(vim.cmd (.. "hi! "group" guifg='"opts.fg"' guibg='"opts.bg"' gui='"opts.gui"'")))))
|
||||||
|
|
||||||
(defn highlight-add [group-arg colset]
|
(fn highlight-add [group-arg colset]
|
||||||
(each [_ group (ipairs (single-to-list group-arg))]
|
(each [_ group (ipairs (single-to-list group-arg))]
|
||||||
(nvim.command
|
(vim.cmd
|
||||||
(.. "hi! "
|
(.. "hi! "
|
||||||
group
|
group
|
||||||
(surround-if-present " guibg='"colset.bg"'")
|
(surround-if-present " guibg='"colset.bg"'")
|
||||||
|
@ -115,7 +115,7 @@
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
(defn shorten-path [path seg-length shorten-after]
|
(fn shorten-path [path seg-length shorten-after]
|
||||||
"shorten a filepath by truncating the segments to n characters, if the path exceeds a given length"
|
"shorten a filepath by truncating the segments to n characters, if the path exceeds a given length"
|
||||||
(let [segments (str.split path "/")]
|
(let [segments (str.split path "/")]
|
||||||
(if (or (> shorten-after (length path))
|
(if (or (> shorten-after (length path))
|
||||||
|
@ -126,7 +126,7 @@
|
||||||
shortened-segs (a.map #(string.sub $1 1 seg-length) init)]
|
shortened-segs (a.map #(string.sub $1 1 seg-length) init)]
|
||||||
(.. (str.join "/" shortened-segs) "/" filename)))))
|
(.. (str.join "/" shortened-segs) "/" filename)))))
|
||||||
|
|
||||||
(defn comp [f g]
|
(fn comp [f g]
|
||||||
(fn [...]
|
(fn [...]
|
||||||
(f (g ...))))
|
(f (g ...))))
|
||||||
|
|
||||||
|
@ -138,28 +138,56 @@
|
||||||
|
|
||||||
(var deferred-funs [])
|
(var deferred-funs [])
|
||||||
(var did-exec-deferred false)
|
(var did-exec-deferred false)
|
||||||
(defn clear-deferred [] (set deferred-funs []))
|
(fn clear-deferred [] (set deferred-funs []))
|
||||||
|
|
||||||
; defer a function. If deferred funcs have already been ran,
|
; defer a function. If deferred funcs have already been ran,
|
||||||
; assume we're reloading config because the user is configuring, and just execute immediately
|
; assume we're reloading config because the user is configuring, and just execute immediately
|
||||||
(defn defer-to-end [f]
|
(fn defer-to-end [f]
|
||||||
(if did-exec-deferred
|
(if did-exec-deferred
|
||||||
(f)
|
(f)
|
||||||
(table.insert deferred-funs f)))
|
(table.insert deferred-funs f)))
|
||||||
|
|
||||||
(defn run-deferred []
|
(fn run-deferred []
|
||||||
(set did-exec-deferred true)
|
(set did-exec-deferred true)
|
||||||
(each [_ f (ipairs deferred-funs)]
|
(each [_ f (ipairs deferred-funs)]
|
||||||
(f)))
|
(f)))
|
||||||
|
|
||||||
|
(fn get-selection []
|
||||||
(defn get-selection []
|
|
||||||
(let [[_ s-start-line s-start-col] (vim.fn.getpos "'<")
|
(let [[_ s-start-line s-start-col] (vim.fn.getpos "'<")
|
||||||
[_ s-end-line s-end-col] (vim.fn.getpos "'>")
|
[_ s-end-line s-end-col] (vim.fn.getpos "'>")
|
||||||
n-lines (+ 1 (math.abs (- s-end-line s-start-line)))
|
n-lines (+ 1 (math.abs (- s-end-line s-start-line)))
|
||||||
lines (vim.api.nvim_buf_get_lines 0 (- s-start-line 1) s-end-line false)]
|
lines (vim.api.nvim_buf_get_lines 0 (- s-start-line 1) s-end-line false)]
|
||||||
|
(if (= nil (. lines 1))
|
||||||
|
(values s-start-line s-end-line lines)
|
||||||
|
(do
|
||||||
(tset lines 1 (string.sub (. lines 1) s-start-col -1))
|
(tset lines 1 (string.sub (. lines 1) s-start-col -1))
|
||||||
(if (= 1 n-lines)
|
(if (= 1 n-lines)
|
||||||
(tset lines n-lines (string.sub (. lines n-lines) 1 (+ 1 (- s-end-col s-start-col))))
|
(tset lines n-lines (string.sub (. lines n-lines) 1 (+ 1 (- s-end-col s-start-col))))
|
||||||
(tset lines n-lines (string.sub (. lines n-lines) 1 s-end-col)))
|
(tset lines n-lines (string.sub (. lines n-lines) 1 s-end-col)))
|
||||||
(values s-start-line s-end-line lines)))
|
(values s-start-line s-end-line lines)))))
|
||||||
|
|
||||||
|
{: plugin
|
||||||
|
: plugin-installed?
|
||||||
|
: all
|
||||||
|
: single-to-list
|
||||||
|
: contains?
|
||||||
|
: filter-table
|
||||||
|
: split-last
|
||||||
|
: find-where
|
||||||
|
: find-map
|
||||||
|
: keep-if
|
||||||
|
: map-values
|
||||||
|
: without-keys
|
||||||
|
: keymap
|
||||||
|
: del-keymap
|
||||||
|
: safe-require
|
||||||
|
: buffer-content
|
||||||
|
: surround-if-present
|
||||||
|
: highlight
|
||||||
|
: highlight-add
|
||||||
|
: shorten-path
|
||||||
|
: comp
|
||||||
|
: clear-deferred
|
||||||
|
: defer-to-end
|
||||||
|
: run-deferred
|
||||||
|
: get-selection}
|
||||||
|
|
|
@ -1,20 +1,27 @@
|
||||||
(module init
|
(import-macros {: al : vim-let} :macros)
|
||||||
{autoload {utils dots.utils
|
(al a nfnl.core)
|
||||||
nvim aniseed.nvim
|
(al utils dots.utils)
|
||||||
a aniseed.core
|
(al str nfnl.string)
|
||||||
str aniseed.string
|
(al colors dots.colors)
|
||||||
colors dots.colors}
|
(local lazy (require :lazy))
|
||||||
require-macros [macros]})
|
|
||||||
(utils.clear-deferred)
|
(utils.clear-deferred)
|
||||||
|
|
||||||
|
;(macro make-errors-epic [f]
|
||||||
|
; `(xpcall #,f #(let [fennel# (require :aniseed.fennel)]
|
||||||
|
; (a.println (fennel#.traceback $1)))))
|
||||||
(macro make-errors-epic [f]
|
(macro make-errors-epic [f]
|
||||||
`(xpcall #,f #(let [fennel# (require :aniseed.fennel)]
|
f)
|
||||||
(a.println (fennel#.traceback $1)))))
|
|
||||||
|
|
||||||
(when (vim.fn.has "termguicolors")
|
(when (vim.fn.has "termguicolors")
|
||||||
(set vim.opt.termguicolors true))
|
(set vim.opt.termguicolors true))
|
||||||
|
|
||||||
(make-errors-epic (require "dots.plugins"))
|
;(make-errors-epic (require "dots.plugins"))
|
||||||
|
|
||||||
|
(vim-let mapleader "\\<Space>")
|
||||||
|
(vim-let maplocalleader ",")
|
||||||
|
|
||||||
|
(lazy.setup {:import "dots.plugins" :install {:colorscheme "gruvbox8"}})
|
||||||
|
|
||||||
; (require "impatient")
|
; (require "impatient")
|
||||||
|
|
||||||
|
@ -27,8 +34,6 @@
|
||||||
|
|
||||||
; Basic setup --------------------------------------- foldstart
|
; Basic setup --------------------------------------- foldstart
|
||||||
|
|
||||||
(vim-let mapleader "\\<Space>")
|
|
||||||
(vim-let maplocalleader ",")
|
|
||||||
|
|
||||||
(vim.cmd "filetype plugin indent on")
|
(vim.cmd "filetype plugin indent on")
|
||||||
(vim.cmd "syntax on")
|
(vim.cmd "syntax on")
|
||||||
|
@ -140,7 +145,7 @@
|
||||||
(vim.cmd
|
(vim.cmd
|
||||||
"command! -nargs=1 L :lua print(vim.inspect(<args>))")
|
"command! -nargs=1 L :lua print(vim.inspect(<args>))")
|
||||||
|
|
||||||
(vim.cmd "Copilot enable")
|
; (vim.cmd "Copilot enable")
|
||||||
|
|
||||||
(utils.run-deferred)
|
(utils.run-deferred)
|
||||||
|
|
||||||
|
|
|
@ -1,3 +1,5 @@
|
||||||
|
;; [nfnl-macro]
|
||||||
|
|
||||||
{:augroup
|
{:augroup
|
||||||
(fn [name ...]
|
(fn [name ...]
|
||||||
`(do
|
`(do
|
||||||
|
@ -6,6 +8,11 @@
|
||||||
,...
|
,...
|
||||||
(nvim.ex.augroup :END)))
|
(nvim.ex.augroup :END)))
|
||||||
|
|
||||||
|
:al
|
||||||
|
(fn [name thing]
|
||||||
|
`(local ,name ((. (require :nfnl.module) :autoload) ,(tostring thing))))
|
||||||
|
|
||||||
|
|
||||||
:defer
|
:defer
|
||||||
(fn [...]
|
(fn [...]
|
||||||
`(let [utils# (require :dots.utils)]
|
`(let [utils# (require :dots.utils)]
|
||||||
|
@ -14,8 +21,8 @@
|
||||||
|
|
||||||
:req
|
:req
|
||||||
(fn [name ...]
|
(fn [name ...]
|
||||||
(let [str (require :aniseed.string)
|
(let [str (require :nfnl.string)
|
||||||
a (require :aniseed.core)
|
a (require :nfnl.core)
|
||||||
segs (str.split (tostring name) "%.")
|
segs (str.split (tostring name) "%.")
|
||||||
mod (str.join "." (a.butlast segs))
|
mod (str.join "." (a.butlast segs))
|
||||||
func (a.last segs)]
|
func (a.last segs)]
|
||||||
|
@ -33,19 +40,6 @@
|
||||||
(fn [name]
|
(fn [name]
|
||||||
`(.. "lua require('" *module-name* "')['" ,(tostring name) "']()"))
|
`(.. "lua require('" *module-name* "')['" ,(tostring name) "']()"))
|
||||||
|
|
||||||
:dbg
|
|
||||||
(fn [x]
|
|
||||||
`(let [view# (require "aniseed.view")]
|
|
||||||
(print (.. `,(tostring x) " => " (view#.serialise ,x)))
|
|
||||||
,x))
|
|
||||||
|
|
||||||
:dbg-call
|
|
||||||
(fn [x ...]
|
|
||||||
`(do
|
|
||||||
(let [a# (require "aniseed.core")]
|
|
||||||
(a#.println ,...))
|
|
||||||
(,x ,...)))
|
|
||||||
|
|
||||||
:pkg
|
:pkg
|
||||||
(fn [name mappings ...]
|
(fn [name mappings ...]
|
||||||
`(if (~= nil (. packer_plugins `,(tostring name)))
|
`(if (~= nil (. packer_plugins `,(tostring name)))
|
||||||
|
@ -60,7 +54,7 @@
|
||||||
:each-pair
|
:each-pair
|
||||||
(fn [args ...]
|
(fn [args ...]
|
||||||
(let [[l# r# d#] args]
|
(let [[l# r# d#] args]
|
||||||
`(let [a# (require "aniseed.core")
|
`(let [a# (require "nfnl.core")
|
||||||
data# ,d#]
|
data# ,d#]
|
||||||
(for [i# 1 (a#.count data#) 2]
|
(for [i# 1 (a#.count data#) 2]
|
||||||
(let [,l# (. data# i#)
|
(let [,l# (. data# i#)
|
||||||
|
@ -69,7 +63,7 @@
|
||||||
|
|
||||||
:packer-use
|
:packer-use
|
||||||
(fn [...]
|
(fn [...]
|
||||||
(let [a (require "aniseed.core")
|
(let [a (require "nfnl.core")
|
||||||
args [...]
|
args [...]
|
||||||
use-statements []]
|
use-statements []]
|
||||||
(for [i 1 (a.count args) 2]
|
(for [i 1 (a.count args) 2]
|
||||||
|
|
|
@ -1,7 +1,3 @@
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
-- not even used, but epic. stores the path to the root config directory.
|
-- not even used, but epic. stores the path to the root config directory.
|
||||||
local vim_config_root = vim.fn.expand("<sfile>:p:h")
|
local vim_config_root = vim.fn.expand("<sfile>:p:h")
|
||||||
|
|
||||||
|
@ -33,15 +29,22 @@ end
|
||||||
|
|
||||||
-- Bootstrap essential plugins required for installing and loading the rest.
|
-- Bootstrap essential plugins required for installing and loading the rest.
|
||||||
--ensure("wbthomason", "packer.nvim", "master")
|
--ensure("wbthomason", "packer.nvim", "master")
|
||||||
ensure("Olical", "aniseed", "master")
|
--ensure("Olical", "aniseed", "master")
|
||||||
|
ensure("Olical", "nfnl", "main")
|
||||||
|
|
||||||
|
-- require('nfnl')['compile-all-files']()
|
||||||
|
|
||||||
|
require("lua.init")
|
||||||
|
|
||||||
|
|
||||||
-- ensure("lewis6991", "impatient.nvim", "main")
|
-- ensure("lewis6991", "impatient.nvim", "main")
|
||||||
|
|
||||||
-- require("impatient")
|
-- require("impatient")
|
||||||
|
|
||||||
|
|
||||||
vim.g["aniseed#env"] = {
|
-- vim.g["aniseed#env"] = {
|
||||||
compile = true
|
-- compile = true
|
||||||
}
|
-- }
|
||||||
--require("aniseed.env").init({compile = true})
|
--require("aniseed.env").init({compile = true})
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"agda-vim": { "branch": "master", "commit": "4a0f475aaef756702222bdd5b01e25f814f5691f" },
|
"agda-vim": { "branch": "master", "commit": "4a0f475aaef756702222bdd5b01e25f814f5691f" },
|
||||||
"aniseed": { "branch": "develop", "commit": "1ed7d5cad835a4aad86ddc5432b71254d4758ada" },
|
"aniseed": { "branch": "master", "commit": "7bc09736f3651c10d29b82d1a465b7f540614be1" },
|
||||||
"antifennel-nvim": { "branch": "master", "commit": "79261d02213a5093135e5d02431682f04459f0f7" },
|
"antifennel-nvim": { "branch": "master", "commit": "79261d02213a5093135e5d02431682f04459f0f7" },
|
||||||
"any-jump.vim": { "branch": "master", "commit": "770ef708ae3f13322430fcc663d7dfb864756b9b" },
|
"any-jump.vim": { "branch": "master", "commit": "770ef708ae3f13322430fcc663d7dfb864756b9b" },
|
||||||
"ats-vim": { "branch": "master", "commit": "8e3e722b6d09ed81313573b4e7b108b265628ff1" },
|
"ats-vim": { "branch": "master", "commit": "8e3e722b6d09ed81313573b4e7b108b265628ff1" },
|
||||||
|
@ -16,17 +16,14 @@
|
||||||
"cmp-vsnip": { "branch": "main", "commit": "989a8a73c44e926199bfd05fa7a516d51f2d2752" },
|
"cmp-vsnip": { "branch": "main", "commit": "989a8a73c44e926199bfd05fa7a516d51f2d2752" },
|
||||||
"conflict-marker.vim": { "branch": "master", "commit": "11a4d42244755505b66b15cd4496a150432eb5e3" },
|
"conflict-marker.vim": { "branch": "master", "commit": "11a4d42244755505b66b15cd4496a150432eb5e3" },
|
||||||
"conjure": { "branch": "master", "commit": "58c46d1f4999679659a5918284b574c266a7ac83" },
|
"conjure": { "branch": "master", "commit": "58c46d1f4999679659a5918284b574c266a7ac83" },
|
||||||
"copilot.lua": { "branch": "master", "commit": "1a8032ae496916ccc7a7a52ee79194fbef29f462" },
|
|
||||||
"crates.nvim": { "branch": "main", "commit": "86b31c92bbcb56d01dff85b07aa008591c848416" },
|
|
||||||
"diffview.nvim": { "branch": "main", "commit": "0437ef8bfdd67156d87140d692840a3c2824fa20" },
|
"diffview.nvim": { "branch": "main", "commit": "0437ef8bfdd67156d87140d692840a3c2824fa20" },
|
||||||
"dressing.nvim": { "branch": "master", "commit": "8f4d62b7817455896a3c73cab642002072c114bc" },
|
"dressing.nvim": { "branch": "master", "commit": "8f4d62b7817455896a3c73cab642002072c114bc" },
|
||||||
"editorconfig-vim": { "branch": "master", "commit": "0d54ea863089fb13be423b4aed6cca35f3a5d778" },
|
"editorconfig-vim": { "branch": "master", "commit": "0d54ea863089fb13be423b4aed6cca35f3a5d778" },
|
||||||
"emmet-vim": { "branch": "master", "commit": "def5d57a1ae5afb1b96ebe83c4652d1c03640f4d" },
|
"emmet-vim": { "branch": "master", "commit": "def5d57a1ae5afb1b96ebe83c4652d1c03640f4d" },
|
||||||
"feline.nvim": { "branch": "master", "commit": "3587f57480b88e8009df7b36dc84e9c7ff8f2c49" },
|
|
||||||
"fennel.vim": { "branch": "master", "commit": "30b9beabad2c4f09b9b284caf5cd5666b6b4dc89" },
|
"fennel.vim": { "branch": "master", "commit": "30b9beabad2c4f09b9b284caf5cd5666b6b4dc89" },
|
||||||
"friendly-snippets": { "branch": "main", "commit": "43727c2ff84240e55d4069ec3e6158d74cb534b6" },
|
"friendly-snippets": { "branch": "main", "commit": "43727c2ff84240e55d4069ec3e6158d74cb534b6" },
|
||||||
"gh.nvim": { "branch": "main", "commit": "2b5551656c1b896bf4ae06546eaaab00311f9a18" },
|
"gh.nvim": { "branch": "main", "commit": "2b5551656c1b896bf4ae06546eaaab00311f9a18" },
|
||||||
"gitsigns.nvim": { "branch": "main", "commit": "292938621016a9eb8f266398383fca5cf531c985" },
|
"gitsigns.nvim": { "branch": "main", "commit": "ff01d34daaed72f271a8ffa088a7e839a60c640f" },
|
||||||
"glance.nvim": { "branch": "master", "commit": "8ed5cf3b3b1231ea696d88c9efd977027429d869" },
|
"glance.nvim": { "branch": "master", "commit": "8ed5cf3b3b1231ea696d88c9efd977027429d869" },
|
||||||
"haskell-vim": { "branch": "master", "commit": "f35d02204b4813d1dbe8b0e98cc39701a4b8e15e" },
|
"haskell-vim": { "branch": "master", "commit": "f35d02204b4813d1dbe8b0e98cc39701a4b8e15e" },
|
||||||
"hop.nvim": { "branch": "master", "commit": "1a1eceafe54b5081eae4cb91c723abd1d450f34b" },
|
"hop.nvim": { "branch": "master", "commit": "1a1eceafe54b5081eae4cb91c723abd1d450f34b" },
|
||||||
|
@ -41,9 +38,10 @@
|
||||||
"neoformat": { "branch": "master", "commit": "aedb6f9d3f53d5da229095f7d761d749f8c5c7e0" },
|
"neoformat": { "branch": "master", "commit": "aedb6f9d3f53d5da229095f7d761d749f8c5c7e0" },
|
||||||
"neogit": { "branch": "master", "commit": "ed99c59d7fda3ba5e2ce9a3adc0a8eb5ebfa6c8f" },
|
"neogit": { "branch": "master", "commit": "ed99c59d7fda3ba5e2ce9a3adc0a8eb5ebfa6c8f" },
|
||||||
"nerdcommenter": { "branch": "master", "commit": "d2e21d417f6c788b11ae3b90d7ac478930dead36" },
|
"nerdcommenter": { "branch": "master", "commit": "d2e21d417f6c788b11ae3b90d7ac478930dead36" },
|
||||||
"noice.nvim": { "branch": "main", "commit": "f77689c9b2436bcd70741a20311496233acb4fb9" },
|
"nfnl": { "branch": "main", "commit": "979dbfc48bcb601a9107764a99f9459cb5bd4051" },
|
||||||
|
"noice.nvim": { "branch": "main", "commit": "7cf858c30841c9c41601ce58e5bc2023228037ef" },
|
||||||
"nui.nvim": { "branch": "main", "commit": "c8de23342caf8d50b15d6b28368d36a56a69d76f" },
|
"nui.nvim": { "branch": "main", "commit": "c8de23342caf8d50b15d6b28368d36a56a69d76f" },
|
||||||
"nvim-bufferline.lua": { "branch": "main", "commit": "874f869a24e568980294b3200fc9dd842db65a36" },
|
"nvim-bufferline.lua": { "branch": "main", "commit": "357cc8f8eeb64702e6fcf2995e3b9becee99a5d3" },
|
||||||
"nvim-cmp": { "branch": "main", "commit": "5dce1b778b85c717f6614e3f4da45e9f19f54435" },
|
"nvim-cmp": { "branch": "main", "commit": "5dce1b778b85c717f6614e3f4da45e9f19f54435" },
|
||||||
"nvim-code-action-menu": { "branch": "main", "commit": "e4399dbaf6eabff998d3d5f1cbcd8d9933710027" },
|
"nvim-code-action-menu": { "branch": "main", "commit": "e4399dbaf6eabff998d3d5f1cbcd8d9933710027" },
|
||||||
"nvim-colorizer.lua": { "branch": "master", "commit": "36c610a9717cc9ec426a07c8e6bf3b3abcb139d6" },
|
"nvim-colorizer.lua": { "branch": "master", "commit": "36c610a9717cc9ec426a07c8e6bf3b3abcb139d6" },
|
||||||
|
@ -52,7 +50,7 @@
|
||||||
"nvim-jenkinsfile-linter": { "branch": "main", "commit": "6e740a9e42251452cbc79808ea894f5233a93e92" },
|
"nvim-jenkinsfile-linter": { "branch": "main", "commit": "6e740a9e42251452cbc79808ea894f5233a93e92" },
|
||||||
"nvim-lspconfig": { "branch": "master", "commit": "2b361e043810d5587d9af0787f8ce40da92ec5e9" },
|
"nvim-lspconfig": { "branch": "master", "commit": "2b361e043810d5587d9af0787f8ce40da92ec5e9" },
|
||||||
"nvim-scrollbar": { "branch": "main", "commit": "35f99d559041c7c0eff3a41f9093581ceea534e8" },
|
"nvim-scrollbar": { "branch": "main", "commit": "35f99d559041c7c0eff3a41f9093581ceea534e8" },
|
||||||
"nvim-treesitter": { "branch": "master", "commit": "db7adb21e6f17528b0f639f36641ce59d65eb68f" },
|
"nvim-treesitter": { "branch": "master", "commit": "10bfa4826f2235c600c073a82e0d78718aa7240e" },
|
||||||
"nvim-treesitter-textsubjects": { "branch": "master", "commit": "48b3bf54e32f23e2299c59ff76fa3b0599565b39" },
|
"nvim-treesitter-textsubjects": { "branch": "master", "commit": "48b3bf54e32f23e2299c59ff76fa3b0599565b39" },
|
||||||
"nvim-ts-context-commentstring": { "branch": "main", "commit": "7241635869b7a8115893ffa67bab3907756caf4f" },
|
"nvim-ts-context-commentstring": { "branch": "main", "commit": "7241635869b7a8115893ffa67bab3907756caf4f" },
|
||||||
"nvim-web-devicons": { "branch": "master", "commit": "45d0237c427baba8cd05e0ab26d30e2ee58c2c82" },
|
"nvim-web-devicons": { "branch": "master", "commit": "45d0237c427baba8cd05e0ab26d30e2ee58c2c82" },
|
||||||
|
|
Loading…
Reference in a new issue