diff --git a/fnl/init.fnl b/fnl/init.fnl index 5b7ff26..8134385 100644 --- a/fnl/init.fnl +++ b/fnl/init.fnl @@ -9,10 +9,11 @@ lazypath])) (vim.opt.rtp:prepend lazypath) (lazy.setup ["https://github.com/rktjmp/hotpot.nvim" - "https://github.com/preservim/vim-markdown" + "https://github.com/julienvincent/nvim-paredit" + "https://github.com/preservim/vim-markdown" + "https://github.com/nvim-lua/plenary.nvim" {:url "https://github.com/nvim-telescope/telescope.nvim" - :tag :0.1.2 - :dependencies [:nvim-lua/plenary.nvim]} + :tag :0.1.2} {:url "https://github.com/nvim-telescope/telescope-fzf-native.nvim" :build (.. "cmake -S. -Bbuild -DCMAKE_BUILD_TYPE=Release" " && cmake --build build --config Release" @@ -35,7 +36,14 @@ {:url "https://github.com/L3MON4D3/LuaSnip" :dependencies ["https://github.com/saadparwaiz1/cmp_luasnip" "https://github.com/rafamadriz/friendly-snippets"]} - "https://github.com/sainnhe/everforest"])) + "https://github.com/sainnhe/everforest" + "https://github.com/serenevoid/kiwi.nvim" + "https://github.com/tamton-aquib/duck.nvim" + ])) + +(let [personalize (require :personalize)] + (personalize.options) + (personalize.keymap)) (let [telescope (require :telescope)] (pcall (telescope.load_extension :fzf))) @@ -43,7 +51,4 @@ (require :setup-treesitter) (require :setup-mason) (require :setup-cmp) - -(let [personalize (require :personalize)] - (personalize.keymap) - (personalize.options)) +(require :setup-kiwi) diff --git a/fnl/personalize.fnl b/fnl/personalize.fnl index 876cc89..76a24ea 100644 --- a/fnl/personalize.fnl +++ b/fnl/personalize.fnl @@ -13,11 +13,12 @@ (let [nmap #(vim.keymap.set [:n] $1 $2 {:desc $3})] (nmap : ":bnext" "Next Buffer") (nmap : ":bprevious" "Previous Buffer") - (nmap : ":write|bdelete" "Save and delete buffer") + (nmap :x ":write|bdelete" "Save and delete buffer") (nmap : ":Telescope find_files" "Telescope find_files") - (nmap : ":Telescope live_grep" "Telescope live_grep") - (nmap : ":Telescope buffers" "Telescope buffers") - (nmap : ":Telescope treesitter" "Telescope treesitter"))) + (let [duck (require :duck)] + (nmap :dd #(duck.hatch) "hatch a duck") + (nmap :dk #(duck.cook) "cook a duck")) + )) :treesitter-languages [:c :lua :vim diff --git a/fnl/setup-kiwi.fnl b/fnl/setup-kiwi.fnl new file mode 100644 index 0000000..cba76ba --- /dev/null +++ b/fnl/setup-kiwi.fnl @@ -0,0 +1,5 @@ +(let [kiwi (require :kiwi) + nmap #(vim.keymap.set [:n] $1 $2 {:desc (.. "[kiwi]" $3)})] + (nmap :ww kiwi.open_wiki_index "Open wiki") + (nmap :wd kiwi.open_diary_index "Open diary") + (nmap :wn kiwi.open_diary_new "New diary entry")) diff --git a/ftdetect/markdown.lua b/ftdetect/markdown.lua new file mode 100644 index 0000000..2f50fec --- /dev/null +++ b/ftdetect/markdown.lua @@ -0,0 +1,11 @@ +vim.api.nvim_create_autocmd({ "BufNewFile", "BufFilePost", "BufRead" }, { + pattern = "*.md", + callback = function() + vim.bo.filetype = "markdown" + vim.bo.syntax = "markdown" + vim.o.colorcolumn = "80" + vim.o.textwidth = 80 + -- autoformating is nice but it fucks with lists and other things kinda + -- vim.o.formatoptions = vim.o.formatoptions .. "a" + end, +}) diff --git a/ftdetect/markdown.vim b/ftdetect/markdown.vim deleted file mode 100644 index 458e5e4..0000000 --- a/ftdetect/markdown.vim +++ /dev/null @@ -1 +0,0 @@ -au BufRead,BufNewFile *.md set syntax=markdown diff --git a/lazy-lock.json b/lazy-lock.json index 23361e7..4cd3b58 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -5,16 +5,19 @@ "cmp-nvim-lsp": { "branch": "main", "commit": "44b16d11215dce86f253ce0c30949813c0a90765" }, "cmp-path": { "branch": "main", "commit": "91ff86cd9c29299a64f968ebb45846c485725f23" }, "cmp_luasnip": { "branch": "master", "commit": "18095520391186d634a0045dacaa346291096566" }, + "duck.nvim": { "branch": "main", "commit": "8f18dd79c701698fc150119ef642c1881ce6a538" }, "everforest": { "branch": "master", "commit": "b8ef2d0bde98645250a8997393aefba38e8c6ff3" }, "fidget.nvim": { "branch": "main", "commit": "0ba1e16d07627532b6cae915cc992ecac249fb97" }, "friendly-snippets": { "branch": "main", "commit": "bc38057e513458cb2486b6cd82d365fa294ee398" }, "hotpot.nvim": { "branch": "master", "commit": "026eba9596b506ab6f807fd4aa93cd5f76255725" }, + "kiwi.nvim": { "branch": "master", "commit": "5a9e5234398f9595cec86419196e4a47b36a354d" }, "lazy.nvim": { "branch": "main", "commit": "dac844ed617dda4f9ec85eb88e9629ad2add5e05" }, "mason-lspconfig.nvim": { "branch": "main", "commit": "e86a4c84ff35240639643ffed56ee1c4d55f538e" }, "mason.nvim": { "branch": "main", "commit": "fe9e34a9ab4d64321cdc3ecab4ea1809239bb73f" }, "neodev.nvim": { "branch": "main", "commit": "2973d6c56cbde46c04e12476bb40eefd516d5f35" }, "nvim-cmp": { "branch": "main", "commit": "c4e491a87eeacf0408902c32f031d802c7eafce8" }, "nvim-lspconfig": { "branch": "master", "commit": "b6091272422bb0fbd729f7f5d17a56d37499c54f" }, + "nvim-paredit": { "branch": "master", "commit": "111c8c8f637a8c2e3e8b78bb0d491f72b10ae875" }, "nvim-treesitter": { "branch": "master", "commit": "1c79da3300951e934f635eaf8703480b57644e7e" }, "plenary.nvim": { "branch": "master", "commit": "267282a9ce242bbb0c5dc31445b6d353bed978bb" }, "telescope-fzf-native.nvim": { "branch": "main", "commit": "9bc8237565ded606e6c366a71c64c0af25cd7a50" },