From 0e66a317251dca236b5989d9fa1f37ec9a43e8d2 Mon Sep 17 00:00:00 2001 From: flin16 Date: Sat, 24 May 2025 18:48:16 -0500 Subject: [PATCH] Auto commit --- .DS_Store | Bin 0 -> 6148 bytes init.lua | 2 + lazy-lock.json | 49 ++++++++ lazyvim.json | 14 +++ lua/.DS_Store | Bin 0 -> 6148 bytes lua/config/keymaps.lua | 41 +++++++ lua/config/options.lua | 23 ++++ lua/plugins/example.lua | 258 +++++++++++----------------------------- 8 files changed, 198 insertions(+), 189 deletions(-) create mode 100644 .DS_Store create mode 100644 lazy-lock.json create mode 100644 lazyvim.json create mode 100644 lua/.DS_Store diff --git a/.DS_Store b/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..ae820a0df68bce92c76b2754ccf2b9c1770da5e1 GIT binary patch literal 6148 zcmeHK&2G~`5S~o}-B6Hn0I5eyh+75ek0K#1CWIHL5gY&o8%L>C#~UR!IYg0sh7)(V zAn^`;g1$lFG1^C9W_Lnkg>Xa&W~AM3cYgNg^JX^#0IFNWdjKr}&{zm-O{{()WT&zw zHP+lfR5V69+zZ~C(Rj^M6n`rN^z9mOABK=XUip6N>-SaL$n<(qY9iF>PsQi*=H=Pr zsy+U#eSExfHfom`3Ux@KfH0a($2{_BG)|Lg-fn+WwR+>)^)0=nxAp7b*vx`F%!_F^ zoV=voGh@x~9nDsf`VsK{s`?-`bha z_dD%f@8Gbr*!AWQ_pyC=&{-^+`p(@4kB<5$=_oVrX}NgF@swM+#khnI*x=n%ID~uW zSC&-_5*qU`KAzGvM*`3|KP284ks19jJJ(fj{&bN*iqlAbUi4E$3J zs75d7b#Y7lwytfC-dYdK8!RN`S33L|f(`o=qc1(hJ6Nos-lGPh&saJ{4T}5`urx>| J4E#|BegOHff&u^l literal 0 HcmV?d00001 diff --git a/init.lua b/init.lua index 2514f9e..ada6139 100644 --- a/init.lua +++ b/init.lua @@ -1,2 +1,4 @@ -- bootstrap lazy.nvim, LazyVim and your plugins require("config.lazy") +vim.g.copilot_no_tab_map = true +vim.api.nvim_set_keymap("i", "", 'copilot#Accept("")', { silent = true, expr = true }) diff --git a/lazy-lock.json b/lazy-lock.json new file mode 100644 index 0000000..bf688c9 --- /dev/null +++ b/lazy-lock.json @@ -0,0 +1,49 @@ +{ + "CopilotChat.nvim": { "branch": "main", "commit": "16d897fd43d07e3b54478ccdb2f8a16e4df4f45a" }, + "LazyVim": { "branch": "main", "commit": "25abbf546d564dc484cf903804661ba12de45507" }, + "blink-cmp-copilot": { "branch": "main", "commit": "439cff78780c033aa23cf061d7315314b347e3c1" }, + "blink.cmp": { "branch": "main", "commit": "022521a8910a5543b0251b21c9e1a1e989745796" }, + "bufferline.nvim": { "branch": "main", "commit": "655133c3b4c3e5e05ec549b9f8cc2894ac6f51b3" }, + "catppuccin": { "branch": "main", "commit": "be1e5e6308bb9d016bf5c1565e0f1d5e46400d7a" }, + "conform.nvim": { "branch": "master", "commit": "6feb2f28f9a9385e401857b21eeac3c1b66dd628" }, + "copilot.lua": { "branch": "master", "commit": "a620a5a97b73faba009a8160bab2885316e1451c" }, + "copilot.vim": { "branch": "release", "commit": "d1e8429bef7f7709586886b0a23a46fbecc685c4" }, + "flash.nvim": { "branch": "main", "commit": "3c942666f115e2811e959eabbdd361a025db8b63" }, + "friendly-snippets": { "branch": "main", "commit": "572f5660cf05f8cd8834e096d7b4c921ba18e175" }, + "gitsigns.nvim": { "branch": "main", "commit": "8b729e489f1475615dc6c9737da917b3bc163605" }, + "grug-far.nvim": { "branch": "main", "commit": "f24022147ca4a0fe1d424a520a9437accbeba193" }, + "lazy.nvim": { "branch": "main", "commit": "6c3bda4aca61a13a9c63f1c1d1b16b9d3be90d7a" }, + "lazydev.nvim": { "branch": "main", "commit": "2367a6c0a01eb9edb0464731cc0fb61ed9ab9d2c" }, + "lualine.nvim": { "branch": "master", "commit": "0c6cca9f2c63dadeb9225c45bc92bb95a151d4af" }, + "mason-lspconfig.nvim": { "branch": "main", "commit": "1a31f824b9cd5bc6f342fc29e9a53b60d74af245" }, + "mason.nvim": { "branch": "main", "commit": "fc98833b6da5de5a9c5b1446ac541577059555be" }, + "mini.ai": { "branch": "main", "commit": "b91997d220086e92edc1fec5ce82094dcc234291" }, + "mini.icons": { "branch": "main", "commit": "397ed3807e96b59709ef3292f0a3e253d5c1dc0a" }, + "mini.pairs": { "branch": "main", "commit": "69864a2efb36c030877421634487fd90db1e4298" }, + "molokai": { "branch": "master", "commit": "c67bdfcdb31415aa0ade7f8c003261700a885476" }, + "neotest": { "branch": "master", "commit": "ef492755730e59e1d8122c461abbd086bee4c76b" }, + "neotest-python": { "branch": "master", "commit": "a2861ab3c9a0bf75a56b11835c2bfc8270f5be7e" }, + "noice.nvim": { "branch": "main", "commit": "0427460c2d7f673ad60eb02b35f5e9926cf67c59" }, + "nui.nvim": { "branch": "main", "commit": "f535005e6ad1016383f24e39559833759453564e" }, + "nvim-dap": { "branch": "master", "commit": "b0f983507e3702f073bfe1516846e58b56d4e42f" }, + "nvim-dap-python": { "branch": "master", "commit": "261ce649d05bc455a29f9636dc03f8cdaa7e0e2c" }, + "nvim-lint": { "branch": "master", "commit": "b47cbb249351873e3a571751c3fb66ed6369852f" }, + "nvim-lspconfig": { "branch": "master", "commit": "562487bc108bf73c2493f9e701b9334b48163216" }, + "nvim-nio": { "branch": "master", "commit": "21f5324bfac14e22ba26553caf69ec76ae8a7662" }, + "nvim-treesitter": { "branch": "master", "commit": "42fc28ba918343ebfd5565147a42a26580579482" }, + "nvim-treesitter-textobjects": { "branch": "master", "commit": "0f051e9813a36481f48ca1f833897210dbcfffde" }, + "nvim-ts-autotag": { "branch": "main", "commit": "a1d526af391f6aebb25a8795cbc05351ed3620b5" }, + "persistence.nvim": { "branch": "main", "commit": "166a79a55bfa7a4db3e26fc031b4d92af71d0b51" }, + "plenary.nvim": { "branch": "master", "commit": "857c5ac632080dba10aae49dba902ce3abf91b35" }, + "refactoring.nvim": { "branch": "master", "commit": "64dbe67bf7c28c864488262d267c799f80cae9ba" }, + "remote-nvim.nvim": { "branch": "main", "commit": "bc39422f544e6f7b6b6cdeb0cc0e9aaa20398f5a" }, + "snacks.nvim": { "branch": "main", "commit": "bc0630e43be5699bb94dadc302c0d21615421d93" }, + "telescope.nvim": { "branch": "master", "commit": "b4da76be54691e854d3e0e02c36b0245f945c2c7" }, + "todo-comments.nvim": { "branch": "main", "commit": "304a8d204ee787d2544d8bc23cd38d2f929e7cc5" }, + "tokyonight.nvim": { "branch": "main", "commit": "057ef5d260c1931f1dffd0f052c685dcd14100a3" }, + "trouble.nvim": { "branch": "main", "commit": "85bedb7eb7fa331a2ccbecb9202d8abba64d37b3" }, + "ts-comments.nvim": { "branch": "main", "commit": "1bd9d0ba1d8b336c3db50692ffd0955fe1bb9f0c" }, + "venv-selector.nvim": { "branch": "regexp", "commit": "c677caa1030808a9f90092e522de7cc20c1390dd" }, + "which-key.nvim": { "branch": "main", "commit": "370ec46f710e058c9c1646273e6b225acf47cbed" }, + "yanky.nvim": { "branch": "main", "commit": "04775cc6e10ef038c397c407bc17f00a2f52b378" } +} diff --git a/lazyvim.json b/lazyvim.json new file mode 100644 index 0000000..27d9c04 --- /dev/null +++ b/lazyvim.json @@ -0,0 +1,14 @@ +{ + "extras": [ + "lazyvim.plugins.extras.ai.copilot", + "lazyvim.plugins.extras.coding.yanky", + "lazyvim.plugins.extras.editor.refactoring", + "lazyvim.plugins.extras.lang.python", + "lazyvim.plugins.extras.test.core" + ], + "install_version": 8, + "news": { + "NEWS.md": "10960" + }, + "version": 8 +} \ No newline at end of file diff --git a/lua/.DS_Store b/lua/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..d6a5e57f8d17f565db57a7fab0e2e67237c51b3d GIT binary patch literal 6148 zcmeHKUrPc(5T8}cJ0$R-z{i7Lg-k_=UJkP_&_z8|nAe#dUAy9GK8SG7^@aK*eV%4^ zSIMlWAVOwf<~PotJNLJ;>i~dgPohJBG5|QJggF<@H$r*RHObjX9#QCL#4vacMlw-y zuvX21|HuIC-8S5T0txr9x_`K*P=p~QFo6N)B&6Xq9fpYtG4mD6m;X!Hnx zSirCr^l6r$9?zn0F*Ar66k%EsO{=gYhA{0I_iUYSF*9h|LD=C#*f$G1p$PqUe7>j4 zLHGvQG6T%ODg!k8p_J+VKmB?B*F|iY0cKz`84!g|&}rk^?A^MyO1f)3)LT>%s>=*6 lThP&0G1k&mTtU@>agQ8C-(qGEBPjewK-0j68TeBMJ^", '"_d', { desc = "Delete selection with Del" }) +map_all_mode("", function() + require("dap").continue() +end, { desc = "DAP: Continue" }) +map_all_mode("", function() + require("dap").step_over() +end, { desc = "DAP: Step Over" }) +map_all_mode("", function() + require("dap").step_into() +end, { desc = "DAP: Step Into" }) +map_all_mode("", function() + require("dap").step_out() +end, { desc = "DAP: Step Out" }) +vim.keymap.set("n", "\\b", function() + require("dap").toggle_breakpoint() +end, { desc = "DAP: Toggle Breakpoint" }) +if vim.g.neovide then + vim.keymap.set("n", "", ":w") -- Save + vim.keymap.set("i", "", ":w") + vim.keymap.set("n", "", ":CloseBuffer") -- Close + vim.keymap.set("i", "", ":CloseBuffer") -- Close + vim.keymap.set("i", "", '"+gP', { desc = "Paste from clipboard" }) + vim.keymap.set("c", "", "+") -- Paste command mode + vim.keymap.set("i", "", "+", { noremap = true, silent = true }) + vim.keymap.set("v", "", '"+y', { desc = "Copy to clipboard in visual mode" }) + vim.keymap.set("v", "", '"+d', { desc = "Cut to clipboard" }) + map_nv("", "ggG", { desc = "Select all" }) +end diff --git a/lua/config/options.lua b/lua/config/options.lua index 3ea1454..ade47d5 100644 --- a/lua/config/options.lua +++ b/lua/config/options.lua @@ -1,3 +1,26 @@ -- Options are automatically loaded before lazy.nvim startup -- Default options that are always set: https://github.com/LazyVim/LazyVim/blob/main/lua/lazyvim/config/options.lua -- Add any additional options here +vim.o.clipboard = "" +vim.o.guifont = "Monaco:h16" +vim.cmd("colorscheme molokai") + +local dap = require("dap") + +dap.adapters.python = { + type = "executable", + command = "python", + args = { "-m", "debugpy.adapter" }, +} + +dap.configurations.python = { + { + type = "python", + request = "launch", + name = "Launch file", + program = "${file}", + pythonPath = function() + return "python" + end, + }, +} diff --git a/lua/plugins/example.lua b/lua/plugins/example.lua index 17f53d6..3f61196 100644 --- a/lua/plugins/example.lua +++ b/lua/plugins/example.lua @@ -1,197 +1,77 @@ -- since this is just an example spec, don't actually load anything here and return an empty spec -- stylua: ignore -if true then return {} end - +return { + 'tomasr/molokai', -- colorscheme + {"mfussenegger/nvim-lint", + opts = { + linters_by_ft = { + sh = { "shellcheck" }, + }, + }, + config = function(_, opts) + local lint = require("lint") + lint.linters.ruff.args = { "--ignore=E401", } + end + }, + {"stevearc/conform.nvim", + opts = { + formatters_by_ft = { + python = { "black" }, + sh = { "shfmt" }, + lua = { "stylua" }, + }, + }}, + {"neovim/nvim-lspconfig", + opts = { + servers = { + pyright = { + }, + }, + }}, + { + "mfussenegger/nvim-dap-python", + ft = "python", + dependencies = { + "mfussenegger/nvim-dap", + }, + config = function() + require("dap-python").setup("python") + end, + }, + { + "github/copilot.vim", + config = function() + vim.g.copilot_no_tab_map = false + vim.api.nvim_set_keymap("i", "", 'copilot#Accept("")', { silent = true, expr = true }) + -- Use a different keybinding for accepting suggestions, for terminal mode. + vim.api.nvim_set_keymap("i", "", 'copilot#Accept("")', { silent = true, expr = true }) + end, + }, + { + "amitds1997/remote-nvim.nvim", + dependencies = { + "nvim-lua/plenary.nvim", + "MunifTanjim/nui.nvim", + "nvim-telescope/telescope.nvim", + }, + config = true, + }, + { + "CopilotC-Nvim/CopilotChat.nvim", + dependencies = { + { "github/copilot.vim" }, -- or zbirenbaum/copilot.lua + { "nvim-lua/plenary.nvim", branch = "master" }, -- for curl, log and async functions + }, + build = "make tiktoken", -- Only on MacOS or Linux + opts = { + -- See Configuration section for options + }, + -- See Commands section for default commands if you want to lazy load on them + }, +} -- every spec file under the "plugins" directory will be loaded automatically by lazy.nvim -- -- In your plugin files, you can: -- * add extra plugins -- * disable/enabled LazyVim plugins -- * override the configuration of LazyVim plugins -return { - -- add gruvbox - { "ellisonleao/gruvbox.nvim" }, - - -- Configure LazyVim to load gruvbox - { - "LazyVim/LazyVim", - opts = { - colorscheme = "gruvbox", - }, - }, - - -- change trouble config - { - "folke/trouble.nvim", - -- opts will be merged with the parent spec - opts = { use_diagnostic_signs = true }, - }, - - -- disable trouble - { "folke/trouble.nvim", enabled = false }, - - -- override nvim-cmp and add cmp-emoji - { - "hrsh7th/nvim-cmp", - dependencies = { "hrsh7th/cmp-emoji" }, - ---@param opts cmp.ConfigSchema - opts = function(_, opts) - table.insert(opts.sources, { name = "emoji" }) - end, - }, - - -- change some telescope options and a keymap to browse plugin files - { - "nvim-telescope/telescope.nvim", - keys = { - -- add a keymap to browse plugin files - -- stylua: ignore - { - "fp", - function() require("telescope.builtin").find_files({ cwd = require("lazy.core.config").options.root }) end, - desc = "Find Plugin File", - }, - }, - -- change some options - opts = { - defaults = { - layout_strategy = "horizontal", - layout_config = { prompt_position = "top" }, - sorting_strategy = "ascending", - winblend = 0, - }, - }, - }, - - -- add pyright to lspconfig - { - "neovim/nvim-lspconfig", - ---@class PluginLspOpts - opts = { - ---@type lspconfig.options - servers = { - -- pyright will be automatically installed with mason and loaded with lspconfig - pyright = {}, - }, - }, - }, - - -- add tsserver and setup with typescript.nvim instead of lspconfig - { - "neovim/nvim-lspconfig", - dependencies = { - "jose-elias-alvarez/typescript.nvim", - init = function() - require("lazyvim.util").lsp.on_attach(function(_, buffer) - -- stylua: ignore - vim.keymap.set( "n", "co", "TypescriptOrganizeImports", { buffer = buffer, desc = "Organize Imports" }) - vim.keymap.set("n", "cR", "TypescriptRenameFile", { desc = "Rename File", buffer = buffer }) - end) - end, - }, - ---@class PluginLspOpts - opts = { - ---@type lspconfig.options - servers = { - -- tsserver will be automatically installed with mason and loaded with lspconfig - tsserver = {}, - }, - -- you can do any additional lsp server setup here - -- return true if you don't want this server to be setup with lspconfig - ---@type table - setup = { - -- example to setup with typescript.nvim - tsserver = function(_, opts) - require("typescript").setup({ server = opts }) - return true - end, - -- Specify * to use this function as a fallback for any server - -- ["*"] = function(server, opts) end, - }, - }, - }, - - -- for typescript, LazyVim also includes extra specs to properly setup lspconfig, - -- treesitter, mason and typescript.nvim. So instead of the above, you can use: - { import = "lazyvim.plugins.extras.lang.typescript" }, - - -- add more treesitter parsers - { - "nvim-treesitter/nvim-treesitter", - opts = { - ensure_installed = { - "bash", - "html", - "javascript", - "json", - "lua", - "markdown", - "markdown_inline", - "python", - "query", - "regex", - "tsx", - "typescript", - "vim", - "yaml", - }, - }, - }, - - -- since `vim.tbl_deep_extend`, can only merge tables and not lists, the code above - -- would overwrite `ensure_installed` with the new value. - -- If you'd rather extend the default config, use the code below instead: - { - "nvim-treesitter/nvim-treesitter", - opts = function(_, opts) - -- add tsx and treesitter - vim.list_extend(opts.ensure_installed, { - "tsx", - "typescript", - }) - end, - }, - - -- the opts function can also be used to change the default opts: - { - "nvim-lualine/lualine.nvim", - event = "VeryLazy", - opts = function(_, opts) - table.insert(opts.sections.lualine_x, { - function() - return "😄" - end, - }) - end, - }, - - -- or you can return new options to override all the defaults - { - "nvim-lualine/lualine.nvim", - event = "VeryLazy", - opts = function() - return { - --[[add your custom lualine config here]] - } - end, - }, - - -- use mini.starter instead of alpha - { import = "lazyvim.plugins.extras.ui.mini-starter" }, - - -- add jsonls and schemastore packages, and setup treesitter for json, json5 and jsonc - { import = "lazyvim.plugins.extras.lang.json" }, - - -- add any tools you want to have installed below - { - "williamboman/mason.nvim", - opts = { - ensure_installed = { - "stylua", - "shellcheck", - "shfmt", - "flake8", - }, - }, - }, -}