From 906bf8697017620950bf60f49ec872cc5d6911ed Mon Sep 17 00:00:00 2001 From: yimazu Date: Tue, 16 Jan 2024 17:09:15 -0500 Subject: [PATCH] added custom files --- lua/.DS_Store | Bin 0 -> 6148 bytes lua/custom/.DS_Store | Bin 0 -> 6148 bytes lua/custom/plugins/autopairs.lua | 16 +++++++ lua/custom/plugins/filetree.lua | 19 ++++++++ lua/custom/plugins/formatter.lua | 78 +++++++++++++++++++++++++++++++ lua/custom/plugins/neotree.lua | 13 ------ lua/custom/plugins/trouble.lua | 9 ++++ lua/kickstart/.DS_Store | Bin 0 -> 6148 bytes 8 files changed, 122 insertions(+), 13 deletions(-) create mode 100644 lua/.DS_Store create mode 100644 lua/custom/.DS_Store create mode 100644 lua/custom/plugins/autopairs.lua create mode 100644 lua/custom/plugins/filetree.lua create mode 100644 lua/custom/plugins/formatter.lua delete mode 100644 lua/custom/plugins/neotree.lua create mode 100644 lua/custom/plugins/trouble.lua create mode 100644 lua/kickstart/.DS_Store diff --git a/lua/.DS_Store b/lua/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..ef04439a9c663ee7055ddfd0a50105ddcbb5389c GIT binary patch literal 6148 zcmeHKy>8nu5I!buA~i_ip(%<^1iCti{}QCgqB`zgR7E>9g(F!;B3Kd)OO6M_fF7V( z`x4nYX3rZGeV*QtEMUb7GNfn&g9nfw$-5(U-+`nE0IV|!8UR%Qu&@wTo?=xZq^GhZ zYkFiGk;yp(#QroL`H}FKtj&O7z%cOG7@)no0ezT23Kneq1+jg(|YBt+#92~Z4e806nukqQNX1&JSt%Ld8wsv0c9ewBxqc{=Y6pai| z9VryWqFiF95LJ-&BOkw#914o)tl{=WJW}4ze%#i_qTAKS8J>ap<@c+bx63xcy*8us z#dY4(a)s}>aK}j`k~18qZ?s_uA*N+0)8fGxvW0{7KP9HoY}a_R-hN1AmtRIv+R|LPuk+P#zsv z$tM6}1&5_zo8A)S!!F+$iTYlR_XqKclZ0h=wy0^0mHybF~BNax7)#x^xe7?9No1X%PAHT pvda}p7p(MkEE{wczr-R1b(|WAj>cRej-Z$y0ZD_Y35`P3 zrGhBT90{b5N0U5@)KWAX{znGr-Bln11!L&Lz4xah^!$l3mE@y({YI2l%B!y`p69K3 zC*irCgrn|goVU8eZ!|j8T1E4IH#$mslTP)`SDlW!N!lBlge2}^$oJzUjrF9Z$7!6K z+|W8a-}gJ!_tWWSW9L(|Cbyg0vznaleyrEzR&!@I^S!qlA3h&+eyBmJe_1jGes@OJ z9nRqbI}7`Y^D`CUb5hEJOZ6M!nI2>|`}ObTh=FdmBV|az-$HS5d3F8ev8eb7QQ7(Z z)%I!8h3EMh4pXJmK6>UGq$n0w0LXJG#^jH3@`&PhXFbtBr0Lxu&`*3 z4s1*bfLKPe5$sbfK{?W4;IOcW9u#3y5pAk)C5Eu+XqPT7a9CKh=^$M3A>7KsRVc!& zj`K?s4kEC~Ei=FjJY-|7 qgyIT|cPZF0S24!YRs0Us2-+oe5CeyWMYN#s9|1!HH_X64W#ASXrgOsp literal 0 HcmV?d00001 diff --git a/lua/custom/plugins/autopairs.lua b/lua/custom/plugins/autopairs.lua new file mode 100644 index 00000000..7cf6cd34 --- /dev/null +++ b/lua/custom/plugins/autopairs.lua @@ -0,0 +1,16 @@ +return { + "windwp/nvim-autopairs", + -- Optional dependency + dependencies = { 'hrsh7th/nvim-cmp' }, + config = function() + require("nvim-autopairs").setup {} + -- If you want to automatically add `(` after selecting a function or method + local cmp_autopairs = require('nvim-autopairs.completion.cmp') + local cmp = require('cmp') + cmp.event:on( + 'confirm_done', + cmp_autopairs.on_confirm_done() + ) + end, +} + diff --git a/lua/custom/plugins/filetree.lua b/lua/custom/plugins/filetree.lua new file mode 100644 index 00000000..ef92c537 --- /dev/null +++ b/lua/custom/plugins/filetree.lua @@ -0,0 +1,19 @@ +return { + "nvim-neo-tree/neo-tree.nvim", + branch = "v3.x", + dependencies = { + "nvim-lua/plenary.nvim", + "nvim-tree/nvim-web-devicons", -- not strictly required, but recommended + "MunifTanjim/nui.nvim", + }, + config = function() + require('neo-tree').setup({ + auto_clean_after_session_restore = true, + filesystem = { + follow_current_file = { + enabled = true, + } + } + }) + end, +} diff --git a/lua/custom/plugins/formatter.lua b/lua/custom/plugins/formatter.lua new file mode 100644 index 00000000..311b5d5e --- /dev/null +++ b/lua/custom/plugins/formatter.lua @@ -0,0 +1,78 @@ +return { + "mhartington/formatter.nvim", + config = function() + -- Utilities for creating configurations + local util = require "formatter.util" + -- Provides the Format, FormatWrite, FormatLock, and FormatWriteLock commands + require("formatter").setup { + -- Enable or disable logging + logging = true, + -- Set the log level + log_level = vim.log.levels.WARN, + -- All formatter configurations are opt-in + filetype = { + css = { + require("formatter.filetypes.css").prettier, + }, + go = { + require("formatter.filetypes.go").gofmt(), + }, + html = { + require("formatter.filetypes.html").prettier + }, + js = { + require("formatter.filetypes.javascript").prettier, + }, + jsx = { + require("formatter.filetypes.javascriptreact").prettier, + }, + -- Formatter configurations for filetype "lua" go here + -- and will be executed in order + lua = { + -- "formatter.filetypes.lua" defines default configurations for the + -- "lua" filetype + require("formatter.filetypes.lua").stylua, + + -- You can also define your own configuration + function() + -- Supports conditional formatting + if util.get_current_buffer_file_name() == "special.lua" then + return nil + end + + -- Full specification of configurations is down below and in Vim help + -- files + return { + exe = "stylua", + args = { + "--search-parent-directories", + "--stdin-filepath", + util.escape_path(util.get_current_buffer_file_path()), + "--", + "-", + }, + stdin = true, + } + end + }, + md = { + require("formatter.filetypes.markdown").prettier + }, + ts = { + require("formatter.filetypes.typescript").prettier + }, + tsx = { + require("formatter.filetypes.typescriptreact").prettier + }, + + -- Use the special "*" filetype for defining formatter configurations on + -- any filetype + ["*"] = { + -- "formatter.filetypes.any" defines default configurations for any + -- filetype + require("formatter.filetypes.any").remove_trailing_whitespace + } + } + } + end +} diff --git a/lua/custom/plugins/neotree.lua b/lua/custom/plugins/neotree.lua deleted file mode 100644 index 3455cae5..00000000 --- a/lua/custom/plugins/neotree.lua +++ /dev/null @@ -1,13 +0,0 @@ -return { - "nvim-neo-tree/neo-tree.nvim", - version = "*", - dependencies = { - "nvim-lua/plenary.nvim", - "nvim-tree/nvim-web-devicons", -- not strictly required, but recommended - "MunifTanjim/nui.nvim", - -- "3rd/image.nvim", -- Optional image support in preview window: See `# Preview Mode` for more information - }, - config = function () - require('neo-tree').setup {} - end, -} diff --git a/lua/custom/plugins/trouble.lua b/lua/custom/plugins/trouble.lua new file mode 100644 index 00000000..7e92648b --- /dev/null +++ b/lua/custom/plugins/trouble.lua @@ -0,0 +1,9 @@ +return { + "folke/trouble.nvim", + dependencies = { "nvim-tree/nvim-web-devicons" }, + opts = { + -- your configuration comes here + -- or leave it empty to use the default settings + -- refer to the configuration section below + }, +} diff --git a/lua/kickstart/.DS_Store b/lua/kickstart/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..00563b0d37d4573c48abbf069a6515b21a405b90 GIT binary patch literal 6148 zcmeHK%}yIJ5FUrL*%hjk14W3FrCw7tX$k^ySweULwt@q#(kvT=Rh{)Jn~*~kX&(Tt zyaaE+y>C$QJj~b*f`m#vpsGSM()hFI$6kNCu`>W5TI09@Pz3-Fm9XSv^Nf(6bV*9i zQb81Ejs#N3qe-4cYAKox|04tR?kbRhf-&^r(fiX8dTygkCHbgczZ0dE@|(96&+}Hj z@8P+ggrn|goVU8eQyP8MT1E4IH#$ywlTLN*K&PW_lJ+2~(SpK%1Pl$_Fa!UTfqR^>bG!fm literal 0 HcmV?d00001